/** * Produce a string containing a textarea input inside a table row * * @param string $name the string used in the 'name' attribute * @param string $title the string used as the label * @param mixed $default a default value for the element * @param int $width an integer saying how many characters wide * the item should be * @param int $height an integer saying how many rows tall the * item should be * @param int $maxlength an integer used in the 'maxlength' attribute * @param string $attr a string of additional attributes to be put * in the element (example: 'id="foo"') * @param string $thattr a string of additional attributes to be put * in the <th> element (example: 'class="foo"') * @param string $tdattr a string of additional attributes to be put * in the <td> element (example: 'class="foo"') * @return string * * @access public * @static * @see HTML_Form::displayTextarea(), HTML_Form::displayTextareaRow(), * HTML_Form::returnTextareaRow(), HTML_Form::addTextarea() */ function returnTextareaRow($name, $title, $default = null, $width = 40, $height = 5, $maxlength = 0, $attr = '', $thattr = HTML_FORM_TH_ATTR, $tdattr = HTML_FORM_TD_ATTR) { $str = " <tr>\n"; $str .= ' <th ' . $thattr . '>' . $title . "</th>\n"; $str .= ' <td ' . $tdattr . ">\n "; $str .= HTML_Form::returnTextarea($name, $default, $width, $height, $maxlength, $attr); $str .= " </td>\n"; $str .= " </tr>\n"; return $str; }
print "<table>\n"; print " <tr>\n"; print " <td> </td>\n"; print " <td><b>{$errorMsg}</b></td>\n"; print " </tr>\n"; print "</table>\n"; } print "<form action=\"" . htmlspecialchars($_SERVER['PHP_SELF']) . "\" method=\"post\" name=\"request_form\">\n"; $bb = new BorderBox("Request a PECL account", "90%", "", 2, true); $bb->horizHeadRow("Username:"******"handle", $handle, 12)); $bb->horizHeadRow("First Name:", HTML_Form::returnText("firstname", $firstname)); $bb->horizHeadRow("Last Name:", HTML_Form::returnText("lastname", $lastname)); $bb->horizHeadRow("Password:"******"password", null, 10) . " Again: " . HTML_Form::returnPassword("password2", null, 10)); $bb->horizHeadRow("Need a php.net account?", HTML_Form::returnCheckbox("needsvn", $needsvn)); $bb->horizHeadRow("Email address:", HTML_Form::returnText("email", $email)); $bb->horizHeadRow("Show email address?", HTML_Form::returnCheckbox("showemail", $showemail)); $bb->horizHeadRow("Homepage", HTML_Form::returnText("homepage", $homepage)); $bb->horizHeadRow("Purpose of your PECL account<br />(No account is needed for using PECL or PECL packages):", HTML_Form::returnTextarea("purpose", stripslashes($purpose))); $bb->horizHeadRow("Sponsoring users<br />(Current php.net users who suggested you request an account and reviewed your extension/patch):", HTML_Form::returnTextarea("sponsor", stripslashes($sponsor))); $bb->horizHeadRow("More relevant information<br />about you (optional):", HTML_Form::returnTextarea("moreinfo", stripslashes($moreinfo))); $bb->horizHeadRow("Requested from IP address:", $_SERVER['REMOTE_ADDR']); $bb->horizHeadRow("<input type=\"submit\" name=\"submit\" value=\"Submit\" />"); $bb->end(); print "</form>"; if ($jumpto) { print "<script language=\"JavaScript\" type=\"text/javascript\">\n<!--\n"; print "if (!document.forms[1].{$jumpto}.disabled) document.forms[1].{$jumpto}.focus();\n"; print "\n// -->\n</script>\n"; } } response_footer();