I am not using Jython. Please see the version information in my prev. reply. Strange issue.
Should I send you my markmin2html.py for comparison? On 12 Okt., 16:16, Massimo Di Pierro <massimo.dipie...@gmail.com> wrote: > I cannot reproduce it. I get: > > Python 2.7.2 (v2.7.2:8527427914a2, Jun 11 2011, 15:22:34) > [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin > > >>> print MARKMIN(content) > > <p>... # My slides title > ... ## Slide One > ... this allows you to create slides using markmin > ... ## Slide Two > ... - you can use lists > ... - you can use <a href="http://www.google.com">links</a> > ... - you can use images <p align="center"><img src="http:// > image.example.com" alt="image" /></p> > ...</p> > > > > Which incorrect because of the <p> inside a <p> but otherwise correct. > Are you using jython? > > On Oct 12, 9:07 am, jotbe <jan.beili...@gmail.com> wrote: > > > > > > > > > Still not working: > > > ### HG rev: > > > $ LC_ALL=C; hg summary > > parent: 2503:0f3a2bc13026 tip > > fixed problem with missing identity in auth > > branch: default > > commit: 2 modified, 1 deleted, 5 unknown > > update: (current) > > > ### Py-CLI: > > > $ python web2py.py -P -M -S slides > > web2py Web Framework > > Created by Massimo Di Pierro, Copyright 2007-2011 > > Version 1.99.3 (2011-10-11 09:05:14) dev > > Database drivers available: SQLite3, pymysql > > Python 2.7.2 (default, Jul 27 2011, 15:07:16) > > [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin > > Type "help", "copyright", "credits" or "license" for more information. > > (InteractiveConsole)>>> content = """ > > > ... # My slides title > > ... ## Slide One > > ... this allows you to create slides using markmin > > ... ## Slide Two > > ... - you can use lists > > ... - you can use [[linkshttp://www.google.com]] > > ... - you can use images [[imagehttp://image.example.comcenter]] > > ... """>>> print MARKMIN(content) > > > <h1>My slides title</h1><h2>Slide One</h2><p>this allows you to create > > slides using markmin</p><h2>Slide Two</h2><ul><li>you can use lists</ > > li><li>you can use <p align="center"><img src="http:// > > image.example.com" alt="links <a > > href="http://www.google.com">http://www.google.com</a>]]</li><li>you can > > use images [[image" /></p></li></ > > ul> > > > Regards, > > Jan > > > On 12 Okt., 15:29, Massimo Di Pierro <massimo.dipie...@gmail.com> > > wrote: > > > > Can you try the latest markmin (from trunk)? > > > > On Oct 12, 2:37 am, jotbe <jan.beili...@gmail.com> wrote: > > > > > Your example code seems to trigger a bug in MARKMIN, when using the > > > > link and the image tag in a list: > > > > > ## snip ## > > > > > >>> content = """... # My slides title... ## Slide One... this allows > > > > >>> you to create slides using markmin... ## Slide Two... - you can use > > > > >>> lists... - you can use [[linkshttp://www.google.com]]... - you can > > > > >>> use images [[imagehttp://image.example.comcenter]]... """>>> print > > > > >>> MARKMIN(content)<h1>My slides title</h1><h2>Slide One</h2><p>this > > > > >>> allows you to create slides using markmin</p><h2>Slide > > > > >>> Two</h2><ul><li>you can use lists</li><li>you can use <img > > > > >>> src="http://image.example.com" alt="links <a > > > > >>> href="http://www.google.com">http://www.google.com</a>]]</li><li>you > > > > >>> can use images [[image" align="center" /></li></ul> > > > > > ## snap ## > > > > > The generated html link including the link scope "links" is inserted > > > > into the alt attribute. > > > > > It works when separating the image from the list: > > > > > ## snip ##>>> content = """ > > > > > ... # My slides title > > > > ... ## Slide One > > > > ... this allows you to create slides using markmin > > > > ... ## Slide Two > > > > ... - you can use lists > > > > ... - you can use [[linkshttp://www.google.com]] > > > > ... you can use images [[imagehttp://image.example.comcenter]] > > > > ... """>>> print MARKMIN(content) > > > > > <h1>My slides title</h1><h2>Slide One</h2><p>this allows you to create > > > > slides using markmin</p><h2>Slide Two</h2><ul><li>you can use lists</ > > > > li><li>you can use <a href="http://www.google.com">links</a></li></ul> > > > > you can use images <img src="http://image.example.com" alt="image" > > > > align="center" /> > > > > ## snap ## > > > > > Regards, > > > > > Jan > > > > > On 11 Okt., 16:17, Massimo Di Pierro <massimo.dipie...@gmail.com> > > > > wrote: > > > > > > I do not understand the bug. Can you provide an example? > > > > > > On Oct 11, 5:28 am, peter <peterchutchin...@gmail.com> wrote: > > > > > > > Using windows, and web2py version 1.99.2, if I setup a simple > > > > > > applicatioin, add slides.py and the test as per your instructions: > > > > > > > Things only half work. The link does not work, it says > > > > > > > "you can use > > > > > > >http://www.google.com]] > > > > > > " > > > > > > > "you can use images [[image" align="center" /> > > > > > > " > > > > > > > If one tries emboldening words, they do no appear emboldened. > > > > > > > This is a nice little addition to web2py, but it appears there is a > > > > > > bug. > > > > > > > Thanks again for all you work Massimo. > > > > > > > Peter > > > > > > > On Sep 13, 6:31 am, Andrew <awillima...@gmail.com> wrote: > > > > > > > > Whilst on the subject of [[ image tags in markmin, how do I > > > > > > > reference > > > > > > > a local image ? Can I use the URL function ? > > > > > > > > On Sep 13, 4:11 pm, guruyaya <guruy...@gmail.com> wrote: > > > > > > > > > Well, oddly it works the other way for me. I'll look into it > > > > > > > > later > > > > > > > > today. > > > > > > > > > On Sep 12, 3:20 am, Massimo Di Pierro > > > > > > > > <massimo.dipie...@gmail.com> > > > > > > > > wrote: > > > > > > > > > > markmin requires [[...]] not [...] > > > > > > > > > > On Sep 11, 2:29 pm, guruyaya <guruy...@gmail.com> wrote: > > > > > > > > > > > Ummm, why are you using [[ for links and images instead of > > > > > > > > > > just one > > > > > > > > > > [ ? It doesn't work for me, when I user the [[ syntax. > > > > > > > > > > > On Sep 11, 1:36 am, Massimo Di Pierro > > > > > > > > > > <massimo.dipie...@gmail.com> > > > > > > > > > > wrote: > > > > > > > > > > > > No. It makes the view. You just return it. > > > > > > > > > > > > On Sep 10, 3:53 pm, António Ramos <ramstei...@gmail.com> > > > > > > > > > > > wrote: > > > > > > > > > > > > > Humm, dont i need a view? > > > > > > > > > > > > > Em 10 de setembro de 2011 21:52, António Ramos > > > > > > > > > > > > <ramstei...@gmail.com>escreveu: > > > > > > > > > > > > > > Working now :) > > > > > > > > > > > > > > Em 10 de setembro de 2011 21:29, António Ramos > > > > > > > > > > > > > <ramstei...@gmail.com>escreveu: > > > > > > > > > > > > > > Traceback (most recent call last): > > > > > > > > > > > > >> File "gluon/restricted.py", line 191, in restricted > > > > > > > > > > > > >> File "gluon/restricted.py", line 178, in compile2 > > > > > > > > > > > > >> TypeError: compile() expected string without null > > > > > > > > > > > > >> bytes > > > > > > > > > > > > > >> :( > > > > > > > > > > > > > >> Just a screenshot please > > > > > > > > > > > > > >> 2011/9/10 Michele Comitini > > > > > > > > > > > > >> <michele.comit...@gmail.com> > > > > > > > > > > > > > >>> +1 > > > > > > > > > > > > > >>> Terrific! > > > > > > > > > > > > > >>> mic > > > > > > > > > > > > >>> Il giorno 10/set/2011 21:24, "Massimo Di Pierro" < > > > > > > > > > > > > >>> mdipie...@cs.depaul.edu> ha scritto: > > > > > > > > > > > > > >>> > Based on desk.js now you can do this > > > > > > > > > > > > > >>> > Put the attached slide.py under models (any app). > > > > > > > > > > > > > >>> > Write a controller like > > > > > > > > > > > > > >>> > def test(): > > > > > > > > > > > > >>> > content = """ > > > > > > > > > > > > >>> > # My slides title > > > > > > > > > > > > >>> > ## Slide One > > > > > > > > > > > > >>> > this allows you to create slides using markmin > > > > > > > > > > > > >>> > ## Slide Two > > > > > > > > > > > > >>> > - you can use lists > > > > > > > > > > > > >>> > - you can use [[linkshttp://www.google.com]] > > > > > > > > > > > > >>> > - you can use images > > > > > > > > > > > > >>> > [[imagehttp://image.example.comcenter]] > > > > > > > > > > > > >>> > """ > > > > > > > > > > > > >>> > return SLIDE(content,title="My slides") > > > > > > > > > > > > > >>> > Notice the resulting file is pure html5 with > > > > > > > > > > > > >>> > external links therefore > > > > > > > > > > > > >>> it can be downloaded as an independent document.