2 javascripts problem
<pre><code>&lt;?php
global $user;
$userId = $user-&gt;uid;

/* start with default */
$myresult = "";


/* All Includes - start */
include_once('db.php');
include_once('valid-scripts/validateData.php');

/* All Includes - end */

/* Build All required Variables - start */

$alias               = $_GET['alias'];
$product             = $_GET['product'];
$product             = strtolower(substr($product,0,-1));
$master_table        = $product.'_master';
$rating_master_table = $product.'_rating_master';
$rating_table        = $product.'_rating';
$numProperties       = 15;

/* Build All required Variables - end */

/* Add all Styles required - start */ 

$myresult .= '&lt;link href="/jquery.rating.css" type="text/css" rel="stylesheet"/&gt;';


/* Add all Styles required - end */ 


/* Show Hide Variables/parameters - start */ 

include_once('all_include_files/show_hide.php');

/* Show Hide Variables/parameters - end */

/* All Javascript - start */
//$myresult .= '&lt;script src="/jquery.rating.js" type="text/javascript" language="javascript"&gt;&lt;/script&gt;';
?&gt;
&lt;style&gt;
#tabs {
//font-size: 90%;
//margin: 20px 0;
margin: 2px 0;
}
#tabs ul {
float: right;
background: #E3FEFA;
width: 600px;
//padding-top: 4px;
}
#tabs li {
margin-left: 8px;
list-style: none;
}
* html #tabs li {
display: inline; /* ie6 double float margin bug */
}
#tabs li,
#tabs li a {
float: left;
}
#tabs ul li a {
text-decoration: none;
//padding: 8px;
color: #0073BF;
font-weight: bold;
}
#tabs ul li.active {
background: #CEE1EF url(/all_include_files/img/nav-right.gif) no-repeat right top;
}
#tabs ul li.active a {
background: url(/all_include_files/img/nav-left.gif) no-repeat left top;
color: #333333;
}
#tabs div {
//background: #CEE1EF;
clear: both;
//padding: 20px;
min-height: 200px;
}
#tabs div h3 {
text-transform: uppercase;
margin-bottom: 10px;
letter-spacing: 1px;

#tabs div p {
line-height: 150%;
}
&lt;/style&gt;

&lt;script src="/jquery.rating.js" type="text/javascript" language="javascript"&gt;&lt;/script&gt;


&lt;script src="/jquery.metadata.js" type="text/javascript" language="javascript"&gt;&lt;/script&gt;
&lt;script type='text/javascript'&gt;

function openComment(number)
{
alert('working');
$('#comment'+number).css('display','');
}
$('.star').rating({
callback: function(value, link){
alert(value);
}
});
$(document).ready(function() {

//$('#tabs div').hide(); 
//$('#tabs div:first').show(); 
$('#tabs ul li:first').addClass('active'); 
$('#tabs ul li a').click(function()
{ 
$('#tabs ul li').removeClass('active'); 
$(this).parent().addClass('active'); 
var currentTab = $(this).attr('href'); 
$('#tabs div').hide(); 
$(currentTab).show(); 
return false;
});


    $("#clickit").click(function() {
$.post("/mobile/tablechange.php",{ p1:'&lt;?php echo $brand ?&gt;',p2:'&lt;?php echo $model ?&gt;',userid:'&lt;?php echo $userid ?&gt;' } ,function(data){
 $("#changetable").html(data);
});
    });


$('div.expandable p').expander({
    slicePoint:       200,  // default is 100
    expandText:         'more &amp;raquo;', // default is 'read more...'
    collapseTimer:    0, // re-collapses after 5 seconds; default is 0, so no re-collapsing
    userCollapseText: '[^]'  // default is '[collapse expanded text]'
  });


});
&lt;/script&gt;
&lt;?php
/* All Javascript - end */

/* Form Processing after submit - start */
/* Form Processing after submit - end */

/* Actual Form or Page - start */

/*fetch all data needed */

/* initial query */

$result_product = query_product_table($product,$alias);

/*fetch property names of product */
$product_properties = master_table($master_table);

/*rating table query */
$master_rating_properties = master_rating_table($rating_master_table);


/*get user ratings*/
$user_ratings = user_ratings($userId,$alias,$rating_table);


$myresult .= '&lt;div class=\'Services\'&gt;';
//$myresult .="&lt;form name ='form1' id='form1' method = 'POST' action='".$_SERVER['php_self'] ."'&gt;";

if(!$result_product)
{  header('Location: /page-not-found'); }
else
{
$row_product = mysql_fetch_array($result_product);

  $myresult .= "&lt;h3 class='newstyle'&gt;".$row_product['alias']." &lt;a style='float:right;padding-right:20px;color:white;text-decoration:underline;' href='/'&gt;Back&lt;/a&gt; &lt;/h3&gt;";

/* start actual product display - start*/
$myresult .= "&lt;div class=\"product\"&gt;";

/* start table 1*/
$myresult .= '&lt;table border=\'0\' cellspacing=\'0\' cellpadding=\'0\' style=\'width:580px; table-layout:fixed;\'&gt;';

$myresult .= '&lt;tr&gt;';

$myresult .='&lt;td valign=\'top\'&gt;';

/* start table 2*/
$myresult .='&lt;table width=\'100%\' border=\'0\' cellspacing=\'0\' cellpadding=\'0\'&gt;';

$myresult .= '&lt;tr&gt;';

$myresult .= '&lt;td valign=\'top\' style=\'width:164px;\'&gt;';

/* start table 3*/
$myresult .= '&lt;table style=\'width:164px;\' border=\'0\' cellspacing=\'0\' cellpadding=\'0\'&gt;';

$myresult .= "&lt;tr&gt;";

/* start of the pic row */
$myresult .= '&lt;td  align=\'center\' class=\'various_product\'&gt;';
 if($row_product['pic'] != "")
        {
$myresult .= '&lt;ul id=\'mycarousel\' style=\'display:\';&gt;';

$myresult .= '&lt;li&gt;&lt;a href=\'/all_image_scripts/origpicdisplay.php?product='.rawurlencode($product).'&amp;alias='.rawurlencode($alias).'&amp;picid=pic&amp;p= \'rel=\'lightbox[roadtrip]\'&gt;&lt;img src=\'/all_image_scripts/picdisplay1.php?product='.rawurlencode($product).'&amp;alias='.rawurlencode($alias).'\'&gt;&lt;/img&gt;&lt;/a&gt;&lt;/li&gt;';

for($p = 1; $p &lt;= 4; $p++)
 {
if($row_product['pic'.$p] != "")
  {

$myresult .= '&lt;li&gt;&lt;a href=\'/all_image_scripts/origpicdisplay.php?product='.rawurlencode($product).'&amp;alias='.rawurlencode($alias).'&amp;picid=pic'.rawurlencode($p).'&amp;p='.rawurlencode($p).'\' rel=\'lightbox[roadtrip]\'&gt;&lt;img src=\'/all_image_scripts/thumbpicdisplay.php?product='.rawurlencode($product).'&amp;alias='.rawurlencode($alias).'&amp;picid=pic'.rawurlencode($p).'\'&gt;&lt;/img&gt;&lt;/a&gt;&lt;/li&gt;';

  }
        }
$myresult .= '&lt;/ul&gt;';

 }
else
{
$myresult .= "&lt;img width='50' height='70' src='/images/no-image.gif'&gt;&lt;/img&gt;";
}
jcarousel_add('#mycarousel', array('horizontal' =&gt; TRUE,'scroll' =&gt; 1,'visible' =&gt; 1));

$myresult .= "&lt;/td&gt;";
/* end display of pic td*/

$myresult .= "&lt;/tr&gt;";
/* end display of pic tr*/
$myresult .= "&lt;/table&gt;&lt;/td&gt;";

/* end display of pic table and earlier td - Still 1 open TR td table tr -hint*/

$myresult .= '&lt;td style=\'width:450px;\'&gt;';

/*table - 4*/
$myresult .= '&lt;table width=\'100%\' border=\'0\' cellspacing=\'0\' cellpadding=\'0\' style=\'display:block;\'&gt;';


/* Start showing property and values */
$myresult .= '&lt;tr&gt;';

$myresult .= '&lt;td class=\'tick\'&gt;&lt;img src=\'/images/ul_li_bg.gif\' width=\'12\' height=\'12\' /&gt;&lt;/td&gt;';

$myresult .= '&lt;td class=\'leftText\'&gt;'.ucfirst($product).':&lt;/td&gt;';

$myresult .= '&lt;td class=\'rightText\'&gt;'.$row_product['alias'] .'&lt;/td&gt;';

$myresult .= "&lt;/tr&gt;";

for($j = 3; $j &lt;= 5 ; $j++){

if($product_properties['property'.$j.'_name']  != "")
{

if($row_product['property'.$j]  != "")
{

$myresult .= '&lt;tr&gt;';

$myresult .= '&lt;td class=\'tick\'&gt;&lt;img src=\'/images/ul_li_bg.gif\' width=\'12\' height=\'12\' /&gt;&lt;/td&gt;';

$myresult .= '&lt;td class=\'leftText\'&gt;'.$product_properties['property'.$j.'_name'].':&lt;/td&gt;';

$myresult .= '&lt;td class=\'rightText\'&gt;'.$row_product['property'.$j] .'&lt;/td&gt;';

$myresult .= '&lt;/tr&gt;';
}
/* end if*/
}
/* end if*/
}
/* end for*/

/* show hide block */
$myresult .= '&lt;tbody id=\'extra_properties\'  style=\'display: none;\'&gt;';

for($j = 6; $j &lt;= 15 ; $j++){

 if($product_properties['property'.$j.'_name']  != "")
{

if($row_product['property'.$j]  != "")
{
$myresult .= '&lt;tr&gt;';

$myresult .= '&lt;td class=\'tick\'&gt;&lt;img src=\'/images/ul_li_bg.gif\' width=\'12\' height=\'12\' /&gt;&lt;/td&gt;';

$myresult .= '&lt;td class=\'leftText\'&gt;'.$produtc_properties['property'.$j.'_name'].':&lt;/td&gt;';

$myresult .= '&lt;td class=\'rightText\'&gt;'.$row_product['property'.$j] .'&lt;/td&gt;';

$myresult .= '&lt;/tr&gt;';
} 
/* end if*/
}
/* end if*/
}
/* end for */
 $myresult .= '&lt;/tbody&gt;';
/* end show/hide tbody */

$myresult .= '&lt;tr&gt;';

$myresult .= '&lt;td&gt;';
$myresult .= '&amp;nbsp;';
$myresult .= '&lt;/td&gt;';

$myresult .= '&lt;td&gt;';
$myresult .= '&amp;nbsp;';
$myresult .= '&lt;/td&gt;';

 $myresult .= '&lt;td align=\'right\' style=\'text-align:right;text-decoration:underline;\'&gt;';

$myresult .= '&lt;a class=\'right_link\' href=\'javascript:showMore()\'&gt;Show Additional Details...&lt;/a&gt;';

$myresult .= '&lt;/td&gt;';
$myresult .= '&lt;/tr&gt;';

/* End showing property and values */

$showreview = 'display:';
/* review show hide */
/*$myresult .= '&lt;tbody '.$showreview.'&gt;';
$myresult .= '&lt;tr&gt;';

$myresult .= '&lt;td colspan=\'2\'&gt;&lt;span class=\'reviews\'&gt;';

//check 
//$numreviews = getreviewcount($brand,$model,'mobile_user_reviews');
if($numreviews &gt; 0)
{
$myresult .= '&lt;a href=\'mobilereviews?alias='.rawurlencode($alias).'\'&gt; &lt;span&gt;$numreviews Reviews&lt;/span&gt;&lt;/a&gt;';
}
else
{
$myresult .= " $numreviews Reviews";
}
$myresult .= "&lt;/span&gt;&lt;/td&gt;";

 $myresult .= "&lt;/tr&gt;";
*/
 $myresult .= "&lt;/tbody&gt;";
/* review show hide - end */


/* count show hide */
$myresult .= '&lt;tbody '.$showcount.'&gt;';
$myresult .= '&lt;tr&gt;';

$myresult .= '&lt;td colspan=\'2\'&gt;&lt;span class=\'reviews\'&gt;';

//check 
//$totalvotes = gettotalvotes($row['property1'],$row['property2'],'mobile_rating');

$myresult .= "&lt;/td&gt;";
 $myresult .= "&lt;/tr&gt;";
 $myresult .= "&lt;/tbody&gt;";
/* count show hide - end */


$myresult .= "&lt;/table&gt;&lt;/td&gt;";
/* end table 4 */

$myresult .= '&lt;/tr&gt;';
/* end 1 row  and remaining  tr , td ,table */


 $myresult .= '&lt;/table&gt;&lt;/td&gt;';

 $myresult .= '&lt;/tr&gt;';

/* remianing only 1 table */


/* ratings - positive last section starts here */
$max= array();
for ($l = 1 ; $l &lt; 15; $l++){
if($row_product['property'.$l.'_avg']){
$maxarray = 0;
$maxarray = $row_product['property'.$l.'_avg'];

$max['rating'.$l.'_name'] = $maxarray;
}
}

if(count($max) &gt;0 )
{
include('all_include_files/min_max_properties.php');
}

if(($row_product['freshness'] &lt;= strtotime("-3 month")))
{  $image_type= 'old';  }

else if(($row_product['freshness'] &lt;= strtotime("-2 month")))
{ $image_type= 'bitold'; }

else if(($row_product['freshness'] &lt;= strtotime("-1 month")) || ($row_product['freshness'] &gt; strtotime("-1 month")))

{ $image_type= 'new'; }

$img_name = $image_type;


$myresult .= "&lt;tr&gt;";
 $myresult .= "&lt;td&gt;";
 $myresult .= "&lt;table width='100%' border='0'&gt;";

 $myresult .= "&lt;tr&gt;";

 $myresult .= "&lt;td width='170' class=\"ratingz\"&gt;&lt;span&gt;&lt;u&gt;Overall rating&lt;/u&gt;&lt;/span&gt;&lt;/td&gt;";

 $myresult .= "&lt;td width='150' class=\"ratingz\"&gt;&lt;span&gt;&lt;u&gt;Positive&lt;/u&gt;&lt;/span&gt;&lt;/td&gt;";

 $myresult .= "&lt;td  width='150' class=\"ratingz\"&gt;&lt;span&gt;&lt;u&gt;Negative&lt;/u&gt;&lt;/span&gt;&lt;/td&gt;";


if($img_name == 'new'){
$images = "&lt;img src='/sites/default/files/battery-discharging-100.png' width='40' height='40'&gt;&lt;/img&gt;";
}
else if($img_name == 'bitold'){
$images = "&lt;img src='/sites/default/files/battery-discharging-80.png' width='40' height='40'&gt;&lt;/img&gt;";
}
else if($img_name == 'old'){
$images = "&lt;img src='/sites/default/files/battery-discharging-0.png' width='40' height='40'&gt;&lt;/img&gt;";
}
else {
$images = "";
}

$myresult .= "&lt;td rowspan='2'&gt;&lt;p ".$showbattery."&gt;". $images ."&lt;/p&gt;&lt;/td&gt;";



 $myresult .= "&lt;/tr&gt;";

 $myresult .= "&lt;tr&gt;";
 $myresult .= "&lt;td&gt;";
 $i++;

        for($k = 0.5; $k &lt;= 10.0; $k+=0.5)
        {
        $overall = roundOff($row_product['overall_rating']);
                if($overall == $k)
                {
                        $chk ="checked";
                }
                else
                {
                        $chk = "";
                }
 $myresult .= '&lt;input class=\'star {split:2}\' type=\'radio\'   value=\''. $k .'\' '.$chk.' title=\''. $k.' out of 10 \' disabled /&gt;';

        }

 $myresult .= '&lt;/td&gt;';

 $myresult .= '&lt;td &gt;&lt;span&gt;'.$positive.'&lt;/span&gt;&lt;/td&gt;';


 $myresult .= '&lt;td &gt;&lt;span&gt;'.$negative.'&lt;/span&gt;&lt;/td&gt;';


 $myresult .= '&lt;/tr&gt;';

 $myresult .= '&lt;/table&gt;&lt;/td&gt;';
 $myresult .= '&lt;/tr&gt;';

/* ratings - positive last section ends here */


 $myresult .= '&lt;tr&gt;';


if($row_product['description'] != ""){

if(words_count($row_product['description']) &gt; 8){

 $myresult .= '&lt;td&gt;&lt;p&gt;&lt;span class=\'description\'&gt;&lt;strong&gt;&lt;u&gt;Description&lt;/u&gt;:&lt;/strong&gt;&lt;/span&gt;&amp;nbsp;&amp;nbsp;  &lt;div class=\'expandable\'&gt;&lt;p&gt;'.$row_product['description'].'&lt;/div&gt;&lt;/p&gt;&lt;/p&gt;&lt;/td&gt;';

}
else
{
$myresult .= '&lt;td&gt;&lt;p&gt;&lt;span class=\'description\'&gt;&lt;strong&gt;&lt;u&gt;Description&lt;/u&gt;:&lt;/strong&gt;&lt;/span&gt;&amp;nbsp;&amp;nbsp;'. $row_product['description'] .'&lt;/p&gt;&lt;/td&gt;';
}
}
 $myresult .= '&lt;/tr&gt;';

 $myresult .= '&lt;/table&gt;';
/* end 1st table */

$myresult .= '&lt;/div&gt;';
/* start actual product display - end*/

/*start the form to take ratings */
$myresult .= '&lt;div id=\'tabs\'&gt;';


$myresult .= '&lt;ul&gt;';
$myresult .= '&lt;li&gt;&lt;a href=\'#tab-1\'&gt;Ratings&lt;/a&gt;&lt;/li&gt;';
$myresult .= '&lt;li&gt;&lt;a href=\'#tab-2\'&gt;Click here to rate&lt;/a&gt;&lt;/li&gt;';
$myresult .= '&lt;/ul&gt;';

$myresult .= '&lt;div id=\'tab-1\'&gt;';

/* actual rating table - start - jsut display ratings */

$myresult .= '&lt;table id=\'rounded-corner\'&gt;';

/* thead - start */
$myresult .= '&lt;thead&gt;';

$myresult .= '&lt;tr&gt;';

$myresult .= '&lt;th width=\'30%\' class=\'rounded-company\' scope=\'col\'&gt;&lt;span style=\'font: normal 18px  Arial, Helvetica, sans-serif; color:#FFF;\'&gt;Ratings&lt;/span&gt;&lt;/th&gt;';

$myresult .= '&lt;th width=\'70%\' colspan=\'2\'class=\'rounded-q4\' scope=\'col\'&gt;&lt;a href=\'#rounded-corner\' id=\'clickit\' style=\'color:white;text-decoration:underline;\' $disabled &gt;&lt;/a&gt;&lt;/th&gt;
';

/*$myresult .= '&lt;th width=\'70%\' colspan=\'2\'class=\'rounded-q4\' scope=\'col\'&gt;&lt;a href=\'#rounded-corner\' id=\'clickit\' style=\'color:white;text-decoration:underline;\' $disabled &gt;Click here to rate&lt;/a&gt;&lt;/th&gt;
';*/
$myresult .= '&lt;/tr&gt;';
$myresult .= '&lt;/thead&gt;';

/* thead - end */

/* tbody - start */
$myresult .= '&lt;tbody&gt;';

/*start printing the table wth feature and ratings */
for ($i = 1 ; $i &lt; $numProperties; $i++){

if($master_rating_properties['rating'.$i.'_name']){

$myresult .= '&lt;tr&gt;';

$myresult .= '&lt;td width=\'22%\'&gt;';

$indfeature = 0;
$indfeature = $row_product['property'.$i.'_avg'];
$myresult .= $master_rating_properties['rating'.$i.'_name'].' ( '.$indfeature .')';

$myresult .= '&lt;/td&gt;';

$myresult .= '&lt;td colspan=\'0\' width=\'38%\' &gt;';

$tocheck = $indfeature;

for($k = 0.5; $k &lt;= 10.0; $k+=0.5){

$tocheck = roundOff($tocheck);
if(($tocheck) == $k)
{ $chk = "checked"; }

else

{ $chk = ""; }

$myresult .= '&lt;input class=\'star {split:2}\' type=\'radio\' name=\'drating'.$i.'\' id=\'drating'.$i.''.$k.'\' value=\''. $k .'\'  '.$chk.'  title=\''. $k.' out of 10 \' disabled \'/&gt;';

}

/* for k loop end */
$myresult .= '&lt;/tr&gt;';
}
/* end if loop */
}
/* end i for loop */

$myresult .= '&lt;/tbody&gt;';
/* end tbody */    

/* footer round corner start */
$myresult .= '&lt;tfoot&gt;';
$myresult .= '&lt;tr&gt;';
$myresult .= '&lt;td class=\'rounded-foot-left\'&gt;&amp;nbsp;&lt;/td&gt;';

$myresult .= '&lt;td class=\'rounded-foot-right\' colspan=\'4\' &gt;';

$myresult .= '&lt;/td&gt;';
$myresult .= '&lt;/tr&gt;';
$myresult .= '&lt;/tfoot&gt;';

$myresult .= '&lt;/table&gt;';
/*round corner table end */


$myresult .= '&lt;/div&gt;';
/*end 1st tab */

/*start 2nd tab */
$myresult .= '&lt;div id=\'tab-2\'&gt;';

$myresult .= '&lt;form name =\'form1\' id=\'form1\' method = \'POST\' action=\''.$_SERVER['php_self'] .'\'&gt;';







/* actual rating table - start - actual rate/update */

$myresult .= '&lt;table id=\'rounded-corner\'&gt;';

/* thead - start */
$myresult .= '&lt;thead&gt;';

$myresult .= '&lt;tr&gt;';

$myresult .= '&lt;th width=\'30%\' class=\'rounded-company\' scope=\'col\'&gt;&lt;span style=\'font: normal 18px  Arial, Helvetica, sans-serif; color:#FFF;\'&gt;Ratings&lt;/span&gt;&lt;/th&gt;';

$myresult .= '&lt;th width=\'70%\' colspan=\'2\'class=\'rounded-q4\' scope=\'col\'&gt;&lt;/th&gt;';

$myresult .= '&lt;/tr&gt;';
$myresult .= '&lt;/thead&gt;';

/* thead - end */

/* tbody - start */
$myresult .= '&lt;tbody&gt;';
unset($i);
/*start printing the table wth feature and ratings */
for ($i = 1 ; $i &lt; $numProperties; $i++){

if($master_rating_properties['rating'.$i.'_name']){

$myresult .= '&lt;tr&gt;';

/*fetch ratings and comments - 1st make it to null */
$indfeature = 0;
$comment    = '';

$indfeature = $user_ratings['rating'.$i];
if($indfeature == NULL){ $indfeature = 0; }
$comment    = $user_ratings['rating'.$i.'_comment']; 


$myresult .= '&lt;td width=\'22%\'&gt;';

$myresult .= $master_rating_properties['rating'.$i.'_name'].' ( '.$indfeature.' )';

$myresult .= '&lt;/td&gt;';

$myresult .= '&lt;td colspan=\'0\' width=\'38%\' &gt;';

if(($userId != '0') &amp;&amp; (is_array($user_ratings)))
{
$tocheck = $indfeature;
}
else
{
$tocheck = '0';
}

for($k = 0.5; $k &lt;= 10.0; $k+=0.5){

$tocheck = roundOff($tocheck);
if(($tocheck) == $k)
{ $chk = "checked"; }

else

{ $chk = ""; }

$myresult .= '&lt;input class=\'star {split:2}\' type=\'radio\' name=\'rating'.$i.'\' id=\'rating'.$i.''.$k.'\' value=\''. $k .'\'  '.$chk.'  title=\''. $k.' out of 10 \' '.$disabled.' \' /&gt;';

}

/* for k loop end */
$myresult .= '&lt;/td&gt;';
$myresult .= '&lt;td width=\'40%\'&gt;';
$myresult .= '&lt;input title=\'Reason for this Rating.. \'type=\'text\' size=\'25\' name=\'comment'.$i.'\' id=\'comment'.$i.'\' style=\'display:;\' maxlength=\'255\' value="'.$comment.'"&gt;';
$myresult .= '&lt;/td&gt;';
$myresult .= '&lt;/tr&gt;';
}
/* end if loop */
}
/* end i for loop */

$myresult .= '&lt;/tbody&gt;';
/* end tbody */    

/* footer round corner start */
$myresult .= '&lt;tfoot&gt;';
$myresult .= '&lt;tr&gt;';
$myresult .= '&lt;td class=\'rounded-foot-left\'&gt;&amp;nbsp;&lt;/td&gt;';

$myresult .= '&lt;td class=\'rounded-foot-right\' colspan=\'4\' &gt;';

if(($userId != '0') &amp;&amp; (is_array($user_ratings)))
{
$myresult .= '&lt;input type=\'button\' id=\'update_form\' value=\'Update\'&gt;';
}
else
{
$myresult .= '&lt;input type=\'button\' id=\'save_form\' value=\'Save\'&gt;';
}

$myresult .= '&lt;/td&gt;';
$myresult .= '&lt;/tr&gt;';
$myresult .= '&lt;/tfoot&gt;';

$myresult .= '&lt;/table&gt;';
/*round corner table end */









$myresult .= '&lt;/form&gt;';
/*end the form to take ratings */ 
$myresult .= '&lt;/div&gt;';
/*end 2nd tab */


$myresult .= '&lt;/div&gt;';

/*end tabs div */

/* actual rating table - end */
/* 1st form ends here id- ratings_form */
}
/* end of if loop result_product loop */

/* start table 3 - overall comment*/
$myresult .= '&lt;table border=\'0\' cellspacing=\'0\' cellpadding=\'0\' style=\'width:580px; table-layout:fixed;\' id=\'rounded-corner\'&gt;';
$myresult .= '&lt;tbody&gt;';
/* thead - start */
$myresult .= '&lt;thead&gt;';

$myresult .= '&lt;tr&gt;';

$myresult .= '&lt;th width=\'100%\' colspan=\'2\' class=\'rounded-company\' scope=\'col\'&gt;&lt;span style=\'font: normal 18px  Arial, Helvetica, sans-serif; color:#FFF;\'&gt;Overall Comments&lt;/span&gt;&lt;/th&gt;';

$myresult .= '&lt;th colspan=\'3\' class=\'rounded-q4\' scope=\'col\'&gt;&lt;/th&gt;';


$myresult .= '&lt;/tr&gt;';
$myresult .= '&lt;/thead&gt;';

/* thead - end */
$myresult .= '&lt;tr&gt;';
$myresult .= '&lt;td colspan=\'4\'&gt;';
$myresult .= '&lt;textarea title=\'OverAll Comment\' name=\'overall_comment\' cols=\'65\'&gt;&lt;/textarea&gt;';
$myresult .= '&lt;/td&gt;';
$myresult .= '&lt;/tr&gt;';
$myresult .= '&lt;tbody&gt;';
$myresult .= '&lt;/table&gt;';
/* end table 3 - overall comment*/



/* start table 4 - summary*/

$myresult .= '&lt;table border=\'0\' cellspacing=\'0\' cellpadding=\'0\' style=\'width:580px; table-layout:fixed;\' id=\'rounded-corner\'&gt;';
$myresult .= '&lt;tbody&gt;';
/* thead - start */
$myresult .= '&lt;thead&gt;';

$myresult .= '&lt;tr&gt;';

$myresult .= '&lt;th colspan=\'2\' class=\'rounded-company\' scope=\'col\'&gt;&lt;span style=\'font: normal 18px  Arial, Helvetica, sans-serif; color:#FFF;\'&gt;Your Opinion&lt;/span&gt;&lt;/th&gt;';
$myresult .= '&lt;th  colspan=\'2\'class=\'rounded-q4\' scope=\'col\'&gt;&lt;/th&gt;';
$myresult .= '&lt;/tr&gt;';
$myresult .= '&lt;/thead&gt;';

/* thead - end */


$myresult .= '&lt;tr&gt;';
$myresult .= '&lt;td colspan=\'2\'&gt;';
$myresult .= 'Do you Agree with the Ratings';
$myresult .= '&lt;/td&gt;';

$myresult .= '&lt;td colspan=\'2\'&gt;';
$myresult .= 'Was the Information Helpful';
$myresult .= '&lt;/td&gt;';
$myresult .= '&lt;/tr&gt;';

$myresult .= '&lt;tr&gt;';

$myresult .= '&lt;form name=\'form2\' id=\'form2\' method=\'post\'&gt;';
$myresult .= '&lt;td&gt;';
$myresult .= '&lt;input type=\'button\' class=\'agree\' value=\'agree\'&gt;';
$myresult .= '&lt;/td&gt;';

$myresult .= '&lt;td&gt;';
$myresult .= '&lt;input type=\'button\' class=\'disagree\' value=\'disagree\'&gt;';
$myresult .= '&lt;/td&gt;';
$myresult .= '&lt;input type=\'hidden\' name=\'agree_disagree\' id=\'agree_disagree\'&gt;';
$myresult .= '&lt;/form&gt;';

$myresult .= '&lt;form name=\'form3\' id=\'form3\' method=\'post\'&gt;';
$myresult .= '&lt;td&gt;';
$myresult .= '&lt;input type=\'button\' class=\'helpful\' value=\'Helpful\'&gt;';
$myresult .= '&lt;/td&gt;';

$myresult .= '&lt;td&gt;';
$myresult .= '&lt;input type=\'button\' class=\'nothelpful\' value=\'Not Helpful\'&gt;';
$myresult .= '&lt;/td&gt;';

$myresult .= '&lt;input type=\'hidden\' name=\'help_nohelp\' id=\'help_nohelp\'&gt;';
$myresult .= '&lt;/form&gt;';
$myresult .= '&lt;/tr&gt;';
$myresult .= '&lt;/tbody&gt;';
$myresult .= '&lt;/table&gt;';
/*end table 4 summary table */


$myresult .= '&lt;/div&gt;';
/* Actual Form or Page - end */
echo $myresult;
//echo 'Product: '.$product;
//echo '&lt;br/&gt;Alias: '.$alias;
?&gt;
</code></pre>

<p>hey this code is working fine for me . as required. the star class code is taken from 
<a href="http://www.fyneworks.com/jquery/star-rating/" rel="nofollow">http://www.fyneworks.com/jquery/star-rating/</a>   ... it works well.. but when i insert code to add tabs for content ,the starts is not  visible at all. but when i check source code. the stars are actually there . dono whats the prob. any suggestions on this </p>

<p>this is the tabs code</p>

<pre><code>$('#tabs div').hide(); 
('#tabs div:first').show(); 
$('#tabs ul li:first').addClass('active'); 
$('#tabs ul li a').click(function()
{ 
$('#tabs ul li').removeClass('active'); 
$(this).parent().addClass('active'); 
var currentTab = $(this).attr('href'); 
$('#tabs div').hide(); 
$(currentTab).show(); 
return false;
});
</code></pre>
