コード例 #1
0
ファイル: login.php プロジェクト: Cibale/sofascoreEDU
        }
    } else {
        $formValidation->display_validation_errors();
    }
}
$page = new html_library\HTMLHtmlElement();
$page->add_child(new html_library\HTMLHeadElement());
$body = new html_library\HTMLBodyElement();
$page->add_child($body);
$form = new \html_library\HTMLFormElement();
$body->add_child($form);
$form->add_attribute(new \html_library\HTMLAttribute('name', 'login'));
$form->add_attribute(new \html_library\HTMLAttribute('action', ''));
$form->add_attribute(new \html_library\HTMLAttribute('method', 'post'));
$form->add_attribute(new \html_library\HTMLAttribute('accept-charset', 'UTF-8'));
$legend = new html_library\HTMLLegendElement();
$legend->add_child(new \html_library\HTMLTextNode('Login'));
$form->add_child($legend);
$input = new html_library\HTMLInputElement();
$input->add_attribute(new \html_library\HTMLAttribute('type', 'hidden'));
$input->add_attribute(new \html_library\HTMLAttribute('name', 'submitted'));
$input->add_attribute(new \html_library\HTMLAttribute('id', 'submitted'));
$input->add_attribute(new \html_library\HTMLAttribute('value', '1'));
$form->add_child($input);
$ul = new \html_library\HTMLUlElement();
$form->add_child($ul);
$li1 = new \html_library\HTMLLiElement();
$li2 = new \html_library\HTMLLiElement();
$li3 = new \html_library\HTMLLiElement();
$ul->add_child($li1);
$ul->add_child($li2);
コード例 #2
0
ファイル: new_gallery.php プロジェクト: Cibale/sofascoreEDU
    }
}
//page rendering
$page = new html_library\HTMLHtmlElement();
$page->add_child(new html_library\HTMLHeadElement());
$body = new html_library\HTMLBodyElement();
$page->add_child($body);
$form = new \html_library\HTMLFormElement();
$body->add_child($form);
$form->add_attribute(new \html_library\HTMLAttribute('id', 'new_gallery'));
$form->add_attribute(new \html_library\HTMLAttribute('action', ''));
$form->add_attribute(new \html_library\HTMLAttribute('method', 'post'));
$form->add_attribute(new \html_library\HTMLAttribute('accept-charset', 'UTF-8'));
$fieldset = new \html_library\HTMLFieldsetElement();
$form->add_child($fieldset);
$legend = new html_library\HTMLLegendElement();
$legend->add_child(new \html_library\HTMLTextNode('Create new gallery'));
$fieldset->add_child($legend);
$submitInput = new \html_library\HTMLInputElement();
$submitInput->add_attribute(new \html_library\HTMLAttribute('type', 'hidden'));
$submitInput->add_attribute(new \html_library\HTMLAttribute('name', 'submitted'));
$submitInput->add_attribute(new \html_library\HTMLAttribute('id', 'submitted'));
$submitInput->add_attribute(new \html_library\HTMLAttribute('value', '1'));
$fieldset->add_child($submitInput);
//title
$labelTitle = new \html_library\HTMLLabelElement();
$labelTitle->add_attribute(new \html_library\HTMLAttribute('for', 'name'));
$labelTitle->add_child(new \html_library\HTMLTextNode('Title*: '));
$fieldset->add_child($labelTitle);
$inputTitle = new \html_library\HTMLInputElement();
$inputTitle->add_attribute(new \html_library\HTMLAttribute('type', 'text'));
コード例 #3
0
ファイル: registration.php プロジェクト: Cibale/sofascoreEDU
        }
    }
}
$page = new html_library\HTMLHtmlElement();
$page->add_child(new html_library\HTMLHeadElement());
$body = new html_library\HTMLBodyElement();
$page->add_child($body);
$form = new \html_library\HTMLFormElement();
$body->add_child($form);
$form->add_attribute(new \html_library\HTMLAttribute('id', 'register'));
$form->add_attribute(new \html_library\HTMLAttribute('action', ''));
$form->add_attribute(new \html_library\HTMLAttribute('method', 'post'));
$form->add_attribute(new \html_library\HTMLAttribute('accept-charset', 'UTF-8'));
$fieldset = new \html_library\HTMLFieldsetElement();
$form->add_child($fieldset);
$legend = new html_library\HTMLLegendElement();
$legend->add_child(new \html_library\HTMLTextNode('Register'));
$fieldset->add_child($legend);
$submitInput = new \html_library\HTMLInputElement();
$submitInput->add_attribute(new \html_library\HTMLAttribute('type', 'hidden'));
$submitInput->add_attribute(new \html_library\HTMLAttribute('name', 'submitted'));
$submitInput->add_attribute(new \html_library\HTMLAttribute('id', 'submitted'));
$submitInput->add_attribute(new \html_library\HTMLAttribute('value', '1'));
$fieldset->add_child($submitInput);
//name
$labelName = new \html_library\HTMLLabelElement();
$labelName->add_attribute(new \html_library\HTMLAttribute('for', 'name'));
$labelName->add_child(new \html_library\HTMLTextNode('Name*: '));
$fieldset->add_child($labelName);
$inputName = new \html_library\HTMLInputElement();
$inputName->add_attribute(new \html_library\HTMLAttribute('type', 'text'));
コード例 #4
0
ファイル: editphoto.php プロジェクト: Cibale/sofascoreEDU
$page = new html_library\HTMLHtmlElement();
$page->add_child(new html_library\HTMLHeadElement());
$body = new html_library\HTMLBodyElement();
$page->add_child($body);
$imagePrint = new \html_library\HTMLImageElement();
$imagePrint->add_attribute(new \html_library\HTMLAttribute('src', "picture.php?id={$pictureId}&size=original"));
$body->add_child($imagePrint);
$form = new \html_library\HTMLFormElement();
$body->add_child($form);
$form->add_attribute(new \html_library\HTMLAttribute('id', 'pic_upload'));
$form->add_attribute(new \html_library\HTMLAttribute('action', ''));
$form->add_attribute(new \html_library\HTMLAttribute('method', 'post'));
$form->add_attribute(new \html_library\HTMLAttribute('accept-charset', 'UTF-8'));
$fieldset = new \html_library\HTMLFieldsetElement();
$form->add_child($fieldset);
$legend = new html_library\HTMLLegendElement();
$legend->add_child(new \html_library\HTMLTextNode('Edit your picture'));
$fieldset->add_child($legend);
$submitInput = new \html_library\HTMLInputElement();
$submitInput->add_attribute(new \html_library\HTMLAttribute('type', 'hidden'));
$submitInput->add_attribute(new \html_library\HTMLAttribute('name', 'submitted'));
$submitInput->add_attribute(new \html_library\HTMLAttribute('id', 'submitted'));
$submitInput->add_attribute(new \html_library\HTMLAttribute('value', '1'));
$fieldset->add_child($submitInput);
//title
$labelTitle = new \html_library\HTMLLabelElement();
$labelTitle->add_attribute(new \html_library\HTMLAttribute('for', 'title'));
$labelTitle->add_child(new \html_library\HTMLTextNode('Title*: '));
$fieldset->add_child($labelTitle);
$inputTitle = new \html_library\HTMLInputElement();
$inputTitle->add_attribute(new \html_library\HTMLAttribute('type', 'text'));
コード例 #5
0
ファイル: aboutPicture.php プロジェクト: Cibale/sofascoreEDU
    $listElement->add_child($username);
    $listElement->add_child($commentData);
    $listElements->add_child($listElement);
}
$body->add_child($listElements);
$form = new \html_library\HTMLFormElement();
if (isset($_SESSION['user_id'])) {
    $body->add_child($form);
}
$form->add_attribute(new \html_library\HTMLAttribute('id', 'comment'));
$form->add_attribute(new \html_library\HTMLAttribute('action', ''));
$form->add_attribute(new \html_library\HTMLAttribute('method', 'post'));
$form->add_attribute(new \html_library\HTMLAttribute('accept-charset', 'UTF-8'));
$fieldset = new \html_library\HTMLFieldsetElement();
$form->add_child($fieldset);
$legend = new html_library\HTMLLegendElement();
$legend->add_child(new \html_library\HTMLTextNode('Add comment'));
$fieldset->add_child($legend);
$submitInput = new \html_library\HTMLInputElement();
$submitInput->add_attribute(new \html_library\HTMLAttribute('type', 'hidden'));
$submitInput->add_attribute(new \html_library\HTMLAttribute('name', 'submitted'));
$submitInput->add_attribute(new \html_library\HTMLAttribute('id', 'submitted'));
$submitInput->add_attribute(new \html_library\HTMLAttribute('value', '1'));
$fieldset->add_child($submitInput);
//comment
$textArea = new \html_library\HTMLTextAreaElement();
$textArea->add_attribute(new \html_library\HTMLAttribute('name', 'comment_data'));
$textArea->add_attribute(new \html_library\HTMLAttribute('form', 'comment'));
$textArea->add_attribute(new \html_library\HTMLAttribute('required', null));
$textArea->add_attribute(new \html_library\HTMLAttribute('placeholder', 'Type your comment here..'));
$textArea->add_attribute(new \html_library\HTMLAttribute('maxlength', 500));