[CRE Loaded] SEO causing issue with javascript

Magic SEO URLs for CRE Loaded.
ebreaka
Posts: 12
Joined: Fri Apr 17, 2009 5:12 pm

[CRE Loaded] SEO causing issue with javascript

Postby ebreaka » Tue Apr 21, 2009 12:53 pm

Hi,

since I have installed the SEO on my CRE loaded store, i just noticed that my "dhtml" javascript menu is not working anymore in internet explorer only... it show in every other browsers but not IE ?

If I put a static link, it's working, but then im getting problems with SSL and my green bar so I can't use any static urls to fix this issue...

it seems when SEO is active, the javascript link is not the same... being relative to my /template folder... Any idea to fix this issue ?

When I am on a products page, where the SEO is working... the menu not working again also...
Last edited by ebreaka on Fri Jun 05, 2009 10:49 am, edited 1 time in total.

inveo
Inveo Support
Posts: 1285
Joined: Sat Feb 02, 2008 12:07 pm
Contact:

Re: [CRE Loaded] SEO causing issue with javascript

Postby inveo » Tue Apr 21, 2009 1:55 pm

Try to add to includes/header_tags.php file before this line:

Code: Select all

echo ' <meta http-equiv="Content-Type" content="text/html; charset=' . CHARSET  . '">'."\n";


following code:

Code: Select all

echo ' <!--[if IE]></base><![endif]-->'."\n";

ebreaka
Posts: 12
Joined: Fri Apr 17, 2009 5:12 pm

Re: [CRE Loaded] SEO causing issue with javascript

Postby ebreaka » Wed Apr 22, 2009 1:01 am

Thanks for your suggestion but it doesnt fix my issue... :(

inveo
Inveo Support
Posts: 1285
Joined: Sat Feb 02, 2008 12:07 pm
Contact:

Re: [CRE Loaded] SEO causing issue with javascript

Postby inveo » Fri Apr 24, 2009 8:27 am

Such JS issues are cased by unclean JS coding. I can try to make it work, but FTP login details are required.

inveo
Inveo Support
Posts: 1285
Joined: Sat Feb 02, 2008 12:07 pm
Contact:

Re: [CRE Loaded] SEO causing issue with javascript

Postby inveo » Sun Apr 26, 2009 6:40 am

Thank you for FTP login details. I have fixed this issue by changing code in templates/Original1_B2B/main_page.tpl file.

Following code:

Code: Select all

<script type="text/javascript" src="includes/js/prototype.js"></script>
<script type="text/javascript" src="includes/js/scriptaculous.js?load=effects"></script>
<script type="text/javascript" src="includes/js/lightbox.js"></script>
<script type="text/javascript" src="templates/Original1_B2B/dhtml-menu/stmenu.js"></script>
<script type="text/javascript" src="includes/js/rollover.js"></script>


has been changed to:

Code: Select all

<script type="text/javascript" src="<?php echo DIR_WS_CATALOG; ?>includes/js/prototype.js"></script>
<script type="text/javascript" src="<?php echo DIR_WS_CATALOG; ?>includes/js/scriptaculous.js?load=effects"></script>
<script type="text/javascript" src="<?php echo DIR_WS_CATALOG; ?>includes/js/lightbox.js"></script>
<script type="text/javascript" src="<?php echo DIR_WS_CATALOG; ?>templates/Original1_B2B/dhtml-menu/stmenu.js"></script>
<script type="text/javascript" src="<?php echo DIR_WS_CATALOG; ?>includes/js/rollover.js"></script>

ebreaka
Posts: 12
Joined: Fri Apr 17, 2009 5:12 pm

Re: [CRE Loaded] SEO causing issue with javascript

Postby ebreaka » Tue Apr 28, 2009 11:48 am

it sound good, it seems working fine...

Thanks a lot for your support :D

ebreaka
Posts: 12
Joined: Fri Apr 17, 2009 5:12 pm

Re: [CRE Loaded] SEO causing issue with javascript

Postby ebreaka » Tue Apr 28, 2009 11:52 am

this fix is creating me an other problem... SSL now see the links as non secure items... :(

if you click on member login to go on https, you'll see...

inveo
Inveo Support
Posts: 1285
Joined: Sat Feb 02, 2008 12:07 pm
Contact:

Re: [CRE Loaded] SEO causing issue with javascript

Postby inveo » Tue Apr 28, 2009 12:37 pm

Please replace the code with:

Code: Select all

<script type="text/javascript" src="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>includes/js/prototype.js"></script>
<script type="text/javascript" src="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>includes/js/scriptaculous.js?load=effects"></script>
<script type="text/javascript" src="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>includes/js/lightbox.js"></script>
<script type="text/javascript" src="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>templates/Original1_B2B/dhtml-menu/stmenu.js"></script>
<script type="text/javascript" src="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>includes/js/rollover.js"></script>

ebreaka
Posts: 12
Joined: Fri Apr 17, 2009 5:12 pm

Re: [CRE Loaded] SEO causing issue with javascript

Postby ebreaka » Tue Apr 28, 2009 3:21 pm

:( it doesnt work also... still asking to show non secure items... but the menu is available when displaying the non-secured items... knowing the the problems is coming from this one:

Code: Select all

<script type="text/javascript" src="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>templates/Original1_B2B/dhtml-menu/stmenu.js"></script>


as the only way i found to solve the non secure item problem is by removing everything before the "templates/Original1_B2B/dhtml-menu/stmenu.js" so the link becoming relative rather then static... but that way... magic prevent the menu working... hummm

I had so much pain with lots of menu, as usual css menu using jquery are creating conflicts with javascripts... :cry:

inveo
Inveo Support
Posts: 1285
Joined: Sat Feb 02, 2008 12:07 pm
Contact:

Re: [CRE Loaded] SEO causing issue with javascript

Postby inveo » Tue Apr 28, 2009 3:29 pm

Are you sure that asking to show non secure items is caused by MSU? I think the problem comes from stmenu.js file (by removing absolute path you only did that this file is not loaded and therefore you don't see any warning message).