• Resolved georginakb

    (@georginakb)


    Hi!

    How do I edit the terms in the adverts-add form?

    For example, I want to change the name ‘Title’ to ‘Advert Title’?

    Thanks!
    Georgina

    The page I need help with: [log in to see the link]

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

    (@gwin)

    Hi,
    the fields in the [adverts_add] form you can edit by using Custom Fields extension https://wpadverts.com/extensions/custom-fields/ or if you are familiar with PHP programming using the adverts_form_load filter https://github.com/simpliko/wpadverts-snippets/blob/master/customize-adverts-add/customize-adverts-add.php

    For example, to change the label in “Title” field you can add 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_title" ) {
            $form["field"][$key]["label"] = "Advert Title";
        }
      }
      return $form;
    }
    

    Hi Greg Winiarski Great Answer, It helped a lot.

    I had one additional question that is :

    what if i want show login form link (i am using pop anything with custom login form) (which will be short code for pop anything) to user who want to post ad, if they are not logged in and then show them the form after successful login.

    Please do Reply.

    Thanking You.

    Plugin Author Greg Winiarski

    (@gwin)

    Hi,
    i understand that to trigger popup you will use this plugin https://www.ads-software.com/plugins/popup-anything-on-click/?

    If so then it would be best to ask the popup plugin support if you can assign a popup to button identified as label[for='_adverts_account_1'] a and how to do that.

    If the button needs to have an ID, then you would need to use a plugin like Say What? https://www.ads-software.com/plugins/say-what/ and customize the phrase “Create an account for me so I can manage all my ads from one place (password will be emailed to you) or Sign In” in a way the that the <a> tag will have the specific ID.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Form edits’ is closed to new replies.