Home     Articles & Projects     Products & Web Services

Problem With Output Display Of Links In My Menu.php On Site

I have a affiliate script developed that creates a mysql table and parse it into my site. My problem is on some sites using certain templates where my categories having 2 or more words, the categories are displayed correctly, but on other sites using the same script and menu.php code in the categories section of template the displayed words with 2 or more words have an "_" for the space between the words. I am wondering what would cause this. The css file or something within the php coding that works for some templates or sites but not others.

Hi Roy, This would almost

Hi Roy,

This would almost certainly be to do with the script rather then the CSS. It would be worth openning menu.php in a text editor and searching for "_" to see if you can find it being used anywhere in a way that would cause it to replace out spaces with underscores.... you may find it within an str_replace function for example...

Cheers,
David.

First Off, Happy New Year to

First Off, Happy New Year to you and thanks for the response.
Alright Dave I opened the menu.php and found the problem. I changed it and the underscore disappeared from my menu correctly, but now it messes up the url with a % sign in it and becomes a dead link when the category is clicked. I have 2 more questions for you also following this. Below is a partial of the code to my menu.php

while ($fetchc=mysql_fetch_array($queryc))
{
$ctgy=$fetchc["Category"];
if (!empty($ctgy))
{
$ctgyasci=str_replace(' ','_',$ctgy);
echo "<li><a href='$url/cat/$ctgyasci/0.html'>".$ctgyasci."</a></li><hr />";
}
}
}
}

2. I also need to create an rss feed and an sitemap to my site some kind of way. What would you suggest be a good way to create either from the entire mysql database.

3. One more question is I had another php script created for an thumbplay api file. It allows me to enter any Artist Name or Album into a search url for to come up with a page dynamicaly for that artist. My Example site is "www cellphoneringtonecreator com/artist/Artist_Name.html". I can enter any artist's name in the artist folder and it pulls their information dynamically from the api file. I would like to create a sitemap and rss feed for this type of site also from a list of maybe 1000 artist or album titles.

Once again I appreciate the help.