<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"><html><head><meta name="qrichtext" content="1" /><style type="text/css">p, li { white-space: pre-wrap; }</style></head><body style=" font-family:'DejaVu Sans'; font-size:9pt; font-weight:400; font-style:normal;">On 22 February 2009, andrewhodel@gmail.com wrote:<br />&gt; I'm currently embedding an iframe with a form which allows users to comment<br />&gt; on the system from the portal page.<br />&gt;<br />&gt; As it stands now the users have to manually enter the node that they are at<br />&gt; in the forum, I would ideally like to have this field be populated<br />&gt; automatically based upon the node which they are currently on.<br />&gt;<br />&gt; The node name is present in on the page and I can get the information via<br />&gt; the DOM however this seems like a very bad way to do things. Beyond the<br />&gt; argument of people without JS, the node name is wrapped in between a div<br />&gt; that has no id and only a class (although that class seems to be unique).<br />&gt; Then inside a span, then inside an em. Using JS it would be ideal if the<br />&gt; node name tag had it's own unique id.<br />&gt;<br />&gt; Even better would be a list of predefined JS variables for certain data an<br />&gt; administrator may want to input into a form. Specifically current data<br />&gt; usage, time since login, mac address, username, and node name.<br /><br>
<br />The SmartyTemplate content type (http://dev.wifidog.org/wiki/ContentDistributionSystem#SmartyTemplate) is designed to do exactly what you want, except that you cannot create a &lt;script&gt; tag.  However, you can use the variables in an onclick() in a &lt;form&gt; or &lt;a&gt;.<br>
-- <br />Benoit Grégoire<br />Technologies Coeus inc.</p></body></html>