Zen Cart Logo
Forums / General Questions / Extra Forward Slash Before Links...

Extra Forward Slash Before Links...

Locked

Views: 1,154

Results 1 to 6 of 6
This thread is locked. New replies are disabled.
20 Aug 2010, 10:55 PM
#1
gaffettape avatar

gaffettape

Zen Follower

Join Date:
May 2009
Posts:
433
Plugin Contributions:
0

Extra Forward Slash Before Links...

I was just looking at my sites page source and noticed that the links to the stylesheets all have a forward slash / before them like this:

<link rel="stylesheet" type="text/css" href="[B]/[/B]includes/templates/my_template/css/stylesheet.css" />

I have looked at a few other Zen Cart showcase stores and believe they shouldn't (?) have the forward slash and should in fact look like this:

<link rel="stylesheet" type="text/css" href="includes/templates/my_template/css/stylesheet.css" />

What could cause this to happen? Have I edited something wrongly in the configure.php files - I can paste them into this thread if required.

Thanks :smile:

20 Aug 2010, 11:27 PM
#2
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Extra Forward Slash Before Links...

Well ... if it's not preventing your stylesheets from loading, then there's nothing wrong with it.
ie: if your site really is in the webroot of your hosting account, then it's perfectly fine.

But, yes, if it ails you, then you can remove the slash by editing your configure.php file.

20 Aug 2010, 11:36 PM
#3
gaffettape avatar

gaffettape

Zen Follower

Join Date:
May 2009
Posts:
433
Plugin Contributions:
0

Re: Extra Forward Slash Before Links...

DrByte:

Well ... if it's not preventing your stylesheets from loading, then there's nothing wrong with it.
ie: if your site really is in the webroot of your hosting account, then it's perfectly fine.

But, yes, if it ails you, then you can remove the slash by editing your configure.php file.

What would you do?

21 Aug 2010, 1:10 AM
#4
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Extra Forward Slash Before Links...

If it's not causing any actual problems, then I'd just leave it.

If it's bothering you, I'm guessing you've got a preceding / in this line unnecessarily:```
define('DIR_WS_INCLUDES', 'includes/');

21 Aug 2010, 1:37 PM
#5
gaffettape avatar

gaffettape

Zen Follower

Join Date:
May 2009
Posts:
433
Plugin Contributions:
0

Re: Extra Forward Slash Before Links...

Hi Dr. B,

Thanks for the reply.

I looked in both the configure.php files and they both looked like this:

define('DIR_WS_INCLUDES', 'includes/');

So that seemed to be ok. Do you know of anything else that could cause this?

I know you have already said that if it was you then you would just leave it, but I'll quite happily admit I'm a little pedantic about these sorts of things lol :blush:

I was thinking about another thing you said: "if your site really is in the webroot of your hosting account" - I'm on a dedicated server (although not yet live) could this be affecting anything?

Thanks.

21 Aug 2010, 1:58 PM
#6
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Extra Forward Slash Before Links...

No, being a dedicated server or not doesn't affect how it reads and uses the data from the config files.