Platon Technologies
not logged in Login Registration
EnglishSlovak
open source software development celebrating 10 years of open source development! Friday, March 29, 2024

Diff for phpMyEdit/phpMyEdit.class.php between version 1.86 and 1.87

version 1.86, 2003/07/24 10:49:00 version 1.87, 2003/07/24 12:45:28
Line 19 
Line 19 
  * http://www.platon.sk/projects/phpMyEdit/   * http://www.platon.sk/projects/phpMyEdit/
  */   */
   
 /* $Platon: phpMyEdit/phpMyEdit.class.php,v 1.85 2003/07/09 19:54:30 nepto Exp $ */  /* $Platon: phpMyEdit/phpMyEdit.class.php,v 1.86 2003/07/24 10:49:00 nepto Exp $ */
   
 /*  This is a generic table editing program. The table and fields to be  /*  This is a generic table editing program. The table and fields to be
         edited are defined in the calling program.          edited are defined in the calling program.
Line 708  class phpMyEdit
Line 708  class phpMyEdit
                                 // TAB javascripts                                  // TAB javascripts
                                 echo '<script type="text/javascript"><!--',"\n\n";                                  echo '<script type="text/javascript"><!--',"\n\n";
                                 echo 'var phpMyEdit_field_to_tab = [',$field_to_tab,'-1];',"\n";                                  echo 'var phpMyEdit_field_to_tab = [',$field_to_tab,'-1];',"\n";
                                   $css_class_name1 = $this->getCSSclass('tab', $position);
                                   $css_class_name2 = $this->getCSSclass('tab-selected', $position);
                                 echo 'var phpMyEdit_current_tab  = "phpMyEdit_tab0";                                  echo 'var phpMyEdit_current_tab  = "phpMyEdit_tab0";
   
 function phpMyEdit_show_tab(tab_name)  function phpMyEdit_show_tab(tab_name)
 {  {';
                                   if ($this->nav_up()) {
                                           echo '
           document.getElementById(phpMyEdit_current_tab+"_up_label").className = "',$css_class_name1,'";
           document.getElementById(phpMyEdit_current_tab+"_up_link").className = "',$css_class_name1,'";
           document.getElementById(tab_name+"_up_label").className = "',$css_class_name2,'";
           document.getElementById(tab_name+"_up_link").className = "',$css_class_name2,'";';
                                   }
                                   if ($this->nav_down()) {
                                           echo '
           document.getElementById(phpMyEdit_current_tab+"_down_label").className = "',$css_class_name1,'";
           document.getElementById(phpMyEdit_current_tab+"_down_link").className = "',$css_class_name1,'";
           document.getElementById(tab_name+"_down_label").className = "',$css_class_name2,'";
           document.getElementById(tab_name+"_down_link").className = "',$css_class_name2,'";';
                                   }
                                   echo '
         document.getElementById(phpMyEdit_current_tab).style.display = "none";          document.getElementById(phpMyEdit_current_tab).style.display = "none";
         document.getElementById(phpMyEdit_current_tab+"_label").style.background = "none";          document.getElementById(tab_name).style.display = "block";
         document.getElementById(tab_name).style.display = "block";  
         document.getElementById(tab_name+"_label").style.background = "#FFFFFF";  
         phpMyEdit_current_tab = tab_name;          phpMyEdit_current_tab = tab_name;
 }',"\n\n";  }',"\n\n";
                                 echo '// --></script>', "\n";                                  echo '// --></script>', "\n";
Line 818  function phpMyEdit_form_control(theForm)
Line 833  function phpMyEdit_form_control(theForm)
                 return true;                  return true;
         } /* }}} */          } /* }}} */
   
         function display_tab_labels() /* {{{ */          function display_tab_labels($position) /* {{{ */
         {          {
                 if (! is_array($this->tabs)) {                  if (! is_array($this->tabs)) {
                         return false;                          return false;
                 }                  }
                 echo "<table>\n";                  echo '<table class="',$this->getCSSclass('tab', $position),'">',"\n";
                 echo '<tr>',"\n";                  echo '<tr class="',$this->getCSSclass('tab', $position),'">',"\n";
                 for ($i = 0; $i < count($this->tabs); $i++) {                  for ($i = 0; $i < count($this->tabs); $i++) {
                         echo '<td id="phpMyEdit_tab',$i,'_label">';                          $css_class_name = $this->getCSSclass($i ? 'tab' : 'tab-selected', $position);
                         echo '<a href="javascript:phpMyEdit_show_tab(\'phpMyEdit_tab',$i,'\')">';                          echo '<td class="',$css_class_name,'" id="phpMyEdit_tab',$i,'_',$position,'_label">';
                           echo '<a class="',$css_class_name,'" id="phpMyEdit_tab',$i,'_',$position,'_link';
                           echo '" href="javascript:phpMyEdit_show_tab(\'phpMyEdit_tab',$i,'\')">';
                         echo $this->tabs[$i],'</a></td>',"\n";                          echo $this->tabs[$i],'</a></td>',"\n";
                 }                  }
                 echo '<td width="100%">&nbsp;</td>';                  echo '<td class="',$this->getCSSclass('tab-end', $position),'">&nbsp;</td>',"\n";
                 echo '</tr>',"\n";                  echo '</tr>',"\n";
                 echo '</table>',"\n";                  echo '</table>',"\n";
         } /* }}} */          } /* }}} */
Line 2123  function phpMyEdit_form_control(theForm)
Line 2140  function phpMyEdit_form_control(theForm)
                         $this->display_record_buttons();                          $this->display_record_buttons();
                         echo '<hr class="',$this->getCSSclass('hr', 'up'),'">',"\n";                          echo '<hr class="',$this->getCSSclass('hr', 'up'),'">',"\n";
                         if ($this->tabs_enabled()) {                          if ($this->tabs_enabled()) {
                                 $this->display_tab_labels();                                  $this->display_tab_labels('up');
                         }                          }
                 }                  }
                 if ($this->tabs_enabled()) {                  if ($this->tabs_enabled()) {
Line 2139  function phpMyEdit_form_control(theForm)
Line 2156  function phpMyEdit_form_control(theForm)
                 echo '</div>',"\n";                  echo '</div>',"\n";
                 if ($this->nav_down()) {                  if ($this->nav_down()) {
                         if ($this->tabs_enabled()) {                          if ($this->tabs_enabled()) {
                                 $this->display_tab_labels();                                  $this->display_tab_labels('down');
                         }                          }
                         echo '<hr class="',$this->getCSSclass('hr', 'down'),'">',"\n";                          echo '<hr class="',$this->getCSSclass('hr', 'down'),'">',"\n";
                         $this->display_record_buttons();                          $this->display_record_buttons();

Legend:
Removed from v.1.86  
changed lines
  Added in v.1.87

Platon Group <platon@platon.org> http://platon.org/
Copyright © 2002-2006 Platon Group
Site powered by Metafox CMS
Go to Top