Title: Remove comma from Numeric Variable
Last modified: August 30, 2016

---

# Remove comma from Numeric Variable

 *  [InventiveWebDesign](https://wordpress.org/support/users/inventivewebdesign/)
 * (@inventivewebdesign)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/remove-comma-from-numeric-variable/)
 * We are using the Year variable as numberic so it can be searched. The problem
   is that it shows up with a comma (2,000 instead of 2000). If I remove the numeric
   classification it isn’t searchable correctly. How can I get rid of the comma?
 * [http://www.yourwhiteknight.com/properties/](http://www.yourwhiteknight.com/properties/)
 * [https://wordpress.org/plugins/wp-property/](https://wordpress.org/plugins/wp-property/)

Viewing 6 replies - 1 through 6 (of 6 total)

 *  Plugin Contributor [MariaKravchenko](https://wordpress.org/support/users/mariakravchenko/)
 * (@mariakravchenko)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/remove-comma-from-numeric-variable/#post-6553683)
 * Hello.
 * That you for pointing us to this issue. We will try to improve this as soon as
   possible.
 * Regards.
 *  Thread Starter [InventiveWebDesign](https://wordpress.org/support/users/inventivewebdesign/)
 * (@inventivewebdesign)
 * [10 years, 7 months ago](https://wordpress.org/support/topic/remove-comma-from-numeric-variable/#post-6553832)
 * The problem is that my client’s website currently looks terrible because there
   are commas in the years. Could you please talk to your developers and supply 
   a solution ASAP? Previous programmers have customized your plugin and I can’t
   do updates because it destroys everything that has been done. I just need the
   ability to remove the comma from the years.
 *  Thread Starter [InventiveWebDesign](https://wordpress.org/support/users/inventivewebdesign/)
 * (@inventivewebdesign)
 * [10 years, 7 months ago](https://wordpress.org/support/topic/remove-comma-from-numeric-variable/#post-6553833)
 * There should be a way to have it strip the comma from the code in the files that
   you have in the software I just need to know how and where.
 * Something like this: number_format($year, 0, ‘.’, ”);
 * I just need to know how to change the php code for the year variable with this.
 *  Plugin Contributor [Maxim Peshkov](https://wordpress.org/support/users/maximpeshkov/)
 * (@maximpeshkov)
 * [10 years, 7 months ago](https://wordpress.org/support/topic/remove-comma-from-numeric-variable/#post-6553838)
 * Hello,
 * you could add the following code to your functions.php in theme’s root directory:
 *     ```
       function ignore_format_of_year_built() {
         if( has_action( 'wpp_stat_filter_year_built', array( 'WPP_F', 'format_numeric' ) ) ) {
           remove_action( 'wpp_stat_filter_year_built', array( 'WPP_F', 'format_numeric' ) );
         }
       }
       add_action( 'template_redirect', 'ignore_format_of_year_built' );
       ```
   
 * Just replace filter `wpp_stat_filter_year_built` above if needed. `year_built`
   is slug of your year attribute. So, e.g., if slug is `year`, filter should be
   called `wpp_stat_filter_year`.
 * Regards.
 *  Thread Starter [InventiveWebDesign](https://wordpress.org/support/users/inventivewebdesign/)
 * (@inventivewebdesign)
 * [10 years, 7 months ago](https://wordpress.org/support/topic/remove-comma-from-numeric-variable/#post-6553848)
 * Looks like that worked, thanks!
 *  Plugin Contributor [Maxim Peshkov](https://wordpress.org/support/users/maximpeshkov/)
 * (@maximpeshkov)
 * [10 years, 7 months ago](https://wordpress.org/support/topic/remove-comma-from-numeric-variable/#post-6553849)
 * Please, mark the ticket as resolved.
 * Thank you.

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘Remove comma from Numeric Variable’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wp-property_c36510.svg)
 * [WP-Property - WordPress Powered Real Estate and Property Management](https://wordpress.org/plugins/wp-property/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-property/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-property/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-property/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-property/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-property/reviews/)

 * 6 replies
 * 3 participants
 * Last reply from: [Maxim Peshkov](https://wordpress.org/support/users/maximpeshkov/)
 * Last activity: [10 years, 7 months ago](https://wordpress.org/support/topic/remove-comma-from-numeric-variable/#post-6553849)
 * Status: not resolved