Permalinks and jquery Error
-
Hello,
I need help with reloading some part of page, actualy i want to make reload some content (post) on my wordpress blog without reloading page.. simple users can click on refresh button and get new post …Im make random.php file and im include in my page this file, so there is 6 random posts…
<?php include ‘random.php’;?>
So now i need reload this part on click without reloading all page, im try found solution on the google but cant find any good tutorial orMy code:
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.5.2/jquery.min.js" ></script> <script type="text/javascript" > var $j = jQuery.noConflict(); function ajaxs_request() { $.get('random.php', function(data) { $('#random').html((data)); }); } </script> <div id="random"><?php include 'random.php';?></div>So all this works very fine if i have Permalinks on Default (http://localhost/wordpress/?p=123)
But when i change Permalink script cant load random.php files, im try change extension to random.html and works but i need to load php..
So where can be problems.. im also try on localhost without any plugins and same…
The topic ‘Permalinks and jquery Error’ is closed to new replies.