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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T11:12:58+00:00 2026-05-19T11:12:58+00:00

I am using the jQuery.history plugin in my webpage and I am stuck with

  • 0

I am using the jQuery.history plugin in my webpage and I am stuck with a little problem. I have the following layout for my webpage:

  • http://www.myDomain.com
  • http://www.myDomain.com/#home.php
  • http://www.myDomain.com/#otherPage.php
  • … more of that

So when going to my website at www.myDomain.com, it actually loads index.php, which is quite logical. Inside index.php, I say: include('home.php');. So google can check the contents of my first page. $.history stores the www.myDomain.com link in its plugin. Which is still fine.

  1. Now, I go through my menu and click on Home. Which will direct me to my homepage. But of course, I was already there. The problem is that the link of my Home button is #home.php, because I do an ajax request with $.history. So my webpage fades out and the same content is coming in.

  2. When I am on otherPage and press ctrl+R, I first get my homepage and then the webpage is unloaded and otherPage comes in. Which is annoying, because I would like to get otherPage direct.

So my question is: How can I make sure, that the first page (so without a hash) is directly loaded when there is no hash? And how can I make sure that the homePage isn’t loaded I am going to another hash?

It seems quite logical that it is going wrong, but I don’t see the workaround, because PHP can’t get the hash of the link. This is for the user agent only. And I was thinking about setting an extra variable or something when going to my page, but still, that would make the href’s not the same anymore and $.history would not recognize the same links.

UPDATE

This demonstration actually shows what I am talking about:

http://balupton.com/sandbox/jquery-ajaxy/demo/

When you are on the page and scroll down to the TABS section. Using jQuery Ajaxy as header; It shows an empty section. And clicking the tabs will fill it of course. When refreshing the page, it will again start with the empty page and then fill it with the right content you wanted. My thing is: I don’t want a blank starting page.

Thanks in advance!

  • 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-19T11:12:59+00:00Added an answer on May 19, 2026 at 11:12 am

    Ok, so I created a workaround… finally.

    In my main page, I do a standard include(). And do not set it to display: none. But I do so in a javascript later on with: document.write('<style>#content{display:none;}</style>');

    So now, google will find the normal page. When someone loads the page. The first included page is just ignored. And because we init the $.history object, the page will do a $('#content').show(); after the first ajax call.

    PS. I would like to mention that I should have start off with the jquery.address plugin, instead of this one. Maybe I’ll refactor it someday.

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

Sidebar

Related Questions

I have a problem , i'm using jQuery plugin from http://www.stilbuero.de/jquery/tabs/ , plugin for
I am using this plugin: http://plugins.jquery.com/project/history on this page: http://www.crtaci.info/index.php?autocom=majice I dont know why
I'm using jquery.history plugin in my web-app and have a problem with '/' being
I have setup some tabs using jquery tools and the history plugin. When i
I'm using jQuery and PHP, I have a problem with history.pushState . When I
I'm using jquery.history lugin found here: http://tkyk.github.com/jquery-history-plugin/ With this i load content into a
I am using the jQuery form validation plugin. The problem I have is that
I'm using jQuery BlockUI Plugin and I'd like to do Javascript:history back(); after Click
I'm using the jquery BBQ plugin for my ajax hashchange events and history states.
I'm using the BBQ jquery plugin for AJAX history management, but I'm having a

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.