Title: Problem with inserted code, what wasn&#8217;t before
Last modified: March 22, 2021

---

# Problem with inserted code, what wasn’t before

 *  [Tama](https://wordpress.org/support/users/tomiqa/)
 * (@tomiqa)
 * [5 years, 2 months ago](https://wordpress.org/support/topic/problem-with-inserted-code-what-wasnt-before/)
 * I’m having problem with inserted code, that wasn’t causing an error before
 * This is the code:
 *     ```
       // Edit WooCommerce dropdown menu item of shop page//
       // Options: menu_order, popularity, rating, date, price, price-desc
   
       function my_woocommerce_catalog_orderby( $orderby ) {
           unset($orderby["price"]);
           unset($orderby["price-desc"]);
           return $orderby;
       }
       add_filter( "woocommerce_catalog_orderby", "my_woocommerce_catalog_orderby", 20 );
       ```
   
 * It should remove sort by price from Woocommerce listing options.
 * When I hover over the dropdown menu, at the top right on my site, it glitches.
 * See it here: [https://pixxsa.com/](https://pixxsa.com/)

The topic ‘Problem with inserted code, what wasn’t before’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/my-custom-functions_0e1030.svg)
 * [My Custom Functions](https://wordpress.org/plugins/my-custom-functions/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/my-custom-functions/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/my-custom-functions/)
 * [Active Topics](https://wordpress.org/support/plugin/my-custom-functions/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/my-custom-functions/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/my-custom-functions/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [Tama](https://wordpress.org/support/users/tomiqa/)
 * Last activity: [5 years, 2 months ago](https://wordpress.org/support/topic/problem-with-inserted-code-what-wasnt-before/)
 * Status: not a support question