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

  • Home
  • SEARCH
  • 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 1053157
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T17:12:32+00:00 2026-05-16T17:12:32+00:00

So I learned from this handy guide how to use .htaccess to redirect pretty

  • 0

So I learned from this handy guide how to use .htaccess to redirect pretty URIs like foobar.com/baz to specific content that may reside at foobar.com/bazheader345.php?user=baz.

What if I’d like to do the opposite? My anchors are static but I have a lot of content in different files – and none of them has a particularly pretty name. Say I have a page at foobar.com called 123.html and would like the location bar to remain http://foobar.com despite the navigation between files that the user does.

Can this be done via changes to .htaccess? Or simply Javascript?

If it is possible, would it interfere with the browser’s history states?

  • 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-16T17:12:33+00:00Added an answer on May 16, 2026 at 5:12 pm

    This is really easy to do with HTML frames. Let’s say your home page is http://example.com/index.html. Save index.html as home.html and save something like the following in index.html:

    <html>
      <head>
        <title>Website title</title>
      </head>
      <body>
        <iframe src="home.html" width="100%" height="100%" frameborder="0" scrolling="no" />
      </body>
    </html>
    

    If you don’t want to rename your original home page, you could instead stick a DirectoryIndex directive in your .htaccess file. Just save the above code in, say, frame.html, change home.html to whatever filename your index is at, and add:

    DirectoryIndex frame.html
    

    to your .htaccess file.

    However, you should know that this practice fell out of style over 10 years ago because it has inherent problems. It won’t break your history, but it breaks deep linking (that is, one can’t bookmark or link to anything other than the home page).

    More info:

    • Frames Suck Most of the Time
    • Why Are Frames So Evil?
    • Framing Critique on Wikipedia
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I learned about how to browse my local App Engine Datastore from this handy
I learned from this article that to avoid confliction between javascript libraries, use jQuery.noConflict();
After what I learned from my previous question , I would like to use
I learned from books that you should write for loop like this: for(var i=0,
As I just learned from this question , .NET regexes can access individual matches
From this question I learned Double.NaN is not equal to itself. I was verifying
To preface this, the most I know about text encoding I learned from Joel
From browsing on this site and elsewhere, I've learned that serving websites as XHTML
I have learned so much from http://www.summerofnhibernate.com/ nhibernate screen casts that i wonder why
UPDATE: I recently learned from this question that in the entire discussion below, I

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.