[web2py] Re: MARKMIN line break

2012-12-06 Thread Andrew W
I assume you are no longer talking about markmin. I didn't think you could use {{ }} in markmin. Correct ? On Sunday, December 2, 2012 10:51:49 PM UTC+13, apps in tables wrote: > > Thank you... > > On Sunday, December 2, 2012 7:45:50 AM UTC+3, Massimo Di Pierro wrote: >> >> You are missing

[web2py] Re: MARKMIN line break

2012-12-02 Thread apps in tables
Thank you... On Sunday, December 2, 2012 7:45:50 AM UTC+3, Massimo Di Pierro wrote: > > You are missing that you need to generate html and {{=anything}} > always escape anything. > > You want: > > {{=(row.body1)}}{{=(row.body2)}} > > or > > {{=CAT(row.body1,BR(),row.body2)}} > > or > > {{=CAT(r

[web2py] Re: MARKMIN line break

2012-12-01 Thread Massimo Di Pierro
You are missing that you need to generate html and {{=anything}} always escape anything. You want: {{=(row.body1)}}{{=(row.body2)}} or {{=CAT(row.body1,BR(),row.body2)}} or {{=CAT(row.body1,XML(''),row.body2)}} or {{=XML(row.body1+''+row.body2, sanitize=True)}} The latter is not quite

[web2py] Re: MARKMIN line break

2012-12-01 Thread Massimo Di Pierro
On Saturday, 1 December 2012 21:43:22 UTC-6, apps in tables wrote: > > > I am trying these: > > {{=(row.body1)+ \n\n +(row.body2)}} > > {{=(row.body1)+ ' \n\n '+(row.body2)}} > > {{=(row.body1)+ [[NEWLINE]] +(row.body2)}} > > {{=(row.body1)+ '[[NEWLINE]]' +(row.body2)}}

[web2py] Re: MARKMIN line break

2012-12-01 Thread apps in tables
I am trying these: {{=(row.body1)+ \n\n +(row.body2)}} {{=(row.body1)+ ' \n\n '+(row.body2)}} {{=(row.body1)+ [[NEWLINE]] +(row.body2)}} {{=(row.body1)+ '[[NEWLINE]]' +(row.body2)}} and they are not working. What am i missing? Regards, Ashraf --

[web2py] Re: MARKMIN line break

2012-11-29 Thread Dirk Krause
I learned from my editor that there is a huge difference between a paragraph and a line break. This also documented on a different thread here - people writing texts need both. Am Donnerstag, 29. November 2012 17:51:45 UTC+1 schrieb Massimo Di Pierro: > > Why do you want the newline at all? If

[web2py] Re: MARKMIN line break

2012-11-29 Thread Massimo Di Pierro
Why do you want the newline at all? If you have \n\n in your text, it will be used to brak You can just add space after with css. On Thursday, 29 November 2012 10:27:12 UTC-6, Dirk Krause wrote: > > I see, and thank you. Now we already have a database full of text without > the 'newline' t

[web2py] Re: MARKMIN line break

2012-11-29 Thread Dirk Krause
I see, and thank you. Now we already have a database full of text without the 'newline' tag and I have two options: (1) traverse through the database and applying foresaid regex to all text fields or (2) hack the regex somewhere into the code. I just tried (2) and it seems to be working; I appli

[web2py] Re: MARKMIN line break

2012-11-29 Thread Massimo Di Pierro
The idea was to insert explicit newlines inside tags like H1, H2, etc. On Thursday, 29 November 2012 08:52:24 UTC-6, Dirk Krause wrote: > > ok, thank you. > > I am only wondering why there is a special tag '[[NEWLINE]] when there is > already a one-to-one token for it - the single page break itse

[web2py] Re: MARKMIN line break

2012-11-29 Thread Dirk Krause
ok, thank you. I am only wondering why there is a special tag '[[NEWLINE]] when there is already a one-to-one token for it - the single page break itself. This can be parsed with re.sub(r'([^\n])\n([^\n])', r'\1[[NEWLINE]]\n\2', s) (full example here: http://pythonfiddle.com/replace-single-line-b

[web2py] Re: MARKMIN line break

2012-11-29 Thread villas
Use this: [[NEWLINE]] On Thursday, November 29, 2012 11:04:56 AM UTC, Dirk Krause wrote: > > Hi, > > sorry if this was answered elsewhere but I couldn't find it: > I found no consistent answer how to add single line breaks ('') as > opposed to paragraphs ('') into MARKMIN. > > This is what I fou