コード例 #1
0
ファイル: upload.php プロジェクト: Cibale/sofascoreEDU
    $option = new \html_library\HTMLOptionElement();
    $option->add_attribute(new \html_library\HTMLAttribute('value', $values['ID']));
    $option->add_child(new \html_library\HTMLTextNode($values['title']));
    $options->add($option);
}
$input = new \html_library\HTMLSelectElement();
$input->add_attribute(new \html_library\HTMLAttribute('name', 'galleryOption'));
$input->add_children($options);
$fieldset->add_child($input);
$fieldset->add_child(new \html_library\HTMLBrElement());
//image tag textfield
$labelDescription = new \html_library\HTMLLabelElement();
$labelDescription->add_attribute(new \html_library\HTMLAttribute('for', 'tags'));
$labelDescription->add_child(new \html_library\HTMLTextNode('Tags (separated by space): '));
$fieldset->add_child($labelDescription);
$textArea = new \html_library\HTMLTextAreaElement();
$textArea->add_attribute(new \html_library\HTMLAttribute('name', 'img_tag'));
$textArea->add_attribute(new \html_library\HTMLAttribute('form', 'pic_upload'));
$textArea->add_attribute(new \html_library\HTMLAttribute('maxlength', 500));
$fieldset->add_child($textArea);
$fieldset->add_child(new \html_library\HTMLBrElement());
//submit
$inputSubmit = new \html_library\HTMLInputElement();
$inputSubmit->add_attribute(new \html_library\HTMLAttribute('type', 'submit'));
$inputSubmit->add_attribute(new \html_library\HTMLAttribute('name', 'Submit'));
$inputSubmit->add_attribute(new \html_library\HTMLAttribute('value', 'Submit'));
$fieldset->add_child($inputSubmit);
$link1 = new html_library\HTMLAElement();
$link1->add_attribute(new html_library\HTMLAttribute('href', 'index.php'));
$link1->add_child(new html_library\HTMLTextNode('Home page'));
$body->add_child($link1);
コード例 #2
0
ファイル: new_gallery.php プロジェクト: Cibale/sofascoreEDU
$fieldset->add_child($labelTitle);
$inputTitle = new \html_library\HTMLInputElement();
$inputTitle->add_attribute(new \html_library\HTMLAttribute('type', 'text'));
$inputTitle->add_attribute(new \html_library\HTMLAttribute('name', 'name'));
$inputTitle->add_attribute(new \html_library\HTMLAttribute('id', 'name'));
$inputTitle->add_attribute(new \html_library\HTMLAttribute('maxlength', 100));
$inputTitle->add_attribute(new \html_library\HTMLAttribute('placeholder', 'Name of your gallery'));
$inputTitle->add_attribute(new \html_library\HTMLAttribute('required', null));
$fieldset->add_child($inputTitle);
$fieldset->add_child(new \html_library\HTMLBrElement());
//description
$labelDescription = new \html_library\HTMLLabelElement();
$labelDescription->add_attribute(new \html_library\HTMLAttribute('for', 'description'));
$labelDescription->add_child(new \html_library\HTMLTextNode('Description: '));
$fieldset->add_child($labelDescription);
$textArea = new \html_library\HTMLTextAreaElement();
$textArea->add_attribute(new \html_library\HTMLAttribute('name', 'description'));
$textArea->add_attribute(new \html_library\HTMLAttribute('form', 'new_gallery'));
$textArea->add_attribute(new \html_library\HTMLAttribute('maxlength', 500));
$fieldset->add_child($textArea);
$fieldset->add_child(new \html_library\HTMLBrElement());
//submit
$inputSubmit = new \html_library\HTMLInputElement();
$inputSubmit->add_attribute(new \html_library\HTMLAttribute('type', 'submit'));
$inputSubmit->add_attribute(new \html_library\HTMLAttribute('name', 'Submit'));
$inputSubmit->add_attribute(new \html_library\HTMLAttribute('value', 'Submit'));
$fieldset->add_child($inputSubmit);
$link1 = new html_library\HTMLAElement();
$link1->add_attribute(new html_library\HTMLAttribute('href', 'index.php'));
$link1->add_child(new html_library\HTMLTextNode('Home page'));
$body->add_child($link1);
コード例 #3
0
ファイル: aboutPicture.php プロジェクト: Cibale/sofascoreEDU
$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));
$fieldset->add_child($textArea);
$fieldset->add_child(new \html_library\HTMLBrElement());
//submit
$inputSubmit = new \html_library\HTMLInputElement();
$inputSubmit->add_attribute(new \html_library\HTMLAttribute('type', 'submit'));
$inputSubmit->add_attribute(new \html_library\HTMLAttribute('name', 'Submit'));
$inputSubmit->add_attribute(new \html_library\HTMLAttribute('value', 'Submit'));
$fieldset->add_child($inputSubmit);
$link1 = new html_library\HTMLAElement();
$link1->add_attribute(new html_library\HTMLAttribute('href', 'index.php'));