eZ Community » Forums » Developer » Example for...
expandshrink

Example for eZWorkflowType::STATUS_REDIRECT

Example for eZWorkflowType::STATUS_REDIRECT

Tuesday 22 February 2011 2:36:31 pm - 2 replies

We're looking to create a workflow event type which returns the constant eZWorkflowType::STATUS_REDIRECT. However, I'm curious as to where/how we should specify the URL to which one should be redirected. Can anyone please give me an example or refer me to some documentation?

Thanks in advance!

Thursday 24 February 2011 4:01:44 pm

$The eZTrigger::runWorkflow(); does actions based on workflow return value.

You would need to set the RedirectUrl property of the eZWorkflowProcess.

something like this i guess:

public function execute( $process, $event ) {
   $process->RedirectUrl = 'http://ez.no';
 
   return eZWorkflowType::STATUS_REDIRECT;
 }

Thursday 24 February 2011 6:50:06 pm

Thanks for the tip, Olav. It worked like a charm. happy.gif Emoticon

expandshrink

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

36 542 Users on board!

Forums menu

Proudly Developed with from