Monday 05 May 2003 2:53:57 pm
Hello,
From a template/page I can create a new contentobject. I'm able to do this with the following code:
<form method="post" action="/ezpublish/index.php/demo/content/action/">
<input type="hidden" name="NodeID" value="{$node.node_id}" />
<input type="hidden" name="ClassID" value="29" />
<input type="hidden" name="ContentObjectID" value="{$content_object.id}" />
<input class="button" type="submit" name="NewButton" value="Submit" /> </form> I have created a file called 'edit_class_29.tpl' with the correct code and this all works fine. But I have a question; On the page with the submit button (see the form-code above) I have a value that I would like to use in the edit-template 'edit_class_29.tpl'.
I have tried to create a hidden field which is also being submitted: <input type="hidden" name="Testvalue" value="1234" /> But unfortunately I cannot use this value in my edit-template. {$Testvalue} results in: Unknown template variable ' Testvalue ' in namespace '' I’ve tried to create a cookie with JavaScript containing the value. But when I use this solution I loose my Session-ID. Can somebody tell me how I can get a value from one template to another? Thanks, Ricardo Lindooren
|