• Resolved webwerkplaats

    (@webwerkplaats)


    In my case it’s always me (admin) who places ads.
    It’s always the same contact,email and phone.
    How can i permanently set: Contact person, email and phonenumber ?

    Thanks in advance !

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Greg Winiarski

    (@gwin)

    Hi, where do you create the ads from? wp-admin or the frontend? In the frontend the contact details should be filled by default, from wp-admin it will require some custom programming.

    You can add the code below in your theme functions.php file to prefill the values.

    
    add_filter( "adverts_form_bind", "adverts_add_default_values", 1000 );
    function adverts_add_default_values( $form ) {
        if( $form->get_scheme( "name" ) != "advert" || get_current_user_id() < 1 ) {
            return $form;
        }
        $form->set_value( "adverts_person", "Me." );
        $form->set_value( "adverts_email", "[email protected]" );
        $form->set_value( "adverts_phone", "1100-0000-0000" );
        return $form;
    }
    
    Thread Starter webwerkplaats

    (@webwerkplaats)

    Again it was excellent support. Works like a charm. Now my friend can walk around his showroom and there is so little to fill in that he can do it with his phone. Picture, 3 fields to type and ready!
    Brilliant !! Thanks!

    Plugin Author Greg Winiarski

    (@gwin)

    Ok great, i am glad you have it exactly the way you want it ??

    BTW. If you are finding the plugin useful i would be thankful if you could write a short one or two sentence review here https://www.ads-software.com/support/view/plugin-reviews/wpadverts

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Only 1 person who places ads’ is closed to new replies.