Individuals would be the sites I have been researching probably the most attempting to wrap my mind around json

This really is my php

if (have_posts()) :  
    while (have_posts()) : 
        $fvsc []= "\n" . '<div id="featuredv-' . "$wp_query->current_post\">" . "$post->post_content;" . '</div>';
$jsonObject= json_encode($fvsc);   

which is my .js

    jQuery.getJSON("<?php TEMPLATEPATH . '/featuredv.php'?>",function(data){
        var fvsJA=jQuery.parseJSON(<?php $jsonObject; ?>);
        var fts = $("#ttContent>[id^=featuredt]");  
        var fvs = $("#inCenter>[id^=featuredv]");
    }); function(){   
        $("#inCenter>[id^=featuredv]").replaceWith( function(){

What I am attempting to do is make my $fvsc array right into a jQuery array. $fvsc is a range of videos, whenever a fts is clicked on it will go ahead and take items in a div and change it with another video which has exactly the same index as whichever fts was clicked on. Should you just load all of the fts and fvs into one place you should use the press function here and delay pills work great but when you echo out 5 videos after which later 10 and so forth the website loads even worse. I figured basically could convert my php array right into a jquery object that loads json strings after that time click converts back to an item and replaces the div contents the burden would degrade better.

I see several issues inside your code:

  1. $fvsc []= "\n" . '<div id="featuredv-' . "$wp_query->current_post\">" . "$post->post_content;" . '</div>';

    I do not think you are able to wrap class's variable in double quote. It ought to be something similar to this:

    $fvsc []= '<div id="featuredv-' . $wp_query->current_post . '">' . $post->post_content . '</div>';
  2. There's problem inside your JS, particularly, how you access URL. The thing is, ajax in wordpress is a little diverse from the standard php. Take a look here to learn more: