Beck FST WebDemo Festo

Back to index  Next  Previous

If we want to have input fields where we can enter a value (to change for example a counter or timer preselect), we need to use some JavaScript and the FORM tag. First I will show the result:

   
Flagword 10=

And here is the HTML code:

   
<script language="JavaScript" src="fst.js">
</script>
<form>
Flagword 10=<FSTCI dmw10><BR>
<input type="text" name="value1" value="<FSTCI dmw10>" size="6" maxlength="6">
<input type="button" value="Load FlagWord 10" onclick="CISend('MW10', value1.value)">
<input type="button" value="Decrement FlagWord 10" onclick="value1.value--;CISend('MW10', value1.value)">
<input type="button" value="Increment FlagWord 10" onclick="value1.value++;CISend('MW10', value1.value)">
</form>

The script(s) are placed in an external file, so they can be easily accessed from different files. This is a good solution if you have some scripts which are used from different pages.
Click here to see the JavaScript source file.