function PrintFormFormForReEntry($Type) { $CurrentPage = htmlspecialchars($_SERVER["PHP_SELF"]); //Determinte the introduction to give to the form. if ($Type == 0) { echo 'Error, Please Compleate form bellow:</br></br>'; } elseif ($Type == 1) { echo 'Error, Incorrect Username or Password:</br></br>'; } require 'FormBuilder.php'; $FormCreator = new FormBuilder(); echo '<span id=LogInFormContainer>'; echo $FormCreator->StartForm($PageCreationInstruction = array("Methord" => "post", "Action" => 1, "id" => "LogInForm")); $InputsRequired = array(array("InputLabel" => "UserName: "******"OptInputHTMLSeperator" => "<br>", "Options" => array(array('type', 'text'), array('value', $_POST["RAWUserName"]), array("maxlength", 100), array("name", "RAWUserName"))), array("InputLabel" => "Password: "******"Options" => array(array('type', 'password'), array("maxlength", 100), array("name", "Password")))); echo $FormCreator->CreateStandardInput($InputsRequired); echo '<br>'; echo $FormCreator->CreateSubmitButton(); echo $FormCreator->EndForm(); echo '<span/>'; /* //Print the form to the page. echo "<form method=\"post\" action=\"$CurrentPage\" >"; //Submits Data to self if(isset($_POST["RAWUserName"])){//Add the submitted user name if avaliable echo 'User: <input type="text" name="RAWUserName" value="' . $_POST["RAWUserName"] . '"/></br>'; }else{ echo 'User: <input type="text" name="RAWUserName" /></br>'; } echo 'Password: <input type="Password" name="Password"/></br>'; echo '</br>'; echo '<input type="submit" value="Log In"/>'; echo "</form>"; */ }
<?php //This is the send message form, include it in any location that you wish to have the messages submit form: //Really need to not use this formbuilder... require 'FormBuilder.php'; $FormCreator = new FormBuilder(); echo '<span id=SendMessageFormContainer>'; echo $FormCreator->StartForm($PageCreationInstruction = array("Methord" => "post", "Action" => 1, "id" => "SendMessageForm", "class" => "UserForm")); echo '<span id="NameTextBoxLabel">Name:</span>'; echo '<span id="NameTextBoxContainer">'; $InputsRequired = array(array("OptInputHTMLSeperator" => "<br>", "Options" => array(array('type', 'text'), array('value', $_POST["Name"]), array("maxlength", 20), array("name", "Name"), array("id", "NameTextBox")))); echo $FormCreator->CreateStandardInput($InputsRequired); echo '</span><span id="EmailText">Email: </span><span id="EmailInputBound"><br><input type="text" name="emailAddressInput" id="emailAddressInput"/></span><br><br>Message:'; if (isset($_POST['UserMessage'])) { $TextArreaContents = $_POST['UserMessage']; } else { $TextArreaContents = ""; } echo '<textarea name="UserMessage" id="UserMessage">' . $TextArreaContents . '</textarea>'; echo '<br><br><span id="GoogleAntiSpanStyleBuffer"></span>'; //Google Recaptcha: echo '<div id="html_element"></div>'; echo '<br><br><span id="submitMessageFormButtonContainer"><button id="submitMessage" type="submit">Submit Message</button></span>'; echo $FormCreator->EndForm(); ?>