Re: [web2py] Re: Using tinymce for text areas of in component views

2016-02-17 Thread PRACHI VAKHARIA

 

I tried that and it did *NOT* work with *Web2Py Components* 

 
—» 
*http://web2py.com/books/default/chapter/29/12/components-and-plugins#Components--LOAD-and-Ajax*

But it does work well on normal HTML Forms submission.
So, are you sure that it worked for you with Web2Py Components 
?
 
If so, then I am doing something wrong.
*(And do you really know about Web2Py Components 

 as 
I am referring to here? Please click the link to know what exactly I am 
referring to by Web2Py Components 
.
 
That will give you a better idea of what I am trying to do, and also, what 
I might be getting wrong as well.)*

Thanks a lot – for the code! Now, make it work with *LOAD()* – that is what 
I am trying to do.

 



On Wednesday, 17 February 2016 08:37:27 UTC-5, Javier Pepe wrote:
>
> Hello
>
> This work for me:
>
> Controller:
> def textarea():
> form=FORM('Texto:',
>   TEXTAREA(_name='texto', 
> requires=IS_NOT_EMPTY(),_id='mytextarea'),
>   INPUT(_type='submit'))
> return locals()
>
> View:
>
> 
>   
>   tinymce.init({
> selector: '#mytextarea'
>   });
>   
> {{extend 'layout.html'}}
> {{=form}}
>
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] Re: Using tinymce for text areas of in component views

2016-02-17 Thread Javier Pepe
Hello

This work for me:

Controller:
def textarea():
form=FORM('Texto:',
  TEXTAREA(_name='texto',
requires=IS_NOT_EMPTY(),_id='mytextarea'),
  INPUT(_type='submit'))
return locals()

View:


  
  tinymce.init({
selector: '#mytextarea'
  });
  
{{extend 'layout.html'}}
{{=form}}
~

On Wed, Feb 17, 2016 at 10:05 AM, PRACHI VAKHARIA 
wrote:

>
>
>- Can you please post your codes for making TinyMCE work with web2py
>Components?
>- It will allow to get a better understanding of how you applied it
>within web2py Components.
>
> Thanks!
>
> *— PRACHI*
>
>
>
>
> On Saturday, 6 November 2010 01:29:25 UTC-4, Luther Goh Lu Feng wrote:
>>
>> I am putting this link here
>> http://tinymce.moxiecode.com/punbb/viewtopic.php?id=28
>> as this is the solution to problematic form submissions.
>>
>> tinyMCE.triggerSave() might need to be called if you are using ajax or
>> components for your form submission. Hope this will be useful to
>> someone who searches the group.
>>
> --
> Resources:
> - http://web2py.com
> - http://web2py.com/book (Documentation)
> - http://github.com/web2py/web2py (Source code)
> - https://code.google.com/p/web2py/issues/list (Report Issues)
> ---
> You received this message because you are subscribed to the Google Groups
> "web2py-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to web2py+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: Using tinymce for text areas of in component views

2016-02-17 Thread PRACHI VAKHARIA


   - Can you please post your codes for making TinyMCE work with web2py 
   Components?
   - It will allow to get a better understanding of how you applied it 
   within web2py Components.

Thanks!

*— PRACHI*


 

On Saturday, 6 November 2010 01:29:25 UTC-4, Luther Goh Lu Feng wrote:
>
> I am putting this link here 
> http://tinymce.moxiecode.com/punbb/viewtopic.php?id=28 
> as this is the solution to problematic form submissions. 
>
> tinyMCE.triggerSave() might need to be called if you are using ajax or 
> components for your form submission. Hope this will be useful to 
> someone who searches the group. 
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: Using tinymce for text areas of in component views

2010-11-05 Thread Luther Goh Lu Feng
Erm I know the issue already. Too complex to put in words.

On Nov 6, 12:31 am, Luther Goh Lu Feng elf...@yahoo.com wrote:
 I have implemeted the basic tinymce editor here:http://
 wiki.moxiecode.com/index.php/
 TinyMCE:For_Dummies#To_create_a_very_simple_TinyMCE_wysiwyg_Editor

 In a normal view, tinymce works fine. The forms were constructed
 manually using form and textarea tags (It's a long story why
 sqlform isn't use but let's leave that for another time)

 Now I have a 2 components: a comments list component and a comments
 form component. Prior to the installation of tinymce, a comment
 created will automatically update the comments list via ajax.

 So what happens when I install tinymce? Well I am able to get the
 editor over the text area. However there are some strange things. Upon
 a fresh reload, the first form submission of the comments form will
 always activate Enter a value. The second submission (without
 refresh), causes the form to be submitted, but this time, the comments
 list won't be updated.

 If this is helpful, the code to do the ajax update of the comments
 form is as follows:

 $('#comments_form').live('change', function(){
         $.get({{=URL(a='roverus', c='comment', f='read.load',
 vars={'current_worksheet':request.args[0]})}}, function(data){
                 web2py_component('/roverus/comment/read.load?
 current_conversation=' + current_conversation, conversation);
         });

 })

 I have tried looking at the javascript console but there are no
 errors. Any tips to debug this is welcomed. Thanks in advance.


[web2py] Re: Using tinymce for text areas of in component views

2010-11-05 Thread Luther Goh Lu Feng
I am putting this link here 
http://tinymce.moxiecode.com/punbb/viewtopic.php?id=28
as this is the solution to problematic form submissions.

tinyMCE.triggerSave() might need to be called if you are using ajax or
components for your form submission. Hope this will be useful to
someone who searches the group.


On Nov 6, 4:18 am, Luther Goh Lu Feng elf...@yahoo.com wrote:
 Erm I know the issue already. Too complex to put in words.

 On Nov 6, 12:31 am, Luther Goh Lu Feng elf...@yahoo.com wrote:







  I have implemeted the basic tinymce editor here:http://
  wiki.moxiecode.com/index.php/
  TinyMCE:For_Dummies#To_create_a_very_simple_TinyMCE_wysiwyg_Editor

  In a normal view, tinymce works fine. The forms were constructed
  manually using form and textarea tags (It's a long story why
  sqlform isn't use but let's leave that for another time)

  Now I have a 2 components: a comments list component and a comments
  form component. Prior to the installation of tinymce, a comment
  created will automatically update the comments list via ajax.

  So what happens when I install tinymce? Well I am able to get the
  editor over the text area. However there are some strange things. Upon
  a fresh reload, the first form submission of the comments form will
  always activate Enter a value. The second submission (without
  refresh), causes the form to be submitted, but this time, the comments
  list won't be updated.

  If this is helpful, the code to do the ajax update of the comments
  form is as follows:

  $('#comments_form').live('change', function(){
          $.get({{=URL(a='roverus', c='comment', f='read.load',
  vars={'current_worksheet':request.args[0]})}}, function(data){
                  web2py_component('/roverus/comment/read.load?
  current_conversation=' + current_conversation, conversation);
          });

  })

  I have tried looking at the javascript console but there are no
  errors. Any tips to debug this is welcomed. Thanks in advance.