隐藏在 PHP 中的 URL [英] URL hiding in PHP

查看:28
本文介绍了隐藏在 PHP 中的 URL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在 php 中显示另一个 url 或主域名而不是文件名?例如,假设我被重定向到文件 http://example.com/myfolder/test.htm,然后我想在地址栏中显示example.com,而不是指定的网址.怎么办?

How do I display another url or main domain name instead of filename in php? For example suppose I am redirected to file http://example.com/myfolder/test.htm, then instead of specified url I want to display example.com in the address bar for such url. How can it be done?

推荐答案

你可以用 .htaccess 做到这一点,这里有一个有用的 链接.

you can do this with .htaccess here is a useful link.

这篇关于隐藏在 PHP 中的 URL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆