Hi all!
I have just begun learning PHP and I'm currently trying to make a sort of video-system so I can keep track on which videos I have 🙂
But I have a little problem ... I have made a link on the title which should go to a php-document that shows details of the video ... it also works fine on most titles, but it doesn't work on the titles with a "single quote" in the title - for example Wayne's World ... the file I'm linking to in the HREF is for example:
video.php?title=Wayne's World
But as I click the link it only tries to get "video.php?title=Wayne" and leaves out the rest ...
I'm well aware of the fact that I need to use some sort of replace function, but none of the things I've tried seems to be working for me, so that's why I wanted to know if people here could be of help?
The system is a bit more complicated than what I described above, so unfortunately it's not possible to just execute the HREF and instead of the title replace it with an ID.
That was problem no. 1 ... problem no. 2 is a sorting rows problem. The videos have a number which I had to make a "varchar" since there are also letters in them (original tapes for example) ... but as I try to order the videos by that number, it sorts the numbers like this:
1
10
100
101
11
12
2
21
and so on ...
I realize that I would need to make an "order by 0+number" for it to work, but then all the original tapes with the "org" number will come first and I don't want that ... does anyone know how to solve that problem?
I'm sorry this might sound really confusing, but I hope someone will be able to help me out ... otherwise please do ask me to be a bit more specific about the problem! Thanks in advance!
/// NetRoam