• Resolved joey111

    (@joey111)


    I want the description is not mandatory. How can and where can I set this?

    • This topic was modified 7 years, 11 months ago by joey111.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Greg Winiarski

    (@gwin)

    Hi, you can do that by adding the code below in your theme functions.php file

    
    add_filter( "adverts_form_load", "customize_adverts_add" );
    function customize_adverts_add( $form ) {
      if( $form['name'] != "advert" ) {
        return $form;
      }
      foreach( $form["field"] as $key => $field ) {
        if( $field["name"] == "post_content" ) {
            $form["field"][$key]["validator"] = array();
        }
      }
      return $form;
    }
    
    Thread Starter joey111

    (@joey111)

    Worked. Thanks a lot!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Description not required’ is closed to new replies.