Title: #tab-description getting loaded automatically
Last modified: December 10, 2020

---

# #tab-description getting loaded automatically

 *  [yydevelopment](https://wordpress.org/support/users/yydevelopment/)
 * (@yydevelopment)
 * [5 years, 6 months ago](https://wordpress.org/support/topic/tab-description-getting-loaded-automatically/)
 * Hey there,
    I am using a jquery simple script to create smooth scroling on my
   theme. This is the code i am using in there:
 *     ```
       jQuery(document).ready(function($){
   
       	$("a").on('click', function(event) {
   
       			event.preventDefault(); // Prevent default anchor click behavior
       			var hash = this.hash; // Store hash
   
       			$('html, body').animate({scrollTop: $(hash).offset().top}, 800, function(){
       				window.location.hash = hash;
       			});
   
       	}); 
   
       }); // jQuery(document).ready(function($){
       ```
   
 * Now as you can see in there the function should run on a button click.
    And it
   also changes the window URL location.
 * For some reason whenever I go into a product page it load #tab-description from
   that function. It seems like even due i haven’t clicked on any button something
   in WooCommerce activate that function, change the url and take me to the description
   part.
 * So if i go into this page
    [http://www.site.com/product/](http://www.site.com/product/)
 * After few sec it load this page:
    [http://www.site.com/product//#tab-description](http://www.site.com/product//#tab-description)
 * Any change you know what causing it?
 * Doesn’t seems like it related to any plugin as I disabled them all.
    It’s also
   not coming from the theme as is have tried using that code on different theme
   as well.
 * Thanks
    -  This topic was modified 5 years, 6 months ago by [yydevelopment](https://wordpress.org/support/users/yydevelopment/).

The topic ‘#tab-description getting loaded automatically’ is closed to new replies.

 * ![](https://ps.w.org/woocommerce/assets/icon.svg?rev=3234504)
 * [WooCommerce](https://wordpress.org/plugins/woocommerce/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woocommerce/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woocommerce/)
 * [Active Topics](https://wordpress.org/support/plugin/woocommerce/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woocommerce/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woocommerce/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [yydevelopment](https://wordpress.org/support/users/yydevelopment/)
 * Last activity: [5 years, 6 months ago](https://wordpress.org/support/topic/tab-description-getting-loaded-automatically/)
 * Status: not resolved