\n"; echo '
\n"; echo ' '; if (strlen(trim($howtotext))) { echo ''; echo $howtotext; echo "
\n"; } } else { echo __('Invalid call to wphelper_form_textarea() - name or label is missing.', 'wphelper'); } } endif; if ( ! function_exists( 'wphelper_form_wpeditor' ) ) : function wphelper_form_wpeditor($name= '', $prevalue = '', $labeltext = '', $howtotext = '', $small = true) { $name = wphelper_san( $name ); $labeltext = wphelper_san( $labeltext ); if (!empty($name) && !empty($labeltext)) { echo "\n"; echo '
\n"; if ($small==true) { wp_editor( $prevalue, $name, array('teeny' => true, 'textarea_rows' => 5, 'media_buttons' => false) ); } else { wp_editor( $prevalue, $name ); } if (strlen(trim($howtotext))) { echo ''; echo $howtotext; echo "
\n"; } } else { echo __('Invalid call to wphelper_form_wpeditor() - name or label is missing.', 'wphelper'); } } endif; if ( ! function_exists( 'wphelper_form_text' ) ) : function wphelper_form_text($name= '', $prevalue = '', $labeltext = '', $howtotext = '', $placeholder='', $size = 0) { $name = wphelper_san( $name ); $labeltext = wphelper_san( $labeltext ); if (!empty($name) && !empty($labeltext)) { echo "\n";
echo '
\n";
echo ' 0) {
echo ' size="'.$size.'"';
} else {
echo ' class="large-text"';
}
echo ' name="'.$name.'" id="'.$name.'" value="'.$prevalue.'"';
if (strlen(trim($placeholder))) {
echo ' placeholder="'.$placeholder.'"';
}
echo " />\n";
echo "
'; echo $howtotext; echo "
\n"; } } else { echo __('Invalid call to wphelper_form_text() - name or label is missing.', 'wphelper'); } } endif; if ( ! function_exists( 'wphelper_form_email' ) ) : function wphelper_form_email($name= '', $prevalue = '', $labeltext = '', $howtotext = '', $placeholder='', $size = 0) { $name = wphelper_san( $name ); $labeltext = wphelper_san( $labeltext ); if (!empty($name) && !empty($labeltext)) { echo "\n";
echo '
\n";
echo ' 0) {
echo ' size="'.$size.'"';
} else {
echo ' class="large-text"';
}
echo ' name="'.$name.'" id="'.$name.'" value="'.$prevalue.'"';
if (strlen(trim($placeholder))) {
echo ' placeholder="'.$placeholder.'"';
}
echo " />\n";
echo "
'; echo $howtotext; echo "
\n"; } } else { echo __('Invalid call to wphelper_form_email() - name or label is missing.', 'wphelper'); } } endif; if ( ! function_exists( 'wphelper_form_number' ) ) : function wphelper_form_number($name= '', $prevalue = '', $labeltext = '', $howtotext = '', $min = 0, $max = 0, $step=1) { $name = wphelper_san( $name ); $labeltext = wphelper_san( $labeltext ); if (!empty($name) && !empty($labeltext)) { echo "\n";
echo '
\n";
echo ' 0) {
echo ' min="'.$min.'"';
}
if ($max>0) {
echo ' max="'.$max.'"';
}
if ($step>1) {
echo ' step="'.$step.'"';
}
echo " />\n";
echo "
'; echo $howtotext; echo "
\n"; } } else { echo __('Invalid call to wphelper_form_number() - name or label is missing.', 'wphelper'); } } endif; if ( ! function_exists( 'wphelper_form_url' ) ) : function wphelper_form_url($name= '', $prevalue = '', $labeltext = '', $howtotext = '', $placeholder='http://', $size = 0) { $name = wphelper_san( $name ); $labeltext = wphelper_san( $labeltext ); if (!empty($name) && !empty($labeltext)) { echo "\n";
echo '
\n";
echo ' 0) {
echo ' length="'.$size.'"';
}
echo " />\n";
echo "
'; echo $howtotext; echo "
\n"; } } else { echo __('Invalid call to wphelper_form_url() - name or label is missing.', 'wphelper'); } } endif; if ( ! function_exists( 'wphelper_form_onoff' ) ) : function wphelper_form_onoff($name= '', $prevalue = 0, $labeltext = '', $howtotext = '' ) { $name = wphelper_san( $name ); $labeltext = wphelper_san( $labeltext ); if (!empty($name) && !empty($labeltext)) { ?>
'; echo $howtotext; echo "
\n"; } echo '\n";
echo '
\n";
echo '';
echo "
\n";
echo '
\n";
echo '';
echo "