Take a look at

http://code.google.com/p/blogitizor/source/browse/src/controllers/admin.py
line 280 starts the controller.

note lines 293-297 - setting wmd defaults

Look at

http://code.google.com/p/blogitizor/source/browse/src/views/admin/create.html

note lines
191-193 - sets wmd options
331 - initializes wmd, this will scan all textareas and convert them
to wmd unless they are of class wmd-ignore


-Thadeus





On Thu, Jan 28, 2010 at 5:00 AM, selecta <gr...@delarue-berlin.de> wrote:
> i showed in a slice that using a wysiwyg editor for markup is
> possible, why not use that instead of wysiwym
>
> On Jan 28, 9:52 am, Johann Spies <johann.sp...@gmail.com> wrote:
>> Thadeus mentioned that he used WMD on his blog.
>>
>> I have tried to get it working by putting the following in layout.hml:
>>
>> <script type="text/javascript">
>>   // to set WMD's options programatically, define a "wmd_options"
>> object with whatever settings
>>   // you want to override.  Here are the defaults:
>>   wmd_options = {
>>   // format sent to the server.  Use "Markdown" to return the markdown 
>> source.
>>   output: "HTML",
>>
>>   // line wrapping length for lists, blockquotes, etc.
>>   lineLength: 40,
>>
>>   // toolbar buttons.  Undo and redo get appended automatically.
>>   buttons: "bold italic | link blockquote code image | ol ul heading hr",
>>
>>   // option to automatically add WMD to the first textarea found.  See
>> apiExample.html for usage.
>>   autostart: true
>>   };
>> </script>
>> <script type="text/javascript" src="wmd/wmd.js"></script>
>> </body>
>> </html>
>>
>> But this seems to be ignored.
>>
>> As I understand the instructions this should be just before </body>
>> so I cannot see where else to put it.
>>
>> What am I doing wrong?
>>
>> Johann
>
> --
> You received this message because you are subscribed to the Google Groups 
> "web2py-users" group.
> To post to this group, send email to web...@googlegroups.com.
> To unsubscribe from this group, send email to 
> web2py+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/web2py?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To post to this group, send email to web...@googlegroups.com.
To unsubscribe from this group, send email to 
web2py+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en.

Reply via email to