Back To Start Of Archive
Taken From The Forum: Help & Support for DHTML Menu Version 5+
Forum Topic: Click to view post
Last Updated: Saturday July 14 2012 - 06:07:38
Designing local, then uploading
Poster: Sharkbait
Dated: Sunday March 18 2007 - 15:54:04 GMT
I'm in the process of redesigning my company's website, and am building it on a local machine to then upload to the site server. Building the site using a combo of Dreamweaver and Expression Web.
My question is about the path structure in the menu scripts. Currently the script I'm inserting into the header of each html file looks like this:
Code:
<SCRIPT language=JavaScript src="/menu/milonic_src.js" type=text/javascript></SCRIPT>
<script language=JavaScript>
if(ns4)_d.write("<scr"+"ipt language=JavaScript src=/menu/mmenuns4.js><\/scr"+"ipt>");
else _d.write("<scr"+"ipt language=JavaScript src=/menu/mmenudom.js><\/scr"+"ipt>"); </script>
<SCRIPT language=JavaScript src="/menu/menu_data.js" type=text/javascript></SCRIPT>
<script language=JavaScript>
if(ns4)_d.write("<scr"+"ipt language=JavaScript src=/menu/mmenuns4.js><\/scr"+"ipt>");
else _d.write("<scr"+"ipt language=JavaScript src=/menu/mmenudom.js><\/scr"+"ipt>"); </script>
<SCRIPT language=JavaScript src="/menu/menu_data.js" type=text/javascript></SCRIPT>
The Milonic files are stored in a subdirectory (menu) off of the main root directory. At the moment, with the site only existing locally, I preview and the menu doesn't show up at all. I assume because the path isn't correct for the local version. When I go live, is that the correct path syntax? I'd hate to upload the site, then try and troubleshoot the thing.
Related question. If I uploaded the site to a subdirectory on my current site for testing (so the base path would be something like http://www.whitesharkphoto.com/testsite/ ), would that path syntax look out to the main root? I think it would. I guess an option would be to upload it to the /testsite folder and just adjust all the links temporarily, then do a global find-replace on them all.
...or is there an easier way that I'm not seeing? Ideally I'd like to see it locally so that I can edit quickly, but I can't see a way to do it easily and keep the paths working.
Cheers,
John
Poster: Ruth
Dated: Monday March 19 2007 - 0:32:22 GMT
Hi,
Paths are the bane of my existence On your local you are probably not getting the menu because it's assuming http where the path is something else. I think, don't take that for gospel.
OK, given your setup of [http://www.whitesharkphoto.com/testsite/] if you are going to create a subfolder under that folder called testsite, then if you use a ../ this would mean that they are to look in the parent folder of the page's folder, so ../menu/filename would say look in testsite/menu, assuming you are putting the pages in the folder testsite.
If you did it that way, then when you put the pages back into the root directory, you should just be able to remove the .. leaving /menu/ and that will say look in the root directory for a folder called menu and then find the file called whatever file.
I hope that made sense.
As to the local setup, aren't there things you can use like Apache to set it up on your computer to 'mimic' your website?
http://www.milonic.com/apachesetup.php
Hope something here helps.
Ruth