Conditional statements using category and Tags
If you’re viewing a category or tag archive, you can access that category or tag object via get_queried_object() $queried_object = get_queried_object(); echo $queried_object->name;
If you’re viewing a category or tag archive, you can access that category or tag object via get_queried_object() $queried_object = get_queried_object(); echo $queried_object->name;
Whilst you’ve got the right idea, it won’t work in this case. Taking a look at the source code, the class is simply instantiated without an assign. There’s no way to get a hold of $this from outside the class, and so no way for you to remove the hooks it attaches itself to. This … Read more
i agree with s_ha_dum, this is not exactly very protective… but what you could do is build a validation form with jquery and if it passes then convert into the actual password. example: real password you created: 0123456789 user enters any ten digits: 6537268574 with jquery you can store the value entered somewhere (if you … Read more
I solved id by myself. For those who want do the same trick: go to bliss-facebook-likebox plugin folder, edit cool-fb-likebox.php. Near the bottom of file there will be an $url variable. Change: $url = urlencode($get_cfbl_options[‘fbpageurl’]); to: wp_reset_query(); global $post; $site-id = 1; // use your own needed number if( is_page($site-id) || $post->post_parent == ‘.$site-id.’) { … Read more
There are only a few reliable filters for front end content, the_content being the only one that seems reasonably applicable. With that you can insert content in the post body. There are also actions like template_redirect and template_include but I doubt those execute where you want them to and using them could be tricky anyway. … Read more
This can be done a lot easier. It is just necessary to change the permalinks settings accordingly – as mentioned on github at the issue 3145: Meet this criteria: // If permalinks contain the shop page in the URI prepend the breadcrumb with shop if ( $shop_page_id && strstr( $permalinks[‘product_base’], “https://wordpress.stackexchange.com/” . $shop_page->post_name ) && … Read more
I think I already had this problem some month ago. It may help you to add the following code to your themes functions.php: http://pastebin.com/KbjS4ZeG The problem in this case was actually located in a wp core function (redirect_canonical() in wp-includes/canonical.php) which tries to “repair” broken/malformed url’s instead of showing an 404 error and ist not … Read more
Contact Form 7 saves forms and data to the database and not in a directory, except for cahced images like captchas. Revert the database to recover old forms. Updating the plugin may irrevocably update the form data, too, so that may be why the forms disappeared.
Sounds like you don’t need the querying power taxonomies will offer, but it would make sense to use if you think you’ll frequently have the same authors publishing; reduces redundant data (i.e. lots of the same entries in post meta) and improves the UX for administrators. Same applies for websites; if there’ll be many with … Read more
How can I use multi Media Uploader in a plugin?