wp_enqueue_style('jquery-style', '//ajax.googleapis.com/ajax/libs/jqueryui/1.8.2/themes/smoothness/jquery-ui.css');
if(is_front_page()) {
}
+ /*
if ( isset( $post ) && in_array( $post->ID, array( 3193, 3194, 3195, 3196, 3197, 3200, 3309, 3303, 3315, 3307 ) ) ) {
wp_enqueue_script(
'discover-survey',
true
);
}
-
+ */
}
function is_post_type($type){
}
/*
- * If the current user is not an admin and is a member,
- * return 'sunrise' as the default admin color
+ * If the current user is not an admin and is a member,
+ * return 'sunrise' as the default admin color
*/
add_filter('get_user_option_admin_color', function($result) {
if (!current_user_can('administrator') && current_user_can("glm_members_member")) {
/**
* Function Name: front_end_login_fail.
* Added for: GLM Member DB front-end login failure custom redirection.
- * Description: This redirects the failed login to the custom login page
+ * Description: This redirects the failed login to the custom login page
* instead of default login page with a modified url
**/
add_action( 'wp_login_failed', 'front_end_login_fail' );
function front_end_login_fail( $username ) {
// Getting URL of the login page
- $referrer = $_SERVER['HTTP_REFERER'];
+ $referrer = $_SERVER['HTTP_REFERER'];
// if there's a valid referrer, and it's not the default log-in screen
if( !empty( $referrer ) && !strstr( $referrer,'wp-login' ) && !strstr( $referrer,'wp-admin' ) ) {
- wp_redirect( get_permalink( get_option('glm_members_database_option_members_only_id') ) . "?login=failed" );
+ wp_redirect( get_permalink( get_option('glm_members_database_option_members_only_id') ) . "?login=failed" );
exit;
}
}
/**
* Function Name: front_end_blank_credentials.
* Added for: GLM Member DB front-end login failure custom redirection.
- * Description: This redirects to the custom login page if user name or
+ * Description: This redirects to the custom login page if user name or
* password is empty with a modified url
**/
add_action( 'authenticate', 'front_end_blank_credentials', 1, 3);
// Getting URL of the login page
$referrer = $_SERVER['HTTP_REFERER'];
// if there's a valid referrer, and it's not the default log-in screen
- if( !empty( $referrer ) && !strstr( $referrer,'wp-login' ) && !strstr( $referrer,'wp-admin' ) ) {
+ if( !empty( $referrer ) && !strstr( $referrer,'wp-login' ) && !strstr( $referrer,'wp-admin' ) ) {
if( $username == "" || $password == "" ){
wp_redirect( get_permalink( get_option('glm_members_database_option_members_only_id') ) . "?login=empty" );
exit;
}
}
-}
+}
?>