Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6016215
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T02:57:03+00:00 2026-05-23T02:57:03+00:00

It possible to rewrite url of the form http://website.com/page.php to http://page.website.com , and when

  • 0

It possible to rewrite url of the form
http://website.com/page.php to http://page.website.com, and when I enter an url such as
http://page.website.com, it will treat it as http://website.com/page.php?

When I am on the page, can the address bar continue showing http://page.website.com ? How can I achieve all this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T02:57:04+00:00Added an answer on May 23, 2026 at 2:57 am

    You can change your default directory page to include “page.php”. In that case, it would be served if you requested the directory.
    Add the following to the .htaccess’s DirectoryIndex line

    DirectoryIndex page.php ...
    

    Also refer to this.

    EDIT:

    Whichever pages you want the server to search for within the directory, when you try to request the folder, you specify them in order in the DirectoryIndex part of your .htaccess.

    e.g.

    If you have an index.html and a page.php, in the same www.site.com/example/example2 folder, apache serves the index.html by default. But you can override this behavior using the .htaccess file.

    If you want the server to serve the page.php when you request for www.site.com/example/example2, put it in your .htaccess as DirectoryIndex page.php.

    Then, that will ensure that it serves the php page.
    Hope I was clear! Read this!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is it possible to re-write (Apache Mod-Rewrite) a URL from this: http://www.example.com/view.php?t=h5k6 to this
If I am mod_rewriting a URL from: http://www.mysite.com/blog/this-is-my-title/1/ to http://www.mysite.com/blog.php?title=this-is-my-title&id=1 ...is it possible then
Possible Duplicate: How to rewrite URL without refresh, like GitHub.com Hi all, I have
Possible Duplicate: Please URL Rewrite in php I would like visitors to access the
I have a rewrite in nginx or Apache for this address: http://domain.com/hello to a
I have this URL: http://hostX.site.com/some_path_here/filename.jpg and need to rewrite it to: http://host.site.com/same_path_here/filenameX.jpg Can you
The actually URL which my app uses is: http://site.com/search.php?search=iPhone but I would like it
Possible Duplicate: mod_rewrite - how to rewrite an URL? Hi can anyone of you
I want to rewrite the URL of a page in my website. Its basicly
Is is possible to use Tuckey's URL Rewrite to rewrite to a different Tomcat

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.