a problem in class in class-wp-hook.php
a problem in class in class-wp-hook.php
a problem in class in class-wp-hook.php
OK, just to clarify your question. Your problem is with the search form not appearing in the top right corner? All I see there is a search image, but no input field. The search functionality does work on your site, eg: http://lunetours.com/?s=destination but something’s not configured properly there either, as it’s not returning any results. … Read more
The use of function_exists is a very bad habit that should simply be avoided in favor of using actions and filters. If you want child themes to be able to override some functionality you need to be very specific about which one and how, and function_exists is usually not specific enough for that.
found a solution: thought it might be worth sharing… //// We use $gallery_media as an array containing all attachment IDs that have been approved by the admin before $args = array( ‘post_type’ => ‘attachment’, ‘posts_per_page’ => -1, ‘orderby’ => ‘post_date’, ‘order’ => ‘ASC’, ‘post_status’ =>’any’, ‘post_parent’ => $post->ID, // This queries a custom field I … Read more
My solution: generate a backtrace in the function and bail early if called from validate_active_plugins(). function action_option_active_plugins( $value, $option ) { // Look at the call backtrace and bail early if called from validation function. $backtrace = debug_backtrace( 2 ); // Exclude [‘object’] and [‘args’] foreach( $backtrace as $frame ) { if( $frame[‘function’] === ‘validate_active_plugins’ … Read more
Have your function return your HTML rather than echo it. Perform the logic in the function to see if the image/logo are present and only return the HTML if that’s the case, otherwise returning null/false. function my_header_function( $output = false ) { if ( /*image and logo have been uploaded */ ) { $output = … Read more
The after_setup_theme hook is actually an action hook not a filter hook. Nonetheless that should not be needed. Give this a try: if( ! function_exists( ‘get_field’ ) ) { function get_field( $key, $post_id = false, $format_value = true ) { if( false === $post_id ) { global $post; $post_id = $post->ID; } return get_post_meta( $post_id, … Read more
Plugin Development – Call to undefined function comment_exists()
I have an fatal error on my funcyions.php
parent theme function doesn’t affect child theme post output