Alright I've been at this for a few hours and I'm not totally frustrated, just wanting to make sure that there's not some obvious solution here that I'm missing. I have an album review site and I'd like for my visitors to be able to use links that are easy to remember (I just yesterday got a leg up on mod_rewrite and have already got some nicer looking urls going). For example instead of (mod_rewritten url) mysite.com/albums/32, I'd instead pass the actual title of the album (pulled from mysql query) into the url parameter using dashes. replacing: albums/32 with: albums/The-Album-Title Right now this works like a charm, I've got a url prep function that adds dashes into whitespaces in the title, and I've got a small 'cleaner' function that strips the dashes out of the title and then passes it via sprintf into a mysql query and the review details are pulled based on that. So the query ends up like: $query_Review = sprintf("SELECT albums.REVIEW FROM albums where albums.NAME LIKE '%%%s%%'", $colname_TITLE); My issue is when whatever I'm trying to pass in the URL parameter already has dashes in it. When I put it through url preparation it adds dashes to any whitespace, and then the dashes are stripped out on the details page for the mysql query. Despite my best efforts (within my realm of knowledge) I've been unable to get it to leave the original dashes in there, while stripping the prep dashes out. Any original dashes are also stripped, which throws off the mysql query and doesn't return anything. Am I missing something obvious here?
Nevermind I've sorted it. I went with converting the name fields to fulltext indexes and doing a match against in the query and its working out fine.