Subversion Repositories wimsdev

Rev

Rev 10057 | Rev 10169 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed

  1. <!-- BEGIN of html/headmenu_* -->
  2. !read name.phtml.$lang
  3. !read themes/$wims_theme/lang/name.phtml.$lang
  4. !default wims_name_bgcolor=$wims_ref_bgcolor
  5. !if $wims_hm$wims_home_items$wims_link_close!=$empty
  6.  !goto defend
  7. !endif
  8. !if $job=print or $printing=yes
  9.  !goto defend
  10. !endif
  11. !reset 1_ home_
  12. !if _ isin $wims_session
  13.  !if _exam isin $wims_session
  14.   !set wims_pses=!translate _ to , in $wims_session
  15.   !set wims_pses=!item 1 of $wims_pses
  16.   !set wims_pser=!randint 1,99999
  17.   !set wims_href_opener=window.opener.location='$wims_ref_name?session=$wims_pses.1&+cmd=reply&+job=student&+randomizer=$wims_pser';
  18.  !endif
  19.  !set 1_=!append line back,3,window.close();$wims_href_opener to $1_
  20. !else
  21.   !if $module!=home or ($module=home and $seq!=$empty)
  22.    !set home_=!append line class_home,1,session=$wims_session.1 to $home_
  23.   !else
  24.    !set home_=!append line class_home,8, to $home_
  25.   !endif
  26. !endif
  27.  
  28. !!! deconnexion link
  29. !if _tool notin $wims_session
  30.  !if $class_cas_auth!=$empty
  31.   !if $wims_user=supervisor
  32.      !set wims_link_close=!append line visitor,1,cmd=close&module=adm/class/classes&type=supervisor&class_auth=$class_cas_auth to $wims_link_close
  33.   !else
  34.    !if $wims_class!=$empty
  35.      !set wims_link_close=!append line visitor,1,cmd=close&module=adm/class/classes&type=participant&class_auth=$class_cas_auth to $wims_link_close
  36.    !else
  37.     !set wims_link_close=!append line visitor,1,cmd=close&class_auth=$wims_cas_auth to $wims_link_close
  38.    !endif
  39.   !endif
  40.  !else
  41.   !if $wims_user=supervisor
  42.     !set wims_link_close=!append line visitor,1,cmd=close&module=adm/class/classes&type=supervisor to $wims_link_close
  43.   !else
  44.      !if $wims_user=anonymous
  45.        !set wims_link_close=!append line visitor,1,cmd=close&module=adm/class/classes&type=example to $wims_link_close
  46.      !else
  47.        !if _exam notin $wims_session
  48.          !set wims_link_close=!append line visitor,1,cmd=close&module=adm/class/classes&type=participant to $wims_link_close
  49.        !endif
  50.     !endif
  51.   !endif
  52.  !endif
  53. !endif
  54.  
  55. !if _check isin $wims_session
  56.  !set ckstep=$special_parm
  57.  !distribute item $wims_check into ckmodule,ckuser,cksession,ckexo,cksteps,score
  58.  !set qstr=module=$ckmodule&+cmd=new&+job=examcheck&+checkuser=$ckuser&+checksession=$cksession&+checkexo=$ckexo
  59.  !set 2_=$wims_page_name : &nbsp;
  60.  !ifval $ckstep>1
  61.   !set 2_=$2_<a href="$wims_ref_name?session=$session&+$qstr&+checkstep=1">1</a>&nbsp;
  62.   !if $ckstep=2
  63.    !set 2_=$(2_)2&nbsp;
  64.   !else
  65.    !if $ckstep=3
  66.     !set 2_=$(2_)<a href="$wims_ref_name?session=$session&+$qstr&+checkstep=2">2</a>&nbsp;3&nbsp;
  67.    !else
  68.     !set 2_=$(2_)&nbsp;...&nbsp;<a href="$wims_ref_name?session=$session&+$qstr&+checkstep=$[$ckstep-1]">$[$ckstep-1]</a>&nbsp;$ckstep&nbsp;
  69.    !endif
  70.   !endif
  71.  !else
  72.   !set 2_=$2_ 1 &nbsp;
  73.  !endif
  74.  !if $ckstep<$cksteps
  75.   !ifval $ckstep<$cksteps-2
  76.    !set 2_=$2_<a href="$wims_ref_name?session=$session&+$qstr&+checkstep=$[$ckstep+1]">$[$ckstep+1]</a>&nbsp;...&nbsp;<a href="$wims_ref_name?session=$session&+$qstr&+checkstep=$cksteps">$cksteps</a>
  77.   !else
  78.    !ifval $ckstep=$cksteps-2
  79.     !set 2_=$2_<a href="$wims_ref_name?session=$session&+$qstr&+checkstep=$[$ckstep+1]">$[$ckstep+1]</a>&nbsp;<a href="$wims_ref_name?session=$session&+$qstr&+checkstep=$cksteps">$cksteps</a>
  80.    !else
  81.     !ifval $ckstep=$cksteps-1
  82.      !set 2_=$2_<a href="$wims_ref_name?session=$session&+$qstr&+checkstep=$[$ckstep+1]">$[$ckstep+1]</a>
  83.     !endif
  84.    !endif
  85.   !endif
  86.  !endif
  87.  !set 1_=!append line nav,0,$2_ to $1_
  88.  !set 3_=!translate internal - to , in $ckexo
  89.  !set 3_=!item -1 of $3_
  90.  !set 2_=<small>$ckuser: $3_=$module. $cksteps steps, $score/10.</small>
  91.  !set wims_hm=!append line score,0,$2_ to $1_
  92.  !goto defend
  93. !endif
  94. !if adm/forum notin $module and _ notin $wims_session \
  95.         and $wims_sheet=$empty
  96.  !!!set 1_=!append line forum,1,module=adm/forum/mboard to $1_
  97. !endif
  98. !!if $cmd=intro
  99. !! !set 1_=!append line work,1,module=$module&cmd=new to $1_
  100. !!endif
  101. !!if $wims_sheet!=$empty or _exam isin $wims_session
  102. !!  !set 1_=!append line tools,4,module=home,tool to $1_
  103. !!endif
  104. !!!if _ notin $wims_session and adm/ notin $module \
  105.         and $cmd notwordof help ref
  106.  !!!set 1_=!append line reference,4,module=$module&cmd=ref&special_parm=$cmd,ref to $1_
  107. !!!endif
  108.  
  109. !if $wims_sequence>0 and adm/sheet isin $module
  110.  !if $wims_user=supervisor
  111.   !set wims_ariane=!append line sequence,1,module=adm/class/sequence&seq=$wims_sequence\
  112.    to $wims_ariane
  113.  !else
  114.   !set wims_ariane=!append line sequence,1,module=home&seq=$wims_sequence\
  115.      to $wims_ariane
  116.  !endif
  117. !endif
  118. !if $wims_sheet>0 or P isin $wims_sheet
  119.   !if $wims_sequence!=$empty
  120.     !set wims_ariane=!append line sequence,1,module=home&seq=$wims_sequence \
  121.       to $wims_ariane
  122.   !endif
  123.     !set wims_ariane=!append line sheet,1,module=adm/sheet&sh=$wims_sheet to $wims_ariane
  124. !endif
  125.  
  126. !if $cmd=help or $cmd=hint
  127.  !set 1_=!append line resume,1,cmd=resume to $1_
  128. !endif
  129. !if $module_has_intro=yes and $cmd notwordof intro help and \
  130.         $wims_sheet=$empty and exam notin $wims_session and mfeed notin $wims_session
  131.   !set 1_=!append line intro,1,module=$module&cmd=intro&special_parm=$special_parm&special_parm2=$special_parm2&special_parm3=$special_parm3&special_parm4=$special_parm4 to $1_
  132. !endif
  133. !if $module_has_help=yes and $cmd notwordof intro help and _exam notin $wims_session
  134.  !if $module_help=$empty or $module_help=popup
  135.    !set 1_=!append line help,4,module=$module&cmd=help&special_parm=$wims_help_parm,mhelp to $1_
  136.  !else
  137.    !set 1_=!append line help,1,module=$module&cmd=help&special_parm=$wims_help_parm to $1_
  138.  !endif
  139. !endif
  140.  
  141. !if $wims_theme_version=0
  142.   !if _ notin $wims_session
  143.     !set 1_=!append line whelp,4,module=help/main&$wims_helper,help to $1_
  144.   !endif
  145. !endif
  146.  
  147. !!********* Link: "About"
  148. !if $module_has_about=yes and $cmd notwordof help and $module!=home \
  149.   and _exam notin $wims_session and _mfeed notin $wims_session \
  150.   and (adm notin $module or $wims_user iswordof supervisor developper or $wims_user=$empty)
  151.   !set 1_=!append line about,4,module=$module&cmd=help&special_parm=about,mhelp,,$wims_name_module_infos ($module) to $1_
  152. !endif
  153.  
  154. !set wims_hm=$1_
  155. !set wims_home_items=$home_
  156. :defend
  157. !set wims_hm_cnt=!linecnt $wims_hm
  158. !set wims_home_items_cnt=!linecnt $wims_home_items
  159. !set wims_link_close_cnt=!linecnt $wims_link_close
  160. !set wims_ariane_cnt=!linecnt $wims_ariane
  161. !read themes.phtml header
  162. <div class="wimsbody">
  163. <!-- END of html/headmenu_* -->
  164.