Show
Ignore:
Timestamp:
07/01/08 19:06:58 (5 months ago)
Author:
aarkerio
Message:

Little fixes

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/app/views/vclassrooms/admin_edit.ctp

    r352 r617  
    22 //exit(var_dump($this->data)); 
    33 echo $javascript->link('fckeditor/fckeditor'); 
    4  echo $html->addCrumb('Control Tools', '/admin/entries/start');   
    5  echo $html->addCrumb('Classrooms', '/admin/vclassrooms/listing');  
     4 echo $html->addCrumb('Control Panel', '/admin/entries/start');   
     5 echo $html->addCrumb('vClassrooms', '/admin/vclassrooms/listing');  
    66 echo $html->getCrumbs(' / ');  
    77 
     
    1414<?php 
    1515    echo $form->input('Vclassroom.name', array('size' => 40, 'maxlength' => 60));  
    16       
    1716 
    1817    echo $form->label('Vclassroom.status', 'Status:'); 
    19     echo $form->checkbox('Vclassroom.status', array('value'=>1));  
     18    echo $form->checkbox('Vclassroom.status');  
    2019 
    21     $attr    = array("value"=>1, "onclick" => "showhide('invi_code')"); 
    22           
    23     if ($this->data['Vclassroom']['access'] == 1) 
    24     { 
    25            $display = 'block';   
    26                $attr['checked'] = 'checked'; 
    27     } 
    28     else 
    29     { 
    30            $display = 'none';      
    31            
    32     } 
    33  
    34     echo $form->label('Vclassroom.access', 'Members only by invitation:'); 
    35     echo $form->checkbox('Vclassroom.access', $attr);  
    36   ?> 
    37   <br /><br /> 
    38    
    39   <div id="invi_code" style="display:<?php echo $display; ?>;"> 
    40      <?php  
    41       echo $form->label('Vclassroom.secret', 'CODE:'); 
    42       echo $form->input('Vclassroom.secret', array("size" => 5, "maxlength" => 6));  
    43     ?> 
    44   </div> 
    45   <div style="clear:both"></div> 
    46   <br /></fieldset> 
    47   <?php echo $form->end('Save'); ?> 
    48  
     20     echo $form->input('Vclassroom.secret', array('size' => 6, 'maxlength' => 6)) 
     21?> 
     22 <div style="clear:both"></div> 
     23 <?php echo $form->end('Save'); ?> 
     24</fieldset> 
     25</div> 
    4926<script type="text/javascript"> 
    5027/* <![CDATA[ */ 
     
    7653   } 
    7754  
    78    if (access.checked == true) 
     55   if (secret.value.length < 5) 
    7956   { 
    80       if (secret.value.length < 5) 
    81       { 
    82         alert('You must type a secret code larger than 5 characters'); 
    83         secret.focus(); 
    84         return false; 
    85       } 
     57      alert('You must type a secret code larger than 5 characters'); 
     58      secret.focus(); 
     59      return false; 
    8660   } 
     61  
    8762   return true; 
    8863 }