<?php include 'form.php'; $title = "card1"; $desc = "input1"; $s_titles = array('sub 1', 'sub2', "sub_3"); $s_contents = array('content of sub 1', 'content of sub 2', 'cuntent of sub tre'); $card1 = create_card($title, $desc, $s_titles, $s_contents); //card is a page //$card2 = create_card("title","description",array("sub_ttiles"),array("$contents"));basic //function input_form($input_name,$input_id,$type) $form = create_form(input_form("E-mail", "email", "text")); $form = $form . "" . create_form(input_form("Password", "pass", "password")); $card = create_card("Sample Form", $form, array(""), array("")); $content = $card; newpage($content); ?> </body> </html>
} include "template/post/{$var_post_template}"; $DMSGuestbookContent .= $GuestbookEntries1; if ($dbresult->gravatar != "" && $var_gravatar == 1) { $DMSGuestbookContent .= $GuestbookEntries2; } $DMSGuestbookContent .= $GuestbookEntries3; $DMSGuestbookContent .= "</div>"; $DMSGuestbookContent .= $GuestbookEntries4; } // show bottom navigation $DMSGuestbookContent .= navigation($num_rows1, $var_step, $var_width, $backward, $forward); // if guestbook form is on bottom the side if ($var_formpos == "bottom") { $DMSGuestbookContent .= "<a name='guestbookform' class='css_form_link'></a>"; $DMSGuestbookContent .= input_form($error1, $error2, $error3, $error4, $error5, $error6, $success, $url, $var_page_id, $lang_name, $lang_email, $var_require_email, $lang_url, $var_require_url, $lang_message, $submitid, $lang_require, $var_require_antispam, $lang_antispam, $lang_submit, $var_url_overruled, $var_mandatory_char, $var_form_template, $var_antispam_key, $var_captcha_color, $var_gravatar, $var_additional_option, $var_additional_option_title, $var_recaptcha_publickey, $var_messagetext_length); } $DMSGuestbookContent .= "</div>"; function input_form($error1, $error2, $error3, $error4, $error5, $error6, $success, $url, $var_page_id, $lang_name, $lang_email, $var_require_email, $lang_url, $var_require_url, $lang_message, $submitid, $lang_require, $var_require_antispam, $lang_antispam, $lang_submit, $var_url_overruled, $var_mandatory_char, $var_form_template, $var_antispam_key, $var_captcha_color, $var_gravatar, $var_additional_option, $var_additional_option_title, $var_recaptcha_publickey, $var_messagetext_length) { $gbadditional_selectbox = isset($gbadditional_selectbox) ? $gbadditional_selectbox : ''; $captcha2 = isset($captcha2) ? $captcha2 : ''; $recaptcha = isset($recaptcha) ? $recaptcha : ''; $DMSGuestbookContent = isset($DMSGuestbookContent) ? $DMSGuestbookContent : ''; $_REQUEST['gbname'] = isset($_REQUEST['gbname']) ? $_REQUEST['gbname'] : ''; $_REQUEST['gbemail'] = isset($_REQUEST['gbemail']) ? $_REQUEST['gbemail'] : ''; $_REQUEST['gburl'] = isset($_REQUEST['gburl']) ? $_REQUEST['gburl'] : ''; $_REQUEST['gbgravataremail'] = isset($_REQUEST['gbgravataremail']) ? $_REQUEST['gbgravataremail'] : ''; $_REQUEST['gbmsg'] = isset($_REQUEST['gbmsg']) ? $_REQUEST['gbmsg'] : ''; $_REQUEST['gbadditional'] = isset($_REQUEST['gbadditional']) ? $_REQUEST['gbadditional'] : ''; $captcha1 = isset($captcha1) ? $captcha1 : '';
$residence = input_form("Residence", "residence", "area"); $username = input_form("Username", "username", "text"); $password = input_form("Password", "password", "password"); $retype_password = input_form("Re-type Password", "re-pass", "password"); $submit = input_form("Submit", "submit", "submit"); $section1 = card_break("Login Information", $username . "" . $password . "" . $retype_password); $section2 = card_break("Personal Information", $fname . "" . $mname . "" . $lname . "" . $sex . "" . $residence . "" . $submit); $form = create_form($section1 . "" . $section2); $card = create_card($title, $form); $content = $err . "" . $card; newpage($content); } } else { $title = "Register a new Personnel"; $desc = ""; $fname = input_form("Firstname", "fname", "text"); $mname = input_form("Middlename", "mname", "text"); $lname = input_form("Lastname", "lname", "text"); $sex = multi("Sex", "sex", array("Male", "Female"), array("male", "female"), "radio"); $residence = input_form("Residence", "residence", "area"); $username = input_form("Username", "username", "text"); $password = input_form("Password", "password", "password"); $retype_password = input_form("Re-type Password", "re-pass", "password"); $submit = input_form("Submit", "submit", "submit"); $section1 = card_break("Login Information", $username . "" . $password . "" . $retype_password); $section2 = card_break("Personal Information", $fname . "" . $mname . "" . $lname . "" . $sex . "" . $residence . "" . $submit); $form = create_form($section1 . "" . $section2); $card = create_card($title, $form); $content = $card; newpage($content); }
case "vote": if (!auth_required()) { if (!vote_request()) { vote_form(); } } return; default: if (!auth_required()) { if (vote_form()) { return; } } } } input_form(); function auth_required() { try { global $voters, $pin; if (!isset($_GET['time'])) { $uid = hash("sha512", $_GET['boi'] . $_GET['prezime'] . $_GET['oib'] . $_GET['ime'] . $_GET['mbg']); } else { return false; } $user = null; try { $user = scraperwiki::select("* from swdata where BIRAČ='" . $uid . "'"); } catch (Exception $e) { } if ($user == null) {