moikano
Forum Replies Created
-
thank’s a lot… I confirm that with 6.0.6 the SELECTs work perfectly (for me)!!!
ps: @aurovrata thank you also for credit!!!
Hi,
I also have the same problem and after reading the code for a while I think I found the cause:
in the file “post-my-contact-form-7\public\class-cf7-2-post-public.php” there is the function “array_to_single()” that reduce the array to one single value BUT APPLY ALSO the “sanitize_key()” function to the value of select;
this function is called by “define_public_hooks()” in the file “post-my-contact-form-7\includes\class-cf7-2-post.php” and for the moment I bypassed it with this code in the “functions.php” of the theme:
add_filter( 'wpcf7_posted_data_select', 'debug_cf2post_not_sanitize_select', 0, 3 ); add_filter( 'wpcf7_posted_data_select*', 'debug_cf2post_not_sanitize_select', 0, 3 ); add_filter( 'wpcf7_posted_data_dynamic-select', 'debug_cf2post_not_sanitize_select', 0, 3 ); add_filter( 'wpcf7_posted_data_dynamic-select*', 'debug_cf2post_not_sanitize_select', 0, 3 ); function debug_cf2post_not_sanitize_select( $value, $org, $tag ) { if ( is_array( $value ) && isset( $_POST[ $tag->name ] ) && ! is_array( $_POST[ $tag->name ] ) ) { $value = $_POST[ $tag->name ]; } return $value; }
ps: I’m using 6.0.5 version of the plugin;
I hope this help someone;
Hi,
now every user that has “edit_posts” capabilitiy can use WP-Bannerize.
I know it isn’t the right solution (because everyone knows how to edit urls can bypass it easily), but for the moment I simply hide the menu items… in functions.php:
//hide wp-bannerize menu items to non administrators if ( is_admin() && ! current_user_can( 'administrator' ) ) { add_action( 'admin_menu', 'mwr_remove_wpbannerize' ); function mwr_remove_wpbannerize() { remove_menu_page( 'wp-bannerize-mainshow' ); } }
and for a minimal control I added:
//restrict to non administrators if ( ! current_user_can( 'administrator' ) ) { return __( 'Error: you have not sufficient privileges!', 'wp-bannerize' ); }
at the top of methods insertBanner(), setBannerToTrash(), unsetBannerToTrash(), deleteBanner(), updateBanner() and:
if ( ! current_user_can( 'administrator' ) ) { echo __( 'Error: you have not sufficient privileges!', 'wp-bannerize' ); return; }
at the top of method settings()… all these methods
of class WPBannerizeAdmin{} in wp-bannerize/Classes/wpBannerizeAdmin.php of WP-Bannerize 3.0.32.Hope this can be helpful until this feature will not be well developed directly in the plugin. ??
MoiKano
Hi Chris,
I’m glad you’ve solved ??
about the other problem I don’t know: are you sure that you didn’t assign also parent categories to the post?
to retrieve terms in the “main post type”‘s taxonomy (specified in the WP SEO Internal Links options), WP SEO Breadcrumbs uses wp_get_object_terms() that returns a list of terms in alphabetical order: the first in the list is the “parent” category of the post;
for example:
– with “Music” and “Music News”, “Music” is the post’s “parent”;
– with “Music”, “Music Reviews” and “Singles”, “Music” is the post’s “parent”;
– with “Music”, “Music Reviews” and “Concerts”, “Concerts” is the post’s “parent”;if this is your situation, the solution is very simple: assign posts to the “true” category only;
I hope this answers your question ??
Hi Chris,
I suppose you’re using WP SEO 0.2.5.4 (my report was for 0.2.3.2): if so, joostdevalk has updated partially the code… instead of to reverse the order in the get_term_parents() declaration, he reversed the order “directly” in the source, but not for tax/category/tag archives;
to solve this, you can simply to edit the original “wordpress-seo/frontend/class-breadcrumbs.php” on row #234 so:
[...] if ( is_taxonomy_hierarchical($term->taxonomy) && $term->parent != 0 ) { $parents = $this->get_term_parents($term, $term->taxonomy); // editing start // $parents = array_reverse( $parents ); // editing end // foreach($parents as $parent) { [...]
I hope you can to solve it ??