Marie Comet
Forum Replies Created
-
Forum: Plugins
In reply to: [GEO my WP] Problem with filter results by stateOkay solved by myself :
If intersted someone, you need to change thisfunction gmw_state_filter( $clauses, $gmw ) { global $wpdb; /* * we first do a form check to make sure we only filter the search form that we want. * for this example I will use form with ID 1 */ if ( $gmw['ID'] != 1 ) return $clauses; /* * check if a state value exists. * everytime the state value exists in URL the search query below will take over * and filter results based on that state. * That is the reason we keep giving the states select box the deafult value on page load. * To preven visitors from having to manually change it back to deafult when * they want to do a proximity search based on address instead of state */ if ( !isset( $_GET['gmw_state'] ) || empty( $_GET['gmw_state'] ) ) return $clauses; //get the sate value from URL $state_value = $_GET['gmw_state']; //filter the tables clauses $clauses['fields'] = " wp_posts.*, gmwlocations.* "; //filter the WHERE cluase to look for locations with based on thier state $clauses['where'] .= $wpdb->prepare(" AND gmwlocations.state_long = %s", $state_value ); $clauses['groupby'] = "$wpdb->posts.ID"; //order results by state name since we cannot orde rby distance $clauses['orderby'] = "$wpdb->posts.post_title"; return $clauses; } add_filter( 'gmw_pt_location_query_clauses', 'gmw_state_filter', 99, 2 );By :
function gmw_state_filter( $clauses, $gmw ) { global $wpdb; /* * we first do a form check to make sure we only filter the search form that we want. * for this example I will use form with ID 1 */ if ( $gmw['ID'] != 1 ) return $clauses; /* * check if a state value exists. * everytime the state value exists in URL the search query below will take over * and filter results based on that state. * That is the reason we keep giving the states select box the deafult value on page load. * To preven visitors from having to manually change it back to deafult when * they want to do a proximity search based on address instead of state */ if ( !isset( $_GET['gmw_state'] ) || empty( $_GET['gmw_state'] ) ) return $clauses; //get the sate value from URL $state_value = $_GET['gmw_state']; //filter the WHERE cluase to look for locations with based on thier state $clauses['where'] .= $wpdb->prepare(" AND gmwlocations.state_long = %s", $state_value ); return $clauses; } add_filter( 'gmw_pt_location_query_clauses', 'gmw_state_filter', 99, 2 );Hi,
My problem was a string translation that I had written directly to my theme.
By withdrawing my problem was solved.
Silly problem, hoping that it helps you.Solved.
Forum: Plugins
In reply to: [WP Vegas] Firefox v35 images clippingHello, i have the same problem.
I remplaced the WP Vegas Slider by the Slider Vegas, but it’s the same.
So, is there a solution?Marie.