Buy Now
Sign in

redirect event with parameters

ieraora , February 01 2020, 17:05
ieraora 130
February 01 2020, 17:05 #390998
I'm sorry, I searched to the forum and FAQ (variable shortcodes),
If I need to add a parameters of a redirect event, how can I?
I tried solutions similar this, without success.
{redirect:name_event}&params=(data:id_listino_2) ?
I done with this (see below), but there is another solution with name of event?
healyhatman 9
February 01 2020, 23:39 #391000
CFs parser (that takes the shortcodes and performs actions) for redirect looks like this
 function redirect($name){
$connection = $this->_connection();

$events = array_keys($connection['events']);
if(in_array($name, $events)){
$url = $this->_url();
$url = \G2\L\Url::build($url, ['event' => $name]);
$url = $this->parse($name, false, 2);

So if the text equals the name of an event it redirects to that event, otherwise it parses the text (like in your working example).
Web developer at - I DO NOT work for ChronoEngine!
Professional Work:
Custom CF / CC Plugins and Extensions:
ieraora 130
February 02 2020, 01:05 #391002
Ok, Good!