Location: PHPKode > projects > Meeting Request Scheduling and Booking System > mrsbs/php/schedule/location.php
<?PHP

   // Select (potential) meeting location
   //
   // Version: $Revision: 1.1 $
   // Date: $Date: 2006/08/06 19:27:36 $
   //
   // Copyright (c) 2006 Benjamin Oshrin
   // License restrictions apply, see LICENSE for details.

$auth_required = 1;
include "../lib/mrsbs.inc";
$pgtitle = $tx['lc.loc.edit'];
$pgtype = "schedule";

if(!authorize("schedule", "location", $rvar_mtgid))
  mexit($tx['op.err.perm'], 1);
$mtg = get_meeting_info($rvar_mtgid);
if(!$mtg)
  mexit($tx['op.err.nomtg'], 1);

if(isset($rvar_next))
  $nexturi = $rvar_next;
else
  $nexturi = "review.php?mtgid=" . $rvar_mtgid;
?>
<HTML>
<HEAD>
<TITLE><?PHP print $pgtitle;?></TITLE>
</HEAD>

<BODY>
<TABLE CLASS="main">
 <?PHP include "../lib/titlebar.php";?>
 <TR>
  <TD CLASS="main">
   <TABLE CLASS="form">
    <TR>
     <TD CLASS="formheader">
      <?PHP print $tx['sd.mtgid'] . " " . hstr($rvar_mtgid);?>
     </TD>
    </TR>
    <FORM NAME="location" ACTION="schedule-op-handler.php" METHOD="post">
    <INPUT TYPE="hidden" NAME="op" VALUE="location">
    <INPUT TYPE="hidden" NAME="mtgid" VALUE="<?PHP print hstr($rvar_mtgid);?>">
    <INPUT TYPE="hidden" NAME="return" VALUE="<?PHP print hstr($nexturi);?>">
    <TR>
     <TD CLASS="formheader2">
      <?PHP print $tx['lc.loc.edit'];?><BR>
     </TD>
    </TR>
    <TR>
     <TD CLASS="formfield2">
      <TABLE CLASS="form">
      <TR>
       <?PHP
         $locval = "l";

	 if($mtg['location'] == -1)
	   $locval = "n";
	 elseif($mtg['location'] == -2)
	   $locval = "t";
       ?>
       <TD CLASS="formfield">
        <INPUT TYPE="radio" NAME="loc" VALUE="n"
	 <?PHP if($locval=="n") print " CHECKED"; ?>>
       </TD>
       <TD CLASS="formfield">
        <?PHP print $tx['sd.locs.no'];?>
       </TD>
      </TR>
      <TR>
       <TD CLASS="formfield">
        <INPUT TYPE="radio" NAME="loc" VALUE="t"
	 <?PHP if($locval=="t") print " CHECKED"; ?>>
       </TD>
       <TD CLASS="formfield">
        <?PHP print $tx['sd.locs.tbd'];?>
       </TD>
      </TR>
      <TR>
       <TD CLASS="formfield">
        <INPUT TYPE="radio" NAME="loc" VALUE="l"
	 <?PHP if($locval=="l") print " CHECKED"; ?>>
       </TD>
       <TD CLASS="formfield">
	<SELECT NAME="location">
	 <?PHP
          $locs = get_permitted_locations($_SESSION['mail'],
					$_SESSION['groups']);

          if($locs)
	  {
	    for($i = 0;$i < $locs['count'];$i++)
	    {
	      print '
          <OPTION VALUE="' . $locs[$i]['locationid'] . '"' .
		(($mtg['location'] == $locs[$i]['locationid']) ?
		 " SELECTED" : "")
		. '>' .	$locs[$i]['description'] . '</OPTION>
              ';
	    }
	  }
	 ?>
        </SELECT>
	<BR />
	<BR />
        <A HREF="../admin/location.php?locationid=new&return=<?PHP print urlencode("../schedule/location.php?mtgid=" . $rvar_mtgid);?>">[+]
        <?PHP print $tx['lc.loc.new'];?></A>
       </TD>
      </TR>
      </TABLE>
     </TD>
    </TR>
    <TR>
     <TD CLASS="formfield2">
      <INPUT TYPE="submit" VALUE="<?PHP print $tx['op.continue'];?>">
     </TD>
    </TR>
    </FORM>
   </TABLE>
  </TD>
 </TR>
</TABLE>
</BODY>
</HTML>
Return current item: Meeting Request Scheduling and Booking System