- How do I use Slime with my Code? Using the latest Pharo image, and have found the Slime classes, but not sure how to use them.<div><br></div><div>- Tried this :-</div><div><div><span class="Apple-tab-span" style="white-space:pre">        </span>html span class: &#39;formdata&#39;; with: [html&nbsp;</div>
<div><span class="Apple-tab-span" style="white-space:pre">                </span>textInput</div><div><span class="Apple-tab-span" style="white-space:pre">                </span>id: #tournamentname;</div><div><span class="Apple-tab-span" style="white-space:pre">                </span>value: tournamentEvent tournamentName;</div>
<div><span class="Apple-tab-span" style="white-space:pre">                </span>callback: [:value | tournamentEvent tournamentName: value];</div><div><span class="Apple-tab-span" style="white-space:pre">                </span>onChange: (html jQuery ajax serializeThis; html: [:r | r render: [self test: 1 on: &nbsp;r]] )].</div>
<div><br></div><div>but cannot see any changes to the DOM element.</div><div><br></div><div>Thanks for looking at this for me.</div><div><br></div><br><div class="gmail_quote">On Tue, Feb 10, 2009 at 3:18 PM, Lukas Renggli <span dir="ltr">&lt;<a href="mailto:renggli@gmail.com">renggli@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div class="Ih2E3d">&gt; html span class: &#39;formdata&#39;; with: [html<br>
&gt; textInput<br>
&gt; id: #tournamentname;<br>
&gt; value: tournamentEvent tournamentName;<br>
&gt; callback: [:value | tournamentEvent tournamentName: value. self test: value<br>
&gt; on: html];<br>
&gt; onChange: (html jQuery ajax serializeThis)].<br>
<br>
</div>html is not valid in the context of a callback. When the callback is<br>
evaluated the response connected to the html canvas you are referring<br>
to has already been sent to the client. Slime would detect such<br>
mistakes.<br>
<div class="Ih2E3d"><br>
&gt; #potsize is the id: of another field in the dialog. My callback works, but<br>
&gt; the DOM is not updated. What is the correct way to update other DOM elements<br>
&gt; in this fashion?<br>
<br>
</div>Try something along:<br>
<br>
 &nbsp; &nbsp;onChange: (html jQuery ajax<br>
 &nbsp; &nbsp; &nbsp; &nbsp;serializeThis;<br>
 &nbsp; &nbsp; &nbsp; &nbsp;html: [ :r |<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot; gee, we have a new renderer &quot;<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; r render: DateAndTime now ])<br>
<br>
Lukas<br>
<font color="#888888"><br>
--<br>
Lukas Renggli<br>
<a href="http://www.lukas-renggli.ch" target="_blank">http://www.lukas-renggli.ch</a><br>
_______________________________________________<br>
seaside mailing list<br>
<a href="mailto:seaside@lists.squeakfoundation.org">seaside@lists.squeakfoundation.org</a><br>
<a href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside" target="_blank">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a><br>
</font></blockquote></div><br><br clear="all"><br>-- <br>-JT<br><br><br>
</div>