PDA

View Full Version : link problem


muddysmurf
07-01-2009, 11:11 AM
This has probably been covered before, but here goes:

I've linked all of my links in the nav bar to go to separate pages inside the folder locally. For example, my Directions tab goes to directions.php.

Menu writer adds a / in front which makes it /directions.php. This works locally when I try to go to different pages.

I get the site online, and when I click on the directions tab, it tries to take me to mydomain.com/mysitefolder/directions.php and not mydomain.com/directions.php

I don't want to take out code that says assumed root, so how do I fix this without having to change the navigation every time I make changes locally and then put it live?

Much Appreciated,
Leslie

Ray Borduin
07-01-2009, 11:30 AM
It should check to make sure the folder exists first... does /mysitefolder/ exist on your live server?

The assumed root takes a local root and remote root argument that are set in the top of the code based on your site definition. There is no way for it to really know if you are on one server or the other, so it tests to see if the folder exists if it doesn't it uses the other path. You may be able to switch the local and remote root values or remove or rename that folder if it isn't needed.

muddysmurf
07-01-2009, 12:15 PM
the mysitefolder doesn't exist live, because the folder that the entire website is in locally is called mysitefolder.

I don't need that folder once I upload it live.

All of my pages are hanging out in the public_html folder, live.

www.sayre-speedway.com is the link

xag
07-01-2009, 12:26 PM
your site isn't live

muddysmurf
07-01-2009, 12:59 PM
your site isn't live

that's what I get for talking on the phone and typing, added an s that wasn't there.

www.sayre-speedway.com

muddysmurf
07-02-2009, 06:40 AM
I took out the "local" folder name at the top of the menu.php file. That seemed to work, but now every time I update the file using the edit content button, I am going to have to change it before I upload it :(

Wish there was a different way to do it.

Ray Borduin
07-02-2009, 07:42 AM
It sounds like a bug or maybe a problem with your site settings... what were the settings for local and remote in that file before you changed them?

muddysmurf
07-02-2009, 08:38 AM
local was the name of 'mysitefolder'

I don't have the file where i'm at right now so I can't look at the remote one, but I only touched the local.

Ray Borduin
07-02-2009, 08:41 AM
I'd like to know the other. Maybe neither were correct. Although you fixed it by updating the local, the problem may have actually been in the remote.

muddysmurf
07-02-2009, 09:11 AM
This is what it is now:
$WA_localRoot = "/";
$WA_remoteRoot = "/";

local did have "mysitefolder" before