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 8414115
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T01:05:18+00:00 2026-06-10T01:05:18+00:00

I have seen in WordPress, when you create a page say Register, it points

  • 0

I have seen in WordPress, when you create a page say “Register”, it points to http://example.com/register/ but without having a folder named register in the root at all. How is this done?

Its like this. When a user clicks the link on http://example.com/index.php which says Register, it takes the user to a new page and the URL in the browser would be http://example.com/register/ and the page loads. The register folder itself does not exist.

From the answers below I learnt that the request is passed through the index.php by modifying the .htaccess

I want to know what code to place in index.php so that http://example.com/register/ would display the register page.

  • 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-06-10T01:05:19+00:00Added an answer on June 10, 2026 at 1:05 am

    In my WordPress .htaccess file I have:

        RewriteCond %{REQUEST_FILENAME} !-f
        RewriteCond %{REQUEST_FILENAME} !-d
        RewriteRule . /index.php [L]
    

    Which basically says if the “filename” part of the URL doesn’t exist as a file !-f or exist as a directory !-d then rewrite the request internally to be /index.php which forces the request to be processed by index.php of WordPress.

    Ok, based on your additional comments, the following .htaccess rules will take http://domain.com/<anything> and internally rewrite it to http://domain.com/index.php?page=<anything>, this will be done without regard to case (NC flag) and will keep (pre-pend) any existing query string (QSA flag). This only does this for filenames and directories that do not exist on the server.

        RewriteCond %{REQUEST_FILENAME} !-f
        RewriteCond %{REQUEST_FILENAME} !-d
        RewriteRule ^(.*)$ /index.php?page=$1 [NC,QSA,L]
    

    This does have the following side effect which you should be able to handle programmatically, http://domain.com/register/ will be rewritten to http://domain.com/index.php?page=register/ which includes the trailing “/” since this is a directory reference. Again, you should be able to handle that in your PHP code.

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

Sidebar

Related Questions

I have seen many examples of creating a custom titlebar: http://zaman91.wordpress.com/2010/03/16/android-how-to-add-custom-title-bar/ Is there a
I have seen in a few libraries, Spray for example, dual package specifications like
I have seen this talked about but never answered. Maybe it has and I'm
I have seen other questions on here related to this, but I have their
Have seen that this piece of code could solve my problems but I don't
Have seen multiple posts on this but I can't see any which answer my
I have seen that is indeed possible to compile Wordpress with HPHP and was
Hi I just got into wordpress theme development and I have seen many developers
Hi I'm trying to make a menu like one I have seen but cant
Ok, we have all seen this question a million times, but I am looking

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.