예제 #1
0
//    $buffer .= 'header("Cache-Control: public")';
//    $buffer .= 'header("Content-Description: File Transfer")';
//    $buffer .= 'header("Content-Disposition: attachment; filename='.$pageName.'.html")';
//    $buffer .= 'header("Content-Type: application/octet-stream; ")';
//    $buffer .= 'header("Content-Transfer-Encoding: binary")';
$buffer .= Boostrap::openForm($pageName, $attribute);
echo Boostrap::openForm($pageName, $attribute);
//    echo $db->getLastPage();
$buffer .= $code;
echo $code;
$buffer .= Boostrap::closeForm();
echo Element::buttonLink("download Code", "index.php?download=true");
echo Boostrap::closeForm();
/////////////////////////////////
if (isset($_GET['download']) && $_GET['download'] == true) {
    Log::writeFile($pageName, $buffer);
}
/////////////////////////////////
$attribute = array('class' => $isBoostrap ? 'form-horizontal' : '', 'action' => 'index.php', 'id' => 'name');
echo Boostrap::openForm("Create a new form", $attribute);
echo str_replace('{text}', 'Form Name', Element::text(array('label' => 'Form Name', 'placeholder' => '', 'help' => ''), 'textinput', false));
echo Element::button("New");
echo Boostrap::closeForm();
//////////////////////////////
// open form
$attribute = array('class' => $isBoostrap ? 'form-horizontal' : '', 'action' => 'index.php');
echo Boostrap::openForm("Add elements to form", $attribute);
// open form
// make the form body here
/////////////////////////////////////////////////
echo str_replace('{button}', ' ', Element::text(array('label' => "Question Name", 'placeholder' => "Type name tag", 'help' => "Type name tag here")));