Yudhi-Max
How to making a simple form using xtscript code to get value from input text and print the output/result? Please give me a sample, thanks
Mwebvendor
Yudhi-Max Xtscript is not a server-side scripting like php. It is like a javascript
Graham
Yudhi-Max simple form
<form action="">
<input type="text" name="my_var" value="" />
<input type="text" name="my_other_var" value="" />
<input type="submit" value="Go" />
</form>
Copy code
in html You can get the values like this
{_$my_var|default value}
{_$my_other_var|default value}
Copy code
The "get" function in xtscript gets the value of variables set in forms or the query string
<!--parser:xtscript-->
get my_var
get_or_default my_other_var;my default value
print $my_var
print $my_other_var
<!--/parser:xtscript-->
Copy code
xtscript
is server based
Yudhi-Max
Graham Thank you so much Mr.Graham, the explanation from you has very helped to me
Yudhi-Max
Graham one question again Sir, i want print value of 'my_var' to output in base64_encode format, how to do it?