Trouble with question mark in URL
Posted: Sun Jun 27, 2010 1:29 am
Hey guys!
I'm having some trouble with something. Right now, the process for submitting and displaying an "article" is roughly this:
1. They enter some text (the article), and a title
2. A script cleans the title, replaces spaces with _'s
3. It names the file the text is kept in the cleaned article name
4. When you go to a page with the articles, it turns the _'s back into spaces to print the link to the article
5. There is also a thumbnail for the article, named <cleaned article name>.jpg
But I'm having a problem when an article's title has a question mark in it. When I look at the thumbnail in my client, it lists it with a question mark. For example: does_this_work?.jpg . And when I go to the directory in my browser, it is labeled the same. But if I click on it and view the picture directly, it has %3f in the url. I know this has something to do with the fact that ? is actually a delimiter in URL's, but I'm trying both ways (having the picture titled with %3f's instead of ?'s) and it's not working.
Can anyone enlighten me? Thanks!
I'm having some trouble with something. Right now, the process for submitting and displaying an "article" is roughly this:
1. They enter some text (the article), and a title
2. A script cleans the title, replaces spaces with _'s
3. It names the file the text is kept in the cleaned article name
4. When you go to a page with the articles, it turns the _'s back into spaces to print the link to the article
5. There is also a thumbnail for the article, named <cleaned article name>.jpg
But I'm having a problem when an article's title has a question mark in it. When I look at the thumbnail in my client, it lists it with a question mark. For example: does_this_work?.jpg . And when I go to the directory in my browser, it is labeled the same. But if I click on it and view the picture directly, it has %3f in the url. I know this has something to do with the fact that ? is actually a delimiter in URL's, but I'm trying both ways (having the picture titled with %3f's instead of ?'s) and it's not working.
Can anyone enlighten me? Thanks!