Plugin option for input box validation

You want to set the input’s type to number for numeric validation. And use the input’s value to set a default value. <input type=”number” id=”title” name=”my_option_namePlugin option for input box validation” value=123 /> If you just want a hint displayed to the user inside the input, use placeholder. <input type=”number” id=”title” name=”my_option_namePlugin option for input … Read more

Remove Edit Profile option but still have the profile viewable

add_filter( ‘wpmem_register_form_rows’, ‘prefix_profile’, 9999, 2 ); function prefix_profile( $rows, $toggle ){ if( ‘edit’ == $toggle ){ foreach( $rows as $row_item ){ $rows[$row_item[‘meta’]][‘field’] = preg_replace( ‘/<input(.*) value=”(.*)” class=”textbox”(.*)\/>/’, ‘<p class=”noinput”>$2&nbsp;</p>’, $row_item[‘field’] ); $rows[$row_item[‘meta’]][‘label’] = str_replace( ‘*’, ”, $row_item[‘label’] ); } } return $rows; }

AJAX call in backend results in empty update_option

I figured it out, when registering with register_setting the second parameter is the name of the settings you will be saving and updating, the parameter is pass in here to whitelist it against being updated outside of the plugin. The AJAX callback is deemed outside of the plugin. My register settings is below and the … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)