Support Forum

Advanced Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
themes-topic
Jquery issues When using a RocketTheme wordpress theme on guest View
Avatar
Lee Erickson
Member
sp_UserOfflineSmall Offline
Jul 5, 2013 - 6:49 am

Hello support,

So we are using SP current version on this site : http://www.businessmentors101.com/forum/, the REALLY odd thing and this is wierd, you get a bunch of javascript errors when accessing the page as a guest BUT if you even login as a lowely subscriber user, the menu works and the errors go away. So it is some js file that is not getting loaded as a guest. We are using a default SP theme. Wondering if you have a solution that we can follow for this problem?

Your Help will be greatly appreciated.

Thanks

Avatar
Yellow Swordfish
Glinton, England
SP Master
sp_UserOfflineSmall Offline
Jul 5, 2013 - 8:48 am

I see jQuery is being loaded but it is being loaded very late in the game - so something is forcing that. The forum is not the only set of scripts causing errors. There are some from your theme and from other plugins as well.

But try this. Go to the forum admin > Integration > Page and Permalink panel and set the option to load JavaScript in the footer. See if that helps with the forum at least.

andy-signature.png
YELLOW
SWORDFISH
Avatar
Lee Erickson
Member
sp_UserOfflineSmall Offline
Jul 5, 2013 - 4:42 pm

Hi,

I tried that with the setting you suggested but it still doesn't work and further, I disabled ALL the plugins but for simple press and gantry+theme and it still does messes up the menu ONLY on the forum page, ONLY when your not logged in :/ Any thoughts?

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jul 5, 2013 - 4:51 pm

is this rocket theme based on gantry? which operates largely outside of the wp api...  like replacing all the wp head stuff..

we have worked with their guys before to work around theme stuff...  worth reading:

https://simple-press.com/suppo.....rk-themes/

but try going forum - integration - page and permalink, and enabling the bypass wp head check option...

Avatar
Lee Erickson
Member
sp_UserOfflineSmall Offline
Jul 5, 2013 - 6:19 pm

Hi,

I read that and tried the solutions, with no avail, that is not really my problem anyway.

To show you I created a short video so that you may see exactly what is happening:

https://www.evermorevideos.com/bug/

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jul 5, 2013 - 10:07 pm

I am not sure what that video is showing - not much info...

and we dont have different js for guests vs users...

the error you allude to was in the fusion.js and I see similar when visiting the site...  oddly its the first js file loaded on your site (that I can see since guests cannot really get in)... its loaded before even jquery which could part of the issue...  or perhaps it really doesnt need jquery - cannot tell... 

when logged in as a user, is the order of loading different?  you can view the page source as guest and user to compare...

also the error is occurring in mootools which is also known to conflict on occasion with wp/jquery... which brings up another question, where is mootools??  why is it loaded in the middle of the page?  that is improper for js loading...  its getting loaded as part of the login form... why???  is the plugin/theme being too greedy and getting confused by a wp login form in the forum header??  is the theme or plugin (since gantry has both theme and plugin here) do anything special with a login form???  this definitely be a difference between logged in or not...  a source compare should answer this quite quickly...

if the theme or plugin is doing incorrect things because of a login form, you primary choices will be to fix the theme/plugin, or disable the of the inline login form within the forum...

Avatar
Lee Erickson
Member
sp_UserOfflineSmall Offline
Jul 5, 2013 - 10:55 pm

Well sorry the video didn't come through, that's what I explained in the video that, the moo tools is loading in the middle of the page ONLY on the forum page when your a guest. period.

All other pages load it in the header just fine.

I have ALL plugins disabled but gantry and simplepress so its not another plugin.

Yes as a guest on the forum page it moves 2 JUST 2 of the JS calls to the middle of the page which is really odd.

I don't know if the theme that is a rockettheme is doing anything special, I have tried 3 different rocket themes and they ALL have the same problem.

And like I said once you log in it works fine...

Can I give you my login credentials to see?

Avatar
Lee Erickson
Member
sp_UserOfflineSmall Offline
Jul 5, 2013 - 10:58 pm

Oh and just to try it how does one disable the inline login form in the forum?

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jul 5, 2013 - 11:46 pm

in your spHead.php template file of the theme you are using, comment out this line:

sp_LoginForm($loginForm);

some plugins/themes are specific enough when targeting the wp login page and sometimes force undesired actions on login forms in content or sidebars...

as always, we recommend using your own sp theme and not editing one of ours directly... see:

http://codex.simple-press.com/.....g-a-theme/

if that fixes the theme/plugin issue (not sure how you disabled all other plugins btw since gantry is part plugin), we can help change our link from opening the login form to be a link to the wp login form instead...

> Simple:Press Support > Friday, July 05, 2013 7:58 PM >postbox-contact-1.jpg

Avatar
Lee Erickson
Member
sp_UserOfflineSmall Offline
Jul 6, 2013 - 1:43 am

I meant I disabled all plugins BUT Gantry and Simple Press and of course the theme. So I knew it wasn't a plugin (other than Gantry) issue caused by one of the OTHER plugins.

However I figured it out:

On line 21 of 

/wp-content/plugins/simple-press/forum/content/forms/sp-form-login.php

If I change:

do_action('login_head', 'sploginform');

To:

do_action('sploginform');

removing the 'login_head', it now works like it should. In fact I can log in and log out and the menus are not broken and the java is being called in the right place.

Do you have any idea why 'login_head', would conflict like that? What is it for and will I be ok with out it?

Forum Timezone: Europe/Stockholm
Most Users Ever Online: 1170
Currently Online:
Guest(s) 1
Top Posters:
Mr Papa: 19448
Ike: 2086
Brandon: 864
kvr28: 804
jim: 650
FidoSysop: 577
Conrad_Farlow: 531
fiddlerman: 358
Stefano Prete: 325
Member Stats:
Guest Posters: 620
Members: 17365
Moderators: 0
Admins: 4
Forum Stats:
Groups: 7
Forums: 17
Topics: 10128
Posts: 79626