2016-09-07, 05:06:49
(2016-09-07, 04:22:53)Bigin Wrote: Create new route: galleries/([a-z0-9-/]+) in gs-front-router, for example
Action:
that should do the trick.Code:<?php
return array( 'title' => 'My Title',
'content' => function($slug) {
echo 'This is my Gallery' .$slug;
});
http://mysite/galleries/abc/
http://mysite/galleries/def/
everything working
Thanks Bigin, it start working I got The Title but the content is empty and when I try 'title' => 'My Title'.$slug,
I got only My Title, And of course I need this $slug
here is my action code
PHP Code:
<?php
$slug=$args[0];
return array( 'title' => 'My Title '.$slug, // works ;)))
'content' => function($slug) { // doesn't work ?????
echo 'test '.$slug;
});
Thanks in advance to both of you guys