I am pretty much novice in php, but I do modify a bit various templates by trial and error method.
I am stuck now with the following problem and desperately need some help from you guys:
1. template has a top menu with class designed outlook and hover effect. however, a completely different class is designed if the link is active.
2. so, I have managed to differ it by php if function in the header.tpl file under <ul> section, like as follows:
Code: Select all
<li<?php if($currentpage == $home) {echo " class=menu_1_active";} else {echo " class=menu_1";}?>><a href="<?php echo $home; ?>"><?php echo $text_home;?></a></li>
<li>...
Code: Select all
$currentpage = $_SERVER['REQUEST_URI'];
Code: Select all
$this->data['title'] = $this->document->getTitle();
if I insert the line:
Code: Select all
$this->data['currentpage'] = $this->$_SERVER['REQUEST_URI'];
Code: Select all
$this->data['currentpage'] = $this->$_SERVER['REQUEST_URI'];
What am I doing wrong here?
Can anybody help with instructions how and where to name/define different pages / links in the opencart system?
Help is extremely appreciated.
Thank you!