is it possible to hide the paths on the address bar ?
Moderator: General Moderators
is it possible to hide the paths on the address bar ?
I was wondering, is it possible to hide the files you are opening in the address bar ?
ie, instead of the address being displayed as http://www.bob.com/somedir/spiffy.php
could it be displayed as
http://www.bob.com/
In case there are any questions, this is saying I own the domain bob.com ( which I don't, but it's just an example... )
if this is possible, could someone point me in the right direction? Thanks
ie, instead of the address being displayed as http://www.bob.com/somedir/spiffy.php
could it be displayed as
http://www.bob.com/
In case there are any questions, this is saying I own the domain bob.com ( which I don't, but it's just an example... )
if this is possible, could someone point me in the right direction? Thanks
- twigletmac
- Her Royal Site Adminness
- Posts: 5371
- Joined: Tue Apr 23, 2002 2:21 am
- Location: Essex, UK
Use Javascript. I am sure there is something for you at http://www.hotscripts.com 
Alternatively - yes, frames are created by HTML, but administered by Javascript. There should a tutorial at http://www.webmonkey.com about frames
Alternatively - yes, frames are created by HTML, but administered by Javascript. There should a tutorial at http://www.webmonkey.com about frames
shouldn't using POST data and reafiles work too?
example:
as long as its post data it wont show in the main page, you wouldn't see the directory paths for the readfiles. is there some php taboo im breaking here?? or some security concern?
example:
Code: Select all
<?
switch ($_POSTї'op']){
case "page1":
page1();
break;
case "page2":
page2();
break;
default:
index();
break;
};
page1(){
readfile("./somedir/spiffy.php");
}
page2(){
readfile("./somedir/biffy.php");
}
index(){
//your index here
};
?>Any Other Ways?
Is there any other ways of doing this, I'm thinking in the lines of META, Header() or HTTP, without javascript and frames?
Yes, but no
Thats interesting, but I'd rather have the address bar with just the domain only for each page accessed.
I thought this might work, but it does not;
<meta name="Identifier-URL" content="http://www.Domain.Com">
I'm thinking maybe something in Header() or maybe;
$URL = $HTTP_HOST or $SERVER_NAME
I thought this might work, but it does not;
<meta name="Identifier-URL" content="http://www.Domain.Com">
I'm thinking maybe something in Header() or maybe;
$URL = $HTTP_HOST or $SERVER_NAME
Easy answer, not really.
Opening up anew window wont work as a user easy can make it visible again.
Making it invincible in frames will be spotted viewing the source of the page.
header() will just redirect the user to a different page.
Require(), include(), readfile() might be an option, as you are displaying a file thats not on the same (i assume) location as the actual page being viewed...
Opening up anew window wont work as a user easy can make it visible again.
Making it invincible in frames will be spotted viewing the source of the page.
header() will just redirect the user to a different page.
Require(), include(), readfile() might be an option, as you are displaying a file thats not on the same (i assume) location as the actual page being viewed...
Easier answer: I'm pretty sure this is something that mod_rewrite can handle easily. I've never tried telling it to report that everything is just the root domain, but I can't think of a reason why it wouldn't work. Of course, if you're not on an Apache server you'll have to think up something else.
But I should mention: using frames is a terrible idea. Unless you're on an intranet or somesuch, or there's some very specific application of your site that I can't think of, the cost-to-benefit ratio of frames is horrible. People need to stop using them, circa three years ago.
But I should mention: using frames is a terrible idea. Unless you're on an intranet or somesuch, or there's some very specific application of your site that I can't think of, the cost-to-benefit ratio of frames is horrible. People need to stop using them, circa three years ago.
A search of url cloaking finds:
"Q. What is URL cloaking?
--------------------------------------------------------------------------------
A.
It is where a user types in a domain name into their browser, but ends up at a different URL. This can be achieved through DNS settings for your domain name.
Importantly, unlike with URL forwarding , it is the domain name itself that is displayed in the browser bar, the destination URL is "cloaked" by the use of browser "frames".
This is an excellent technique to use in a variety of circumstances. For example you may want to hide an affiliate code or an overly long URL. However the method does have inheritent limitations. For example, if the URL being forwarded to is on a secure server, browsers won't be able to detect this and the padlock won't display."
"Q. What is URL cloaking?
--------------------------------------------------------------------------------
A.
It is where a user types in a domain name into their browser, but ends up at a different URL. This can be achieved through DNS settings for your domain name.
Importantly, unlike with URL forwarding , it is the domain name itself that is displayed in the browser bar, the destination URL is "cloaked" by the use of browser "frames".
This is an excellent technique to use in a variety of circumstances. For example you may want to hide an affiliate code or an overly long URL. However the method does have inheritent limitations. For example, if the URL being forwarded to is on a secure server, browsers won't be able to detect this and the padlock won't display."
I found that iframe works a lot better, iframe is alot more compatable (to my knowledge) and doesnt require a bunch of files..
Try using this on the page you want it to always show up as:
<BODY TOPMARGIN=0 LEFTMARGIN=0>
<iframe FRAMEBORDER="0" width=100% height=100% src="Content.php" name="Content"></iframe>
Change that iframe the the main page of the page you want to show up, and it will always show up as that file in the url
Try using this on the page you want it to always show up as:
<BODY TOPMARGIN=0 LEFTMARGIN=0>
<iframe FRAMEBORDER="0" width=100% height=100% src="Content.php" name="Content"></iframe>
Change that iframe the the main page of the page you want to show up, and it will always show up as that file in the url
