+ Reply to Thread
Results 1 to 7 of 7

Thread: No contact form for certain listing type

  1. #1
    Guru
    Join Date
    Jul 2019
    Location
    Australia
    Posts
    657

    No contact form for certain listing type

    Hello,
    How can i disable contact form on listing page only for certain listing type?

    Thanks

  2. #2
    Flynax developer Rudi's Avatar
    Join Date
    Dec 2014
    Location
    Planet Earth
    Posts
    3,138
    Hello,

    go to templates > tpl > blocks > listing_details_sidebar.tpl

    replace:
    Code:
    Only registered members can view the code.
    with:
    Code:
    Only registered members can view the code.
    Last edited by Rudi; July 8, 2021 at 10:07 AM. Reason: Corrected

  3. #3
    Guru
    Join Date
    Jul 2019
    Location
    Australia
    Posts
    657
    Quote Originally Posted by Rudi View Post
    Hello,

    go to templates > tpl > blocks > listing_details_sidebar.tpl

    replace:
    Code:
    Only registered members can view the code.
    with:
    Code:
    Only registered members can view the code.
    this logic is not working correctly, it disables contact form for all listing types.

    I even tried to replace '&&" with "||".

    Im not a professional programmer but still trying to figure this out.


    {If $.I_struggle_with_php
    ||'why not' && $.Keep_on_trying}

    thank you

  4. #4
    Guru
    Join Date
    Jul 2019
    Location
    Australia
    Posts
    657
    Quote Originally Posted by Rudi View Post
    Hello,

    go to templates > tpl > blocks > listing_details_sidebar.tpl

    replace:
    Code:
    Only registered members can view the code.
    with:
    Code:
    Only registered members can view the code.
    hello rudi ,

    can you please advise here?

    This code disables contact box for all listing types.

  5. #5
    Flynax developer Rudi's Avatar
    Join Date
    Dec 2014
    Location
    Planet Earth
    Posts
    3,138
    Hello,

    Instead of YOUR_KEY you should insert the key of listing type for which the contact form should be hidden,

    you check it from Listing Types > your listing type > Edit > Key

  6. #6
    Guru
    Join Date
    Jul 2019
    Location
    Australia
    Posts
    657
    i did that rudi, thought i made a typo but i checked it.

  7. #7
    Flynax developer Rudi's Avatar
    Join Date
    Dec 2014
    Location
    Planet Earth
    Posts
    3,138
    Sorry, I made a mistake in my code instead of == use !=

+ Reply to Thread