• Resolved malaiac

    (@malaiac)


    Hi,

    I’ve just started using WP Adverts, and I like the admin and the strict adherence to CPT usages.

    I currently am working for a client that has two different types of adverts on his website :
    one is for B2B adverts (partnerships / raw materials / etc.)
    one is for C2C adverts (craiglist style)

    I see three possibles ways of doing that :
    1/ “duplicate” WPAdverts on another CPT like “pro_advert”, to have a distinct admin management. Probably would be the best client wise, but requires a lot of rewriting
    2/ add a post_meta (like “advert_type”) to filter (“advert_type=pro” vs “advert_type=consumer”) both on admin and front end sides
    2/ use 2 main parent categories (pro/consumer), which would be ok front side with a few modifications (like adding a parent value in shortcode_adverts_categories / get_terms ), and could be ok admin side.

    What’s your opinion ?

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

    (@gwin)

    Hi,
    #1 is something i will be doing in the future, but i haven’t looked at it exactly most likely like you wrote it will require quite a lot of rewriting.

    For now, the best solution would be to use Custom Fields add-on and create two different form schemes. In the Custom Forms in the frontend you can preselect a category so when posting to a form [adverts_add form_scheme=”pro-ads”] the user will be forced to select “Pro” category and likewise with [adverts_add form_scheme=”normal-ads”].

    In the wp-admin panel you will have both ads types in wp-admin / Classifieds panel but you could easily filter them by category.

    Hope this helps.

    Thread Starter malaiac

    (@malaiac)

    Thanks for your quick answer !
    So, solution 2. I will add a submenu for “pro ads”.

    Still need to solve the front end display of pro/non pro adverts categories.
    What do you think about adding
    ‘parent’ => false,
    AND
    ‘parent’ => $parent,
    to includes/shortcodes.php/shortcode_adverts_categories($atts)
    ? I hate to hack plugins files :p

    Thread Starter malaiac

    (@malaiac)

    Don’t bother, I will add my own shortcodes ! ??

    • This reply was modified 7 years, 8 months ago by malaiac.
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Consumer adverts / Pro adverts’ is closed to new replies.