X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=lib%2Fform.php;h=f6501dc6daf699b0b190f748c459d34a064638f9;hb=1fd91de82c0be74ae2305f1412b1cd1b2948dfbc;hp=87b7a5cba91c42d0aea1b55ff62eea7a2e1d8712;hpb=5d09b6b3f0595540c66b703ae085f0af904fe30f;p=quix0rs-gnu-social.git diff --git a/lib/form.php b/lib/form.php index 87b7a5cba9..f6501dc6da 100644 --- a/lib/form.php +++ b/lib/form.php @@ -67,7 +67,7 @@ class Form extends Widget { $attributes = array('id' => $this->id(), 'class' => $this->formClass(), - 'method' => 'post', + 'method' => $this->method(), 'action' => $this->action()); if (!empty($this->enctype)) { @@ -119,6 +119,18 @@ class Form extends Widget { } + /** + * HTTP method used to submit the form + * + * Defaults to post. Subclasses can override if they need to. + * + * @return string the method to use for submitting + */ + function method() + { + return 'post'; + } + /** * Buttons for form actions * @@ -169,4 +181,14 @@ class Form extends Widget { return 'form'; } + + function li() + { + $this->out->elementStart('li'); + } + + function unli() + { + $this->out->elementEnd('li'); + } }