Problems, need help? Have a tip or advice? Post it here.
14 posts Page 2 of 2
Sam, PHP is not required - we can use Couch variables to set the page id.
Both the following methods should work (assuming we are using it in page_view of the page to be edited) -
<cms:form masterpage='index.php' mode='edit' page_id=k_page_id method='post'>
<cms:form masterpage='index.php' mode='edit' page_id="<cms:show k_page_id />" method='post'>

Hope this helps.
KK wrote:
<cms:form masterpage='index.php' mode='edit' page_id=k_page_id method='post'>
<cms:form masterpage='index.php' mode='edit' page_id="<cms:show k_page_id />" method='post'>



Yes this does work, but only when the form is on the page that the user trying to edit.

I'm using some pseudo authentication before the user can edit a page. When they authenticate the user is brought to another page, and the id from the original is assigned to a POST variable and then used in 'page_id'.

Similarly, I tried doing an sql query that results in an id number, and assigning 'page_id' to that value -- again it works to display the bound data but not when actually submitting it.

Sam
My mistake. I needed to create a hidden input with these value in order for the form to work. All is working now!

Thank you very much for your help, @KK


Sam
Is there a way to alter the layout of the USERS section in CouchCMS admin panel?
Maybe even the comments section?? :)
---
You live many times, but only ever remember your lives.length - 1
---
Image
14 posts Page 2 of 2
cron