Untitled Snippet
upload_max_filesize = 32M post_max_size = 64M memory_limit = 128M ?>Continue reading
Join 2,000,000+ Professionals who use WPCode to Future-Proof Their Websites!
upload_max_filesize = 32M post_max_size = 64M memory_limit = 128M ?>Continue reading
upload_max_filesize = 256M post_max_size = 256M max_execution_time = 300 />Continue reading
function mepr_only_with_coupon( $errors ) { $membership_id = 123; //Change this ID to your membership ID $coupons = array( ‘IMRECOMMENDED’, ‘DISCOUNTED’ ); //Change these titles to your coupon title(s) if( $_POST[‘mepr_product_id’] == $membership_id ) { if( !isset( $_POST[‘mepr_coupon_code’] ) || empty(…Continue reading
function mepr_must_fill_out_coupon_code( $errors ) { if( !isset($_POST[‘mepr_coupon_code’]) || empty($_POST[‘mepr_coupon_code’] ) ) { $errors[] = “You must fill out the Coupon code field before registering.”; } return $errors; } add_filter( ‘mepr-validate-signup’, ‘mepr_must_fill_out_coupon_code’, 11, 1 );Continue reading
function auto_vote_5_stars_on_publish($ID, $post) { if ($post->post_status === ‘publish’) { if (function_exists(‘kk_star_ratings_insert’)) { kk_star_ratings_insert(“5”, $ID); } } } add_action(‘publish_post’, ‘auto_vote_5_stars_on_publish’, 10, 2);Continue reading
function mepr_disable_admin_pw_changed_email( $recipients, $subject, $message, $headers ) { if( strpos( $subject, ‘Password Lost/Changed’ ) !== false ) { $recipients = array(); // no recipients } return $recipients; } add_filter( ‘mepr-wp-mail-recipients’, ‘mepr_disable_admin_pw_changed_email’, 11, 4 );Continue reading
function mepr_remove_countries( $countries, $prioritize_my_country ) { return array ( ‘DE’ => _x( ‘Germany’, ‘ui’, ‘memberpress’ ) ); } add_filter( ‘mepr_countries’, ‘mepr_remove_countries’, 10, 2 );Continue reading
/** * Adding custom fonts to Generate Press * https://docs.generatepress.com/article/adding-local-fonts/ */ // allows the following to be uploaded add_filter( ‘upload_mimes’, function( $mimes ) { $mimes[‘woff’] = ‘application/x-font-woff’; $mimes[‘woff2’] = ‘application/x-font-woff2’; $mimes[‘ttf’] = ‘application/x-font-ttf’; $mimes[‘svg’] = ‘image/svg+xml’; $mimes[‘eot’] = ‘application/vnd.ms-fontobject’; return…Continue reading