function is_valid_form_id($formid, $date, $username = "") { if ($username == "") { $username = Yii::app()->user->name; } return $formid == make_unique_form_id($date, $username); }
<?php StdLib::Functions(); Flashes::render(); ?> <div class="well" style="background-color:inherit;"> <form class="form-horizontal" id="edit-syllabus-form" method="post" enctype="multipart/form-data"> <input type="hidden" value="<?php echo make_unique_form_id(); ?> " name="uniqueformid" id="uniqueformid" /> <input type="hidden" value="<?php echo date("Y-m-d H:i:s"); ?> " name="datetime" id="datetime" /> <input type="hidden" name="id" id="id" value="<?php echo @$_REQUEST["id"]; ?> " /> <fieldset> <legend>Edit Course Syllabus</legend> <div class="bs-component" id="alert-field"> <div class="alert dismissible alert-warning" style="display:none;"> <button type="button" class="close" data-dismiss="alert">×</button> <p></p> </div> <div class="alert dismissible alert-success" style="display:none;"> <button type="button" class="close" data-dismiss="alert">×</button> <p></p> </div>