示例#1
0
                        <td align="right"> 
                          <?php 
        if ($nextid) {
            echo "<a href='showdocpc.php?id={$nextid}&lid={$lid}&ck={$very}{$peekarg}&y=2005&pos=" . ($pos + 1) . "'>Next</a>";
        } else {
            echo '&nbsp;';
        }
        ?>
                        </td>
                      </tr>
                 
            </table>
			  <h3>Curriculum Vitae</h3>
			  <p>
<?php 
        $cv = $doc->getcv(0);
        if ($cv) {
            echo "Curriculum Vitae is available on file. ";
            //echo " (<a href='?id=$docid&delete=cv'>Click Here to Delete CV</a>)";
        }
        ?>
			  If you have their updated CV, <a href='cvfile.php<?php 
        echo "?id={$docid}&lid={$lid}&ck={$very}{$peekarg}&y=2005&pos={$pos}";
        ?>
'>click here to upload it</a>. <em><br>
Save the  changes before clickin'!</em></p>
			  
			  <h3>Section 2 - Profile</h3>
				<input type="hidden" name="licensed" id="licensed" value="<?php 
        echo $doc->licensed;
        ?>
示例#2
0
    } catch (Exception $e) {
        $result = false;
        $mesg = 'Can not send CV: ' . $e->getMessage() . ' (' . $e->getCode() . ')';
    }
}
$cvacc = 0;
if ($UUID && $ACCESS && $docid) {
    try {
        if (!$db) {
            $db = db_career();
        }
        if (!$doc) {
            $doc = new Physician($db, $docid);
        }
        if (!$cv) {
            $cv = $doc->getcv();
        }
        $key = substr(md5($cv->filename . $doc->fname . $doc->lname), 0, 8);
        if (isset($_POST['submit']) || isset($_POST['submit1']) || isset($_POST['submit2'])) {
            // do stuff
            if ($_REQUEST["permit"] === "yes") {
                if (is_uploaded_file($_FILES['userfile']['tmp_name'])) {
                    $file_size = $_FILES['userfile']['size'];
                    if (!$file_size || $file_size > 2 * 1024 * 1024.0) {
                        throw new Exception('File is too big. Size limit is 2Mb', __LINE__);
                    }
                    if ($cv) {
                        // replace
                        unlink("{$STORAGE_DIR}/{$cv->internal}");
                    }
                    $doc->savecv($_FILES['userfile']);