Can anyone show me how I can hide my full URL
instead of displaying:
http://www.mydomain.com/index.php?name=123
but only display:
all the time.
Can I do this without changing any setting in Apache?
Can anyone show me how I can hide my full URL
instead of displaying:
http://www.mydomain.com/index.php?name=123
but only display:
all the time.
Can I do this without changing any setting in Apache?
Use 2 frames. Make a "0%" and a "100%" frame, where your application will run.
You can't avoid having the full path. However, with frames you will have the url you want but you will face other frame-related problems
John
I would according to web design usability recommend not to hide your URL if you don't have a veeery good reason to do it. It will only "trick" your users and not give them the right URL in case they want to share your link or use it in any other situation(bookmarks etc.).
Of course you would have to make sure users cannot access pages that doesn't "exist" on your site, but this shouldn't be to much of a problem.
I'm not an expert, but this is my personal opinion based on my work with different sites the last years...
Yeah, its mean to your users and to search engine spiders to hide your URLs...
But that frame idea is your best bet. Note though they can still get to your page if they view the source and know what they're doing.
Originally posted by superwormy
Yeah, its mean to your users and to search engine spiders to hide your URLs...
But that frame idea is your best bet. Note though they can still get to your page if they view the source and know what they're doing.
however there is javascript code that you can use to enfore that any page visited that should be inside the 0% frame can automatically redirect to the page with frames.
And then there are those of us who know what we're doing and turn Javascript off... :-)
I have a situation where I'd like to hide the URL also...but for those who know what they are doing the above frame or javascript solutions would not work.
Situation Explained:
I have a PHP/MySQL message board.
At the bottom of each page is a link for next and previous which, when clicked, cause the next page's URL info to look something like:
http://mywebsite.com/messageboard/view.php?display=10&sort=&entry=10&search=
If someone where to change the value of entry from 10 (entries displayed per page) in the URL to 20000, then 20K posts displayed on a page could really bog down the server.
How do I achieve controlling the display without putting the info in the URL?
Like anything coming from the client, you should validate it before you use it. Look at the display value and if it's outside a sensible range (1..50, say) force it to some sensible default (like 10). If they try something silly like 20000 or -35 or smellmyfeet, they get ten.
Of course, if it's not something that the user can choose, and it's always going to be ten, it doesn't need to be in the URL at all. ("Hi, I want ten results." "Yes, I know already.")