<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style>
</head>
<body class='hmmessage'><div dir='ltr'>
The child component should have an ajax callback, then. It doesn't need to be in a form necessarily.<div><br></div><div>It could look something like this:</div><div><br></div><div>html textInput</div><div>&nbsp; &nbsp; callback: [:v | self doSomethingWithValue: v ];</div><div>&nbsp; &nbsp; onChange:/onBlur:/onEnter: (html jQuery ajax serializeThis).</div><div><br></div><div>That would serialize it, but I imagine you want it to do something, so you could further modify it this way:</div><div><br></div><div>html textInput</div><div>&nbsp; &nbsp; callback: [ ... ];</div><div>&nbsp; &nbsp; onEnter: (html jQuery ajax serializeThis onSuccess: (html jQuery ajax script: [:s | s add: (self doSomethingOn: s) ].</div><div><br></div><div>RS</div><div><br><div>&gt; Date: Wed, 5 Oct 2011 20:43:40 -0400<br>&gt; From: ljw1001@gmail.com<br>&gt; To: seaside@lists.squeakfoundation.org<br>&gt; Subject: [Seaside] Ajax Posting with JQuery: An example?<br>&gt; <br>&gt; Hi,<br>&gt; <br>&gt; I need to make an Ajax post using JQuery, with Seaside for my server.<br>&gt; I've found a number of Seaside JQuery examples (no posts though) and<br>&gt; lots of JQuery post examples (no seaside). In the JQuery examples you<br>&gt; specify the URL you're posting to, but that would be wrong in Seaside.<br>&gt; <br>&gt; Here's the use case. I have a large table of data. Each cell contains<br>&gt; an anchor and clicking on the anchor converts the cell to a TextInput<br>&gt; field. Now I need to submit that field's value, in an Ajaxy way, so I<br>&gt; only refresh the single cell of the table.<br>&gt; <br>&gt; A simplified version of the current code looks like this:<br>&gt; <br>&gt; renderContentOn: html        <br>&gt;         | child |<br>&gt;         child := myTextEditor<br>&gt;                                 valueBlock: [ object value ]<br>&gt;                                 callback: [ :value | object setValue: value ]<br>&gt; <br>&gt;         html anchor<br>&gt;                      onClick: ((html jQuery this) load  html: [ :r | r  render: child ]);<br>&gt;                      with: ( object value).        <br>&gt; <br>&gt; I'm assuming the solution involves modifying the callback in my<br>&gt; 'child' to post using JQuery.  if anyone could explain in a bit more<br>&gt; detail what the callback and the server code should look like it would<br>&gt; be a big help.<br>&gt; <br>&gt; PS: It would also make a good addition to Dynamic Web Development with<br>&gt; Seaside's draft JQuery chapter so you'd probably be helping a lot of<br>&gt; people ;)<br>&gt; <br>&gt; Thanks much.<br>&gt; <br>&gt; Larry<br>&gt; _______________________________________________<br>&gt; seaside mailing list<br>&gt; seaside@lists.squeakfoundation.org<br>&gt; http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside<br></div></div>                                               </div></body>
</html>