Share » Forums » Developer » Control the behaviour of the Web Site...

Control the behaviour of the Web Site Toolbar

Control the behaviour of the Web Site Toolbar

Thursday 31 July 2008 2:14:49 am - 4 replies

Author Message

Albe Terra

Thursday 31 July 2008 6:49:02 am

I found an hidden element in the edit form called "RedirectURIAfterPublish"...I think that's what I was looking for!

The problem in now: how can I change this value only for one content class? So that when I edit instances of this class, the value is cutomized according to my needs.

Thanks! Albe

Gabriel Finkelstein

Thursday 31 July 2008 11:24:29 am

You could do an override of edit.tpl for that class and add that hidden field.
Something like:

[edit_document]
Source=content/edit.tpl
MatchFile=edit/document.tpl
Subdir=templates
Match[class_identifier]=document

André R.

Thursday 31 July 2008 12:12:03 pm

And since you don't have the node id before the object is published the first time, you'll need to create a module that takes object id as input and redirects you to the url of the main node of the object.

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Albe Terra

Friday 01 August 2008 5:48:58 am

Thanks to all!

So I have to use the attribute "RedirectURIAfterPublish" to redirect the user to a custom module?

And how can I obtain the ID of the node when I'm in the module and make the redirection to the view of the node?

Thanks to all!
Albe

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu