There are many ways neither of which is straightforward unless of course you display all the information in the list view and print this web page. Alternatively, you can enable the RSS of the database, set the RSS template to display the entry as you want it in the printout and then open the RSS page and print it. Alternatively you can do something more complex than these two ways, and I'd be happy to explain what and how if neither one of the above works for you. 
Itamar Tzadok
Forumindlæg af Itamar Tzadok
Moodle in English -> Database -> Field IDs -> Re: Field IDs
ved Itamar Tzadok -
For both text and HTML Editor fields you should use
document.getElementById(fieldID).value=
By the way, in your template code you have
...
<td Xonclick="setDefault('||Id kazu#id||','2345');">||Id kazu||</td>
...
This code means that when the 'Identifikátor kazuistiky' field in the form is clicked it will be assigned the default value. But if what you need is that the field will be assigned the default value only by the form and not by the user then that onclick in the td element should be omitted.
Also, the javascript as implemented will assign the default value to the field every time the form is opened, even if it is opened for editing in which case if the user updated the information in that field the user information will be overridden. To prevent that you need to first check in the function that the field is empty:
function setDefault(fieldID,val){if (document.getElementById(fieldID).value=="") {
document.getElementById(fieldID).value=val;
}
} Give it a try and let me know if it works. :-)
Moodle in English -> Database -> Field IDs -> Re: Field IDs
ved Itamar Tzadok -
Here is the function definition. Note that the field ids which are passed into the function are strings to be used in document.getElementById('...'). 
Moodle in English -> Database -> Field IDs -> Re: Field IDs
ved Itamar Tzadok -
Here is an example of the Add template code. Note the javascript function call at the bottom. In this case the function itself is defined in the javascript template but there should be no problem to add it to the script tag of the Add Template. Hope this helps and let me know if you need more details. 
You can try the following and see if it works for you. Add an html block on your course main page and in text mode add something like:
<script type="text/javascript"> openpopup('your_file.html', 'title', 'menubar=0,location=0,scrollbars,status,resizable,width=400,height=500', 0); </script>
This uses Moodle's popup method but of course you can also use window.open.

<script type="text/javascript"> openpopup('your_file.html', 'title', 'menubar=0,location=0,scrollbars,status,resizable,width=400,height=500', 0); </script>
This uses Moodle's popup method but of course you can also use window.open.