help needed splitting table!

Want to talk "shop?" Offer up advice, maybe seeking help, discuss it all here.

help needed splitting table!

Postby caeos on Fri Apr 03, 2009 4:40 am

i know it sounds stupid, but this is causing me grief!

I have a table that needs splitting to form 2 columns as its a very large table

here isa sample of the code.. let me know if you can help and i will pm the full file

Code: Select all
<table cellspacing="0" class="ewGrid"><tr><td class="ewGridContent">
<div class="ewGridMiddlePanel">
<table cellspacing="0" class="ewTable">
   <tr<?php echo $teachers->nvq_1_childcare->RowAttributes ?>>
      <td class="ewTableHeader">nvq 1 childcare</td>
      <td<?php echo $teachers->nvq_1_childcare->CellAttributes() ?>><span class="ewSearchOpr"><input type="hidden" name="z_nvq_1_childcare" id="z_nvq_1_childcare" value="="></span></td>
      <td<?php echo $teachers->nvq_1_childcare->CellAttributes() ?>>
         <table cellspacing="0" class="ewItemTable"><tr>
            <td><span class="phpmaker">
<div id="tp_x_nvq_1_childcare" class="<?php echo EW_ITEM_TEMPLATE_CLASSNAME ?>"><input type="radio" name="x_nvq_1_childcare" id="x_nvq_1_childcare" value="{value}"<?php echo $teachers->nvq_1_childcare->EditAttributes() ?>></div>
<div id="dsl_x_nvq_1_childcare" repeatcolumn="5">
<?php
$arwrk = $teachers->nvq_1_childcare->EditValue;
if (is_array($arwrk)) {
   $rowswrk = count($arwrk);
   $emptywrk = TRUE;
   for ($rowcntwrk = 0; $rowcntwrk < $rowswrk; $rowcntwrk++) {
      $selwrk = (strval($teachers->nvq_1_childcare->AdvancedSearch->SearchValue) == strval($arwrk[$rowcntwrk][0])) ? " checked=\"checked\"" : "";
      if ($selwrk <> "") $emptywrk = FALSE;

      // Note: No spacing within the LABEL tag
?>
<?php echo ew_RepeatColumnTable($rowswrk, $rowcntwrk, 5, 1) ?>
<label><input type="radio" name="x_nvq_1_childcare" id="x_nvq_1_childcare" value="<?php echo ew_HtmlEncode($arwrk[$rowcntwrk][0]) ?>"<?php echo $selwrk ?><?php echo $teachers->nvq_1_childcare->EditAttributes() ?>><?php echo $arwrk[$rowcntwrk][1] ?></label>
<?php echo ew_RepeatColumnTable($rowswrk, $rowcntwrk, 5, 2) ?>
<?php
   }
}
?>
</div>
</span></td>
         </tr></table>      </td>
   </tr>
   <tr<?php echo $teachers->nvq_2_childcare->RowAttributes ?>>
      <td class="ewTableHeader">nvq 2 childcare</td>
      <td<?php echo $teachers->nvq_2_childcare->CellAttributes() ?>><span class="ewSearchOpr"><input type="hidden" name="z_nvq_2_childcare" id="z_nvq_2_childcare" value="="></span></td>
      <td<?php echo $teachers->nvq_2_childcare->CellAttributes() ?>>
         <table cellspacing="0" class="ewItemTable"><tr>
            <td><span class="phpmaker">
<div id="tp_x_nvq_2_childcare" class="<?php echo EW_ITEM_TEMPLATE_CLASSNAME ?>"><input type="radio" name="x_nvq_2_childcare" id="x_nvq_2_childcare" value="{value}"<?php echo $teachers->nvq_2_childcare->EditAttributes() ?>></div>
<div id="dsl_x_nvq_2_childcare" repeatcolumn="5">
<?php
$arwrk = $teachers->nvq_2_childcare->EditValue;
if (is_array($arwrk)) {
   $rowswrk = count($arwrk);
   $emptywrk = TRUE;
   for ($rowcntwrk = 0; $rowcntwrk < $rowswrk; $rowcntwrk++) {
      $selwrk = (strval($teachers->nvq_2_childcare->AdvancedSearch->SearchValue) == strval($arwrk[$rowcntwrk][0])) ? " checked=\"checked\"" : "";
      if ($selwrk <> "") $emptywrk = FALSE;

      // Note: No spacing within the LABEL tag
?>
<?php echo ew_RepeatColumnTable($rowswrk, $rowcntwrk, 5, 1) ?>
<label><input type="radio" name="x_nvq_2_childcare" id="x_nvq_2_childcare" value="<?php echo ew_HtmlEncode($arwrk[$rowcntwrk][0]) ?>"<?php echo $selwrk ?><?php echo $teachers->nvq_2_childcare->EditAttributes() ?>><?php echo $arwrk[$rowcntwrk][1] ?></label>
<?php echo ew_RepeatColumnTable($rowswrk, $rowcntwrk, 5, 2) ?>
<?php
   }
}
?>
</div>
</span></td>
         </tr></table>      </td>
   </tr>
   <tr<?php echo $teachers->nvq_3_childcare->RowAttributes ?>>
      <td class="ewTableHeader">nvq 3 childcare</td>
      <td<?php echo $teachers->nvq_3_childcare->CellAttributes() ?>><span class="ewSearchOpr"><input type="hidden" name="z_nvq_3_childcare" id="z_nvq_3_childcare" value="="></span></td>
      <td<?php echo $teachers->nvq_3_childcare->CellAttributes() ?>>
         <table cellspacing="0" class="ewItemTable"><tr>
            <td><span class="phpmaker">
<div id="tp_x_nvq_3_childcare" class="<?php echo EW_ITEM_TEMPLATE_CLASSNAME ?>"><input type="radio" name="x_nvq_3_childcare" id="x_nvq_3_childcare" value="{value}"<?php echo $teachers->nvq_3_childcare->EditAttributes() ?>></div>
<div id="dsl_x_nvq_3_childcare" repeatcolumn="5">

<?php
$arwrk = $teachers->nvq_3_childcare->EditValue;
if (is_array($arwrk)) {
   $rowswrk = count($arwrk);
   $emptywrk = TRUE;
   for ($rowcntwrk = 0; $rowcntwrk < $rowswrk; $rowcntwrk++) {
      $selwrk = (strval($teachers->nvq_3_childcare->AdvancedSearch->SearchValue) == strval($arwrk[$rowcntwrk][0])) ? " checked=\"checked\"" : "";
      if ($selwrk <> "") $emptywrk = FALSE;

      // Note: No spacing within the LABEL tag
?>
<?php echo ew_RepeatColumnTable($rowswrk, $rowcntwrk, 5, 1) ?>
<label><input type="radio" name="x_nvq_3_childcare" id="x_nvq_3_childcare" value="<?php echo ew_HtmlEncode($arwrk[$rowcntwrk][0]) ?>"<?php echo $selwrk ?><?php echo $teachers->nvq_3_childcare->EditAttributes() ?>><?php echo $arwrk[$rowcntwrk][1] ?></label>
<?php echo ew_RepeatColumnTable($rowswrk, $rowcntwrk, 5, 2) ?>
<?php
   }
}
?>
</div>
</span></td>
         </tr></table>      </td>
   </tr>
   <tr<?php echo $teachers->nvq_4_childcare->RowAttributes ?>>
      <td class="ewTableHeader">nvq 4 childcare</td>
      <td<?php echo $teachers->nvq_4_childcare->CellAttributes() ?>><span class="ewSearchOpr"><input type="hidden" name="z_nvq_4_childcare" id="z_nvq_4_childcare" value="="></span></td>
      <td<?php echo $teachers->nvq_4_childcare->CellAttributes() ?>>
         <table cellspacing="0" class="ewItemTable"><tr>
            <td><span class="phpmaker">
<div id="tp_x_nvq_4_childcare" class="<?php echo EW_ITEM_TEMPLATE_CLASSNAME ?>"><input type="radio" name="x_nvq_4_childcare" id="x_nvq_4_childcare" value="{value}"<?php echo $teachers->nvq_4_childcare->EditAttributes() ?>></div>
<div id="dsl_x_nvq_4_childcare" repeatcolumn="5">
<?php
$arwrk = $teachers->nvq_4_childcare->EditValue;
if (is_array($arwrk)) {
   $rowswrk = count($arwrk);
   $emptywrk = TRUE;
   for ($rowcntwrk = 0; $rowcntwrk < $rowswrk; $rowcntwrk++) {
      $selwrk = (strval($teachers->nvq_4_childcare->AdvancedSearch->SearchValue) == strval($arwrk[$rowcntwrk][0])) ? " checked=\"checked\"" : "";
      if ($selwrk <> "") $emptywrk = FALSE;

      // Note: No spacing within the LABEL tag
?>
<?php echo ew_RepeatColumnTable($rowswrk, $rowcntwrk, 5, 1) ?>
<label><input type="radio" name="x_nvq_4_childcare" id="x_nvq_4_childcare" value="<?php echo ew_HtmlEncode($arwrk[$rowcntwrk][0]) ?>"<?php echo $selwrk ?><?php echo $teachers->nvq_4_childcare->EditAttributes() ?>><?php echo $arwrk[$rowcntwrk][1] ?></label>
<?php echo ew_RepeatColumnTable($rowswrk, $rowcntwrk, 5, 2) ?>
<?php
   }
}
?>
</div>
</span></td>
         </tr></table>      </td>
   </tr>
   <tr<?php echo $teachers->nvq_1_playwork->RowAttributes ?>>
      <td class="ewTableHeader">nvq 1 playwork</td>
      <td<?php echo $teachers->nvq_1_playwork->CellAttributes() ?>><span class="ewSearchOpr"><input type="hidden" name="z_nvq_1_playwork" id="z_nvq_1_playwork" value="="></span></td>
      <td<?php echo $teachers->nvq_1_playwork->CellAttributes() ?>>
         <table cellspacing="0" class="ewItemTable"><tr>
            <td><span class="phpmaker">
<div id="tp_x_nvq_1_playwork" class="<?php echo EW_ITEM_TEMPLATE_CLASSNAME ?>"><input type="radio" name="x_nvq_1_playwork" id="x_nvq_1_playwork" value="{value}"<?php echo $teachers->nvq_1_playwork->EditAttributes() ?>></div>
<div id="dsl_x_nvq_1_playwork" repeatcolumn="5">
<?php
$arwrk = $teachers->nvq_1_playwork->EditValue;
if (is_array($arwrk)) {
   $rowswrk = count($arwrk);
   $emptywrk = TRUE;
   for ($rowcntwrk = 0; $rowcntwrk < $rowswrk; $rowcntwrk++) {
      $selwrk = (strval($teachers->nvq_1_playwork->AdvancedSearch->SearchValue) == strval($arwrk[$rowcntwrk][0])) ? " checked=\"checked\"" : "";
      if ($selwrk <> "") $emptywrk = FALSE;

      // Note: No spacing within the LABEL tag
?>
<?php echo ew_RepeatColumnTable($rowswrk, $rowcntwrk, 5, 1) ?>
<label><input type="radio" name="x_nvq_1_playwork" id="x_nvq_1_playwork" value="<?php echo ew_HtmlEncode($arwrk[$rowcntwrk][0]) ?>"<?php echo $selwrk ?><?php echo $teachers->nvq_1_playwork->EditAttributes() ?>><?php echo $arwrk[$rowcntwrk][1] ?></label>
<?php echo ew_RepeatColumnTable($rowswrk, $rowcntwrk, 5, 2) ?>
<?php
   }
}
?>
</div>
</span></td>
         </tr></table>      </td>
   </tr>
User avatar
caeos
Global Moderator
Global Moderator
 
Posts: 582
Joined: Fri Jul 07, 2006 2:54 pm
Location: South Coast. UK.

Re: help needed splitting table!

Postby earth on Wed May 20, 2009 9:36 pm

Yeah I think I could do that, if you pm me i will look at it from school tomorrow.
Occasionally around... smf>phpbb
earth
Sr. Member
Sr. Member
 
Posts: 306
Joined: Fri Dec 23, 2005 12:40 pm
Location: Oregon

Re: help needed splitting table!

Postby caeos on Fri May 22, 2009 4:27 pm

pm was sent with search table....good luck
User avatar
caeos
Global Moderator
Global Moderator
 
Posts: 582
Joined: Fri Jul 07, 2006 2:54 pm
Location: South Coast. UK.


Return to Let's Talk Tech

Who is online

Users browsing this forum: No registered users and 1 guest

cron