WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to implement some AJAX to my theme, but there are a few things I cannot get my head (or Google) around.

I have a custom post type named "Faculty" and a page displaying the featured image for each entry in the custom post type in a grid that links to /faculty/entry1, /faculty/entry2 etc.

Instead of loading a new page with the content I'm trying to load the content above the grid using the admin-ajax.php file.

But how can I implement this leveraging the current "pretty" permalinks?

What I would like to achieve is that the user clicks the featured image and the url will change to /faculty/item2 and I will receive the content for item2 via AJAX. And if the user manually enters /faculty/item2 in the browser the same faculty page will load with the content from item2.

I really hope the explanation makes sense - and that somebody can give me a pointer in the right direction.

EDIT: This is an example of the functionality I'm looking for, just with the WordPress permalinks implemented: http://themewich.com/aware/

share|improve this question

You can do that with html5 history API with which you can change the URL at the address bar whenever you want. Works on anything modern which is not IE, but maybe this utility will help with IE.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.