0
votes
1answer
33 views

Retrieving post ID from current page

I am following the tutorial here. Wordpress Ajax is a bit complicated but this tutorial helped me out a bit. The only question I have is, when I view any page, I want to be able to get the current ...
0
votes
1answer
54 views

Ajax Call in page theme not working?

Ok, i am VERY new to wordpress (2 Hours new). I am creating a page template, which works fine, but this is the issue i am having: In the template.php file, i have this code: <script ...
0
votes
1answer
109 views

How to render the single post template with the post name?

I'm calling pages with Ajax and I have this code in functions.php to determine which page is called and then, render the corresponding template: function ajax_callback() { if( isset( ...
1
vote
0answers
25 views

Different template for second page result for Ajax-loading new pages [duplicate]

Everytime I enter a posts page, index.php is called. Now on the site I load next pages (page2, page3...) with Ajax and insert the posts (just the posts) from the Ajax result inside my page. This works ...
0
votes
2answers
346 views

How to add a “ waiting” icon for an ajax in WP frontend?

This is my search js code for processing search : jQuery(document).ready(function($){ $('#searchsubmit').click(function(e){ e.preventDefault(); var searchval = $('#s').val(); ...
-6
votes
3answers
431 views

Jquery Slider for profile template

I want to show the posts under a category in my page.The first 5 posts should be shown when the page loads and When the user clicks the next button/link next 5 posts should be shown. Currently I show ...
0
votes
0answers
17 views

Custom .php page that contains json for dynamically loaded content [duplicate]

Possible Duplicate: How can I use WordPress functions in my stylesheet? For my wordpress blog, I would like to use some JS to load dynamic content into the sidebar of my cached pages. I was ...
2
votes
1answer
93 views

How to get full content including template HTML

I'm looking to get the page content between the header and footer (as Wordpress already does) that includes the template HTML (as this is going to be an AJAX request). Is there a function that will ...
0
votes
1answer
59 views

Load featured article once in a loop

I'm working on a WP-Touch theme and I have a template file that looks like this: <?php get_header(); ?> <?php locate_template( 'featured-post.php', true, false ); ?> <?php ...
0
votes
2answers
204 views

AJAX requests within templates

I'm trying to come to an accurate decision here about safe ajax requests from a template. The thing about AJAX that always scares me is that the called script location is public: ...
3
votes
1answer
2k views

Template issues getting ajax search results

I'm trying to put search results into a div with ajax. The issue is I'm getting errors saying undefined function have_posts() when the the search template is accessed. It also took issue with ...
4
votes
1answer
2k views

wp_get_attachment_image returns different image size

It is a bug? wp_get_attachment_image( $attachment_id, 'post-thumb-size-small'); Same code, called in template, and in AJAX call returns same image SRC, but different image width and height. dumb ...
2
votes
1answer
310 views

Sharing templates with the JSON API?

Is there any way to share 'templates' between JS and Wordpress? For instance, this sort of modest seat-of-the-pants templating feels ok: var AJAXSuccessFunc = function(data){ // calling this on ...
3
votes
3answers
7k views

Load entire NextGEN gallery from single thumbnail?

I'm using Alex Rabe's NextGEN Gallery in a lot of client sites as a centralized image repository, and am finding I often need to load an entire gallery into a lightbox (invoked via a single ...
3
votes
2answers
540 views

Add a preview to a Wordpress Control Panel

I'm trying to create a new wordpress template and inside it I added a Control Panel, inside this control panel there is an option that allows user to choose where he want's to place a on a map, I try ...