Foren
Javascript navigate in theme error
Bach Hoang, geändert vor 7 Jahren.
Javascript navigate in theme error
New Member Beiträge: 15 Beitrittsdatum: 30.09.13 Neueste Beiträge
I created a new theme in liferay 6.2.
But It's only run smoothly within Administrator role, when I used Power User role to sign in, my menu has problem.
I used javascript in theme:
I can navigate to other page with Administrator role.
But when user Power User or other role to sign in, when I click (mouse down)in menu which is invisible and visible when mouse up.
So that page can not navigate, in this case, I have only one way which is right click and "open link in new tab". It's ok.
Help me please!
But It's only run smoothly within Administrator role, when I used Power User role to sign in, my menu has problem.
I used javascript in theme:
var menu = A.one('#navigation');
var subMenu = A.all('.child-menu');
menu.on('click', function(event) {
subMenu.setStyle('display','block');
});
var subMenu2 = A.one('#main-content');
subMenu2.on('click', function(event) {
subMenu.setStyle('display','none');
});
var obj = A.one('#showHideTop');
var show = A.all('.dockbar');
obj.on('click', function(event) {
if (show.getStyle('display')=="block") {
show.setStyle('display','none');
}
else {
show.setStyle('display','block');
}
});
I can navigate to other page with Administrator role.
But when user Power User or other role to sign in, when I click (mouse down)in menu which is invisible and visible when mouse up.
So that page can not navigate, in this case, I have only one way which is right click and "open link in new tab". It's ok.
Help me please!
Byrån Zaugg, geändert vor 7 Jahren.
RE: Javascript navigate in theme error
Expert Beiträge: 252 Beitrittsdatum: 06.04.12 Neueste Beiträge
Using the browser's Dev Tools, I would look at how the markup differs between accounts, when logged in.