I've tried to create a tag called $banner_logo inside controllers/banshee/page.php, to assign it the image path which will be used inside the xslt view by passing it to <img src="{banner_logo}"/>.
but unfortunately {banner_logo} gets always empty string.
so what's wrong here? and how can I solve the problem?
Thanks.
Hiawatha version: 9.7 Operating System: ArchLinux
Hugo Leisink
9 January 2015, 18:28
Make sure you master XSLT well enough and use the available modules as an example. It's not that I don't want to tell you the answer, it's that I don't know what you are doing so I don't know where it goes wrong.
Ian
9 January 2015, 19:03
Well, that's all my code:
-the code of views/banshee/page.xslt which is used for HTML output: http://pastebin.com/D6Rj3Ejp -my modifications to controllers/page.php: http://pastebin.com/a3VMC1Zd -my modifications to libraries/output.php: http://pastebin.com/xru7BX6H
Hugo Leisink
9 January 2015, 19:33
Try adding "title/@" to the variables in page.xslt:
It didn't work for me. and I still have empty value for banner_logo.
Ian
9 January 2015, 20:30
what is the reason for using "title/@" here, since I need only the banner_logo value?
Hugo Leisink
9 January 2015, 20:32
What you should do is learn more about XSLT first.
Ian
9 January 2015, 20:41
well, adding "title/@" didn't solve my problem? what to do now?
Ian
9 January 2015, 22:08
"title/@" is not needed here. and finally I found the solution, by adding $this->add_tag("banner_logo", $this->banner_logo); inside close_tag() of the libraries/output.php which I missed up: the only mistake I did here.