简体   繁体   中英

Is it possible to hide a .php extension or replace .php with .html in a URL without htaccess?

I have tried to find the answer, but I failed. Other questions are with htaccess .

I found this question similar of my question, but I did not get my answer.

I need it without .htaccess , because I do not have permission of URL rewriting in my client's server.

How can I achieve this?

If you don't have access to your .htaccess or httpd.conf file the you could set up a proxy (like nginx) in front of the web server, point the DNS record to this proxy and have the proxy rewrite the requests from .html to .php to pass on to your apache server.

However, if you don't have access to .htaccess or httpd.conf files, you probably don't control the DNS records...

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM