简体   繁体   中英

Why won't my page display unless I put an .html at the end of URL?

For some reason after transferring to a new server my invoices page and script aren't working. When a customer enters his information it is put in the database and it creates an invoice like so:

/Invoices/JohnDoe 10100188

However the URL should open up a nice invoice page with all the info for the order, instead I get a 404 Error now. Nothing has changed with the script or databases. We simply moved them to a new server and all the included files. What's even stranger is that when you add .html to the end of JohnDoe 10100188 it will load the page. I don't know why but do I need to make my script add .html at the end now? It is confusing to me why this won't work now.. I was hoping someone had a similar problem and could help me out. I would be greatly appreciative!

I'm not too familiar with Apache, but my guess would be that there's a configuration setting where you can set a default file extension for the case when one is not supplied.

Could be in .htaccess, or one of the Apache config files.

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