JQuery Tabs not populating / assigning

JQuery Tabs not populating / assigning

I'm new to jquery but I've completed the basic tutorials.  Most of the examples I've seen use pure html and javascript but I'm trying to use PHP.

I have the basic TAB object setup and of course it works with hard-coded text - but fails when trying to populate it with a PHP variable.

$('#tab-doc').html('Test');                                     // Works fine

$('#tab-doc').html(' ?> print $html; <?php ');        // This fails

I've also tried:
print "$('#-tab-doc').html('test');";   // Works fine


I have a DIV in the $html variable, perhaps that's related to the problem, but I need to populate DIVs and Tables in the TAB context.