[Infusion-users] What syntax for single inlineEdit?

Matt Zumwalt collaborate at yourmediashelf.com
Tue Dec 1 08:08:22 UTC 2009

Thanks for the help.  I just needed put the code in a clean page -- I was hitting all sorts of funny id collisions.

I'm now able to inject new inline editable fields into a page on the fly -- this answers Jeromy's question from the other day about adding new editable fields after page load.  In short - Justin was right.  You can use fluid.inlineEdit to initialize an editable field whenever you want.  I'll pass on some tutorial content for you when I get a chance. 

Matt Zumwalt
MediaShelf, LLC

On Nov 30, 2009, at 5:50 PM, Antranig Basman wrote:

> Matt Zumwalt wrote:
>> The funny nesting in the id doesn't have any particular purpose in the DOM itself.  It's so that our save function knows how to submit the values to the app (equivalent to the "name" attribute in html form inputs).  The particular syntax is a rails convention.  I'm not extremely familiar with jquery.  Are you saying that ids in this format will screw up the jquery #id selector?  I tried using a more ordinary id but it didn't help:
>> <dd id="foo" class="flc-inlineEditable">
>>  <span class="flc-inlineEdit-text">Foo</span>
>> </dd>
>>    var singleEdit = fluid.inlineEdit("#foo", {});
>>    singleEdit.edit();
>> ... this still fails.
> This sample markup and code works fine for me in testing. Things to check - i) is an exception being thrown by the failure of earlier code? ii) is there an id collision in your dd with some other markup in the file?
> Yes, the jquery id selector is sensitive to unusual characters and in this case we recommend you use the fluid.byId() framework function as a safe and quick way to do the search. But your "foo" example should work fine - have a look at the contents of "singleEdit" at the time of execution to see if there is some other problem with the code.
> Cheers,
> A.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://fluidproject.org/pipermail/infusion-users/attachments/20091201/ea8ca33b/attachment.html>

More information about the Infusion-users mailing list