• Resolved masterclass

    (@masterclass)


    1.I would like to hide or make read-only (blocked) the following on front-page form
    a.Description
    b. Price
    c.Location

    2. I would like to limit the image/gallery uploads to just 1 on the front-page form

    3. I would like to remove theme author on details page. (I’m using Dynamix Theme from Themeforest)

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

    (@gwin)

    1. you can hide the fields using adverts_form_load filter or by using the Custom Fields extension https://wpadverts.com/extensions/custom-fields/

    The code below will hide the fields in the [adverts_add] you can add it 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( in_array( $field["name"], array( "adverts_price", "adverts_location", "post_content" ) ) ) {
            unset( $form["field"][$key] );
        }
      }
      return $form;
    }
    

    2. similarly as above you can limit the file uploads to just one file by using the Custom Fields extension or the Limit File Uploads snippet https://github.com/simpliko/wpadverts-snippets/blob/master/limit-file-uploads/limit-file-uploads.php

    3. this most likely can be hidden with a CSS snippet but you would need to paste a link to one of your Ad details pages as the CSS code which will do it varies from theme to theme.

    Thread Starter masterclass

    (@masterclass)

    Thank you that worked perfectly.

    3. Here is the link. https://startupbotswana.com/advert/sharing-connects-us
    If not possible, lets try to remove plugin author

    Plugin Author Greg Winiarski

    (@gwin)

    I understand you would like to remove the part “By Startup Botswana October 8, 2018”?

    If so then please go to wp-admin / Appearance / Customize / Additional CSS panel and add there the code below

    
    article.classified .post-metadata {
        display: none !important;
    }
    
    Thread Starter masterclass

    (@masterclass)

    Thanks that did it.

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

The topic ‘Customize front page form’ is closed to new replies.