How to get the current scroll top position?
How to get the current scroll top position? Copy and past the following codes below to your JS file.
var current_scroll = window.scrollY; console.log( current_scroll );
Header hooks and filters Remove site description add_action( 'genesis_site_description', 'genesis_seo_site_description' ); Custom Logo structure add_filter( 'genesis_seo_title', 'genesis_custom_seo_title', 10, 3 ); function genesis_custom_seo_title( $title ) { if( get_header_image() ){ $title .= '<div class="logo-wrap">'; $title .= '<a class="logo-image" href="'.get_bloginfo('url').'" title="'.get_bloginfo('name').'">'; $title .= '<img src="'.get_header_image().'" alt="'.get_bloginfo('name').'"/>'; $title .= '</a>'; $title .= '</div>'; }else{ $title = '<h1 class="site-title">'.get_bloginfo('name').'</h1>'; }…
Override rtMedia media-gallery.php template into current WordPress theme is now not a problem. For example you have artist role in your users and you want different template for the artist role. This apply in `http://www.sample.com/members/artist/media/music/` page. add_filter( 'rtmedia_template_filter', 'rtmedia_template_filter_override', 10, 3 ); function rtmedia_template_filter_override( $template ){ global $bp; $role = get_user_meta( $bp->displayed_user->id, 'wp_capabilities', true );…
Copy this this on your choosed templates. Locate a file code : locate_template( array( 'function-custom.php' ), true ); Require a file code : require_once( 'functions-custom.php' ); Include a file code : include( 'functions-custom.php' ); Get template functions-woocommerce.php Ex: get_template_part( ‘partials/content’, ‘page’ ); get_template_part( 'functions-woocommerce' );
If this is happening on your end, try this troubleshooting. Check if your Gravity Form short code if is placed outside the wp_footer();. I guess the short code does not support any function outside the wp_footer();. You should put your Gravity Form short code before wp_footer();. Much better if it is placed on inside the…
Copy this code and paste to your functions.php function wpa54064_inspect_scripts() { global $wp_scripts; print_r($wp_scripts); // this will show all enqueue’s script } add_action( ‘wp_head’, ‘wpa54064_inspect_scripts’ );