> When inside a html form (<html><form>......) how do I access the data
> in a config.options.txt... variable.
> I am looking for something like
> <input name="name" value = {{config.options.txtUserName}}>
> Is that possible?
Unfortunately, there isn't an 'onInit' syntax for HTML form
elements... as a result, there isn't really a *direct* way to use
javascript code to initialize a field's value. However, it is still
possible to initialize form controls using javascript, but it has to
be written a bit indirectly.
Here's the basic structure:
<html><nowiki><form>
<input name="somename" value="">
</form></html><script>
var form=place.lastChild.getElementsByTagName('form')[0];
form.somename.value=config.options.txtUserName;
</script>
note: requires http://www.TiddlyTools.com/#InlineJavascriptPlugin
enjoy,
-e
Eric Shulman
TiddlyTools / ELS Design Studios
--
You received this message because you are subscribed to the Google Groups
"TiddlyWiki" 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/tiddlywiki?hl=en.