Whenever i select a category like users/content etc from administrator area the submenus are getting displayed 6 times. Like the below picture for Users.
Debug: Administrator template (hathor/index.php) Line 92:
<jdoc:include type="modules" name="submenu" style="rounded" id="submenu-box" />
var_dump("test");
This is where the mod_submenu
is included and the submenus are displayed.After the var_dump
i get only one output (wanted to test if i were inside a loop) , so i thought that the problem would be inside the mod_submenu
.
Altough i noticed that the whole code of mod_submenu is executed inside a
<ul id="submenu">
But the output after i inspected the page is this for each line :
<div id="submenu-box">
<div class="m">
<ul id="submenu"></ul>
If the mod_submenu was executed 6 times i would have something like that for output:
<div id="submenu-box">
<div class="m">
<ul id="submenu"></ul>
<ul id="submenu"></ul>
<ul id="submenu"></ul>
etc..
Now the output is this:
<div id="submenu-box">
<div class="m">
<ul id="submenu"></ul>
</div>
</div>
<div id="submenu-box">
<div class="m">
<ul id="submenu"></ul>
</div>
</div>
<div id="submenu-box">
<div class="m">
<ul id="submenu"></ul>
</div>
</div>
etc...
So if im not mistaken <jdoc:include type="modules" name="submenu" style="rounded" id="submenu-box" />
creates both <div id="submenu-box">
and <div class="m">
.
After alot of debugging i came to the conclusion that the include statement and only that ( the rest code of hathor is running normally ) is executed 5 more times.
I thought of getting rid of the 5 extra divs using jquery. altough the problem is that there are 6 divs with the same id. So i tried to change the id="submenu-box"
on include to class="submenu-box"
. after i refreshed the page, instead of having a <div class="submenu-box">
i had an empty <div>
. Cant i use a class with the jdoc:include
?
Has anyone encountered something like that before ? Or anyone has any idea what could be the problem ? I Hope i was clear enough.
P.S: error_log is empty !