Originally Posted by farout
So I have my main php-page (ajax #!) that loads all other html-pages as dynamic content.
When a dynamic page is loaded the title and description of my main page stays the same.
How can I display a unique title tag and description for each dynamic page
and will that show up in search results as well?
For one example, on window load you can loop through the menu container and set onclick event handlers on all of the anchor tags present in that menu. The onclick event handler in those cases can trigger an AJAX request function that will check the href of the link that was clicked, append a $_GET variable to the URL to mark it as an AJAX request (e.g. "?ajax=1"), and then query the very same PHP file as before with that slightly modified URL. Now, when the AJAX request marker is present in the URL requested your PHP page can be set up to SKIP outputting everything (html, head, body tags, etc.) EXCEPT the page contents that you want to deliver.