Milonic provide full featured pull down web menus for some of the worlds largest companies
click here to see what it can do for you

Download Milonic DHTML Menu
Buy Milonic DHTML Menu

Back To Start Of Archive
Taken From The Forum: Archived Topics for the old Version 3.0 JavaScript Menu
Forum Topic: Click to view post
Last Updated: Wednesday July 18 2012 - 06:07:30

PHPSESSID ruining things only the 1st time u browse the page


Poster: Talloula
Dated: Tuesday July 23 2002 - 18:11:40 BST

if i browse my page in a new browser window, the menu doesn't appear
and there's errors in the page.

if i hit refresh, everything works great. i did a compare on the two sources and here's the difference.

before hitting refresh:
Code:
else{if(ns4){hlnk="<a href="\?PHPSESSID=ab19f83147c87e463f92148dafafc01e"""+hlnk+"\" "+ltarg}else{hlnk=

after hitting refresh it becomes:
Code:
else{if(ns4){hlnk="<a href=\""+hlnk+"\" "+ltarg}else{hlnk=


i cannot change the server's php settings.
is there a way to modify the script to prevent this, I assume the server is automatically inserting the PHPSESSID wherever it sees a href="....
right?


Poster: Andy
Dated: Wednesday July 24 2002 - 9:53:41 BST

You could try changing mmenu.js and replace all href's with a split version like this

Code:
else{if(ns4){hlnk="<a hr"+""+"ef=\""+hlnk+"\" "+ltarg}else{hlnk=


I'm not sure at what point PHP is parsing mmenu.js so the above might not work though.

Also, if you have mmenu.js named mmenu.js then you must tell PHP not to parse .js files but I'm assuming you have renamed the .js file as .php

-- Andy


Poster: Talloula
Dated: Wednesday July 24 2002 - 14:41:08 BST

I thought that I "had" to rename it to .php
is it possible to leave the file as a js and then include it in the code?

and if i do that, how do I tell php not to parse .js files?

thanks for all the prompt help, this is a great menu!!!
Talal

it worked!


Poster: Talloula
Dated: Thursday July 25 2002 - 21:34:21 BST

breaking apart the "href" worked, no more PHPSESSID

and I also left the mmenu.js as a js file, and i just echoed the <script src=...></script> line in php and it worked like a charm.

thanks
Talloula