Ignore:
Timestamp:
08/27/10 17:14:12 (21 months ago)
Author:
aarkerio
Message:

Helper updated

File:
1 edited

Legend:

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

    r2460 r2486  
    1414 
    1515# Superuser sudo hack 
    16 if ( !$belongs and $session->read('Auth.User.sudo')): 
     16if ( !$belongs and $this->Session->read('Auth.User.sudo')): 
    1717    $belongs = True; 
    1818endif; 
     
    2020#check if student is logged in and belongs to this vClassroom 
    2121if ( $belongs === True ): 
    22   echo $this->Html->div(Null,  __('Welcome', True) . '!<b> '. $session->read('Auth.User.username') .'</b>'); 
     22  echo $this->Html->div(Null,  __('Welcome', True) . '!<b> '. $this->Session->read('Auth.User.username') .'</b>'); 
    2323  # Prepare ecourse activities 
    2424  #die(debug($data['activities'])); 
     
    6969   
    7070  # hello teacher! 
    71   if ( $blogger['User']['id'] == $session->read('Auth.User.id') && $data['Vclassroom']['message']): 
     71  if ( $blogger['User']['id'] == $this->Session->read('Auth.User.id') && $data['Vclassroom']['message']): 
    7272      echo $this->element('helloteacher', array('vclassroom_id'=>$data['Vclassroom']['id'], 'code'=>$data['Vclassroom']['secret'],  
    7373'username'=> $blogger['User']['username'])); 
     
    217217 endif; # user is logged in and member 
    218218 
    219   if ( $session->check('Auth.User') && $session->read('Auth.User.group_id') < 4 && $belongs === False): # student is login in portal but does not belongs to VC, so, show "Join" button    
     219  if ( $this->Session->check('Auth.User') && $this->Session->read('Auth.User.group_id') < 4 && $belongs === False): # student is login in portal but does not belongs to VC, so, show "Join" button    
    220220     echo $this->Html->para(Null, __('In order to join this classroom you must know the access code, if you do not know it, please put in contact with classroom teacher', True)); 
    221221     echo $this->Form->create(); 
    222222     echo $this->Form->hidden('UsersVclassroom.vclassroom_id', array('value'=>$data['Vclassroom']['id'])); 
    223223     echo $this->Form->input('UsersVclassroom.code', array('size' => 9, 'maxlength'=>9, 'title'=>__('Access code', True), 'between'=>': ')); 
    224      echo $this->Js->submit(__('Join to this class', True).'  '.$session->read('Auth.User.username'), 
     224     echo $this->Js->submit(__('Join to this class', True).'  '.$this->Session->read('Auth.User.username'), 
    225225                                    array('url'         => '/vclassrooms/jointoclass/', 
    226226                                          'update'      => '#updater', 
     
    235235echo $gags->imgLoad('loading'); 
    236236 
    237 if ( !$session->check('Auth.User') ):   # the user is anonymus 
     237if ( !$this->Session->check('Auth.User') ):   # the user is anonymus 
    238238     e($this->Html->link(__('Login to join this group', True), '/users/login')); 
    239239endif; 
Note: See TracChangeset for help on using the changeset viewer.