On Mar 16, 2007, at 3:49 PM, Peter2 wrote:
>
> yes, that's part of what i mean, but the more important part is that
> i
> want to _start with_ a textarea. that is, i want a TEXTAREA on my
> screen
> - not a one-line INPUT element. here is my code:
>
> <textarea id="editme" rows="5" cols="50">This is what is in the box
> already.</textarea>
>
> <script type="text/javascript">
> new Ajax.InPlaceEditor('editme', '/ajaxWaitReturn.php',
> {rows:5,cols:50});
> </script>
>
> The 'ajaxWaitReturn.php' script just sleeps 5 seconds, then ends. So,
> taking easy things first, there never is a 'Saving...' message -
> whether
> I use a 'wait/spinning' icon or not. Is this normal? A bug?
>
> (didn't realize this forum was the same as the google group sort of.)
>
>
> On Mar 16, 9:39 am, Walter Lee Davis <[EMAIL PROTECTED]> wrote:
>> On Mar 16, 2007, at 11:14 AM, Peter2 wrote:
>>
>>
>>
>>> when i use a TEXTAREA with in-place-editor, all sorts of weird stuff
>>> happens - like it disappears, or the callbacks don't work, the 'wait'
>>> indicator stops working after the first save, i never get a 'Save...'
>>> message, etc. is this all from using a TEXTAREA as opposed to a P
>>> tag?
>>
>> Not sure what you mean here. Do you mean if you set the editor to use
>> columns and rows, rather than letting it default to a single-line
>> (input type=text) you get different behavior? I haven't seen that
>> personally, and I have used both types of IPE.
>>
>>> also, is there a non-hack way to not pre-select all the text in the
>>> textarea?
>>
>> There was a long discussion of this recently on this list. Please have
>> a search of the archives.
>>
>> Walter
>
>
That's whacked! It's a textarea, so just use that! Are you trying to
get the textarea's form to submit over Ajax? Cuz that's pretty easy:
(in your <form> tag)
onsubmit="Element.show('spinner'); new
Ajax.Updater('parent_div_of_the_form', 'form_handler.php',
{asynchronous:true, parameters:Form.serialize(this)}); return false;"
I'm not at all clear why you would have a form element and then make
the form element itself editable with IPE. Form elements are editable
to begin with!
Walter
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---