Hmm.. by the quote in my previous post you refered to the global variable "$mosConfig_live_site" which is the value found in the configuration.php.
Say you want reference to the file "file.php" using the live site it would be:
Code: Select all
<?php
echo $mosConfig_live_site.'/file.php';
?>
I think it really depends on the script... say the script uses some kind of variable $path...
Code: Select all
<?php
$path = '/index.php';
// ... some other code
echo $mosConfig_live_site.'/'.$path;
?>
Then you get a double slash because the $path variable already contains that slash.
Another cause could be an empty variable (for whatever reason) which is assumed not to be empty... for example like this:
Code: Select all
<?php
echo $mosConfig_live_site.'/'.$option.'/file.php';
?>
If $option happen to be empty this also leads to a double slash.
In both of the last cases you may remove the slash as a quick "fix"... but you could run into other problems with the same script when $path happen to not contain that slash or $option is not empty.
After all one could also "fix" it like this:
Code: Select all
<?php
echo preg_replace('%[-:]//%', '/', $mosConfig_live_site.'/'.$option.'/file.php');
?>
(not tested though... just to give the idea).
But since you say that the following produces a double slash:
Code: Select all
<?php
echo $mosConfig_live_site.'/templates/css/template_css.css';
?>
... and you insist that the global configuration is correct... then you may have a script that is adding it? For example the one which reads the host server variable to work with different domains (e.g.: localhost vs. external access).
Sorry, it is my developers brain that had to mention it.