Title: Stop/Remove VigLink links!
Last modified: September 6, 2019

---

# Stop/Remove VigLink links!

 *  Resolved [lazyym](https://wordpress.org/support/users/lazyym/)
 * (@lazyym)
 * [6 years, 8 months ago](https://wordpress.org/support/topic/stop-remove-viglink-links/)
 * Hi Greg,
 * Users at my site occasionally copy and paste the content of their ads from another
   classified site. They inadvertently paste links and code from their ads at the
   other site.
 * Viglink specifically. Viglink is an affiliate program used at a lot of sites 
   to auto encode keywords. viglink.com is the system.
 * It also allows them to paste html formatting including li’s and ul’s, etc. I 
   have my editor set to plain text and they still post for some reason with the
   formatting and links.
 * People are able to simply copy and paste their ad content and formatting with
   affiliate links from the other site into ads on my site and their site gets credit
   when people click them!
 * I have had to manually remove formatting and links from ads so far.
 * How do we stop this?

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

 *  Plugin Author [Greg Winiarski](https://wordpress.org/support/users/gwin/)
 * (@gwin)
 * [6 years, 8 months ago](https://wordpress.org/support/topic/stop-remove-viglink-links/#post-11912810)
 * Hi,
    do you want to completely remove the HTML code from the description field
   in [adverts_add]?
 * If so then you can do that by adding the code below in your theme functions.php
   file
 *     ```
       add_filter( "adverts_form_load", function( $form ) {
         if( $form["name"] != "advert" ) {
           return $form;
         }
         foreach( $form["field"] as $k => $field ) {
           if( $field["name"] == "post_content" ) {
             $form["field"][$k]["filter"] = array( array( "name" => "strip_tags" ) );
           }
         }
         return $form;
       } );
       add_action( "init", function( ) {
         adverts_form_add_filter( "strip_tags", array( 
           "description" => "strip_tags", 
           "callback" => "strip_tags" 
         ) );
       } );
       ```
   
 *  Thread Starter [lazyym](https://wordpress.org/support/users/lazyym/)
 * (@lazyym)
 * [6 years, 8 months ago](https://wordpress.org/support/topic/stop-remove-viglink-links/#post-11913974)
 * I’ll try that, thanks!

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

The topic ‘Stop/Remove VigLink links!’ is closed to new replies.

 * ![](https://ps.w.org/wpadverts/assets/icon-256x256.png?rev=2423472)
 * [WPAdverts - Classifieds Plugin](https://wordpress.org/plugins/wpadverts/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wpadverts/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wpadverts/)
 * [Active Topics](https://wordpress.org/support/plugin/wpadverts/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wpadverts/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wpadverts/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [lazyym](https://wordpress.org/support/users/lazyym/)
 * Last activity: [6 years, 8 months ago](https://wordpress.org/support/topic/stop-remove-viglink-links/#post-11913974)
 * Status: resolved