Search on Turbosale template

Discussion in 'Auto Classifieds Script' started by oglasi, Nov 16, 2016.

  1. oglasi

    oglasi New Member

    Hello,

    I have a question regarding the search. I am currently using turbosale template.
    I want to add country and city to search. So i need to know is that possible?
    The field for search (for country and city) would be placed as shown in attached file (name Image 1).
    Also I would also like to change the order of search fields.

    Thanks in advance :)

    Attached Files:

  2. Dayir_A.

    Dayir_A. Staff Member

    Hello @oglasi,

    First of all, you should add those fields for autos item and make them searchable.
    Then you should add custom search filters in that block.
    Search block is rendered in file:
    /templates/turbosale/packages/autos/block.quicksearch.tpl

    I'll show raw example:
    in that file you'll find a <form>
    in this form add
    Code (HTML5):

    <input type="text" name="city">
     
    (in this case it will search by "city" field)
    After that search will be working. As I said this is a raw example, HTML + CSS styling should be done, so it will look more nicely.

    However it will work only for text fields, if you want a dropdown or other type of field, then this field should be transformed before search. Examples for this can be found in
    /packages/autos/includes/classes/ia.front.auto.php file coreSearchTranslateColumn() method
    i.e. you should have some knowledge in PHP

    If you are interested in this modification, it can be implemented as a custom modification for you.
    You can create a ticket in our HelpDesk -> Custom modifications department and we'll quote this request for you.

    Thanks.
    oglasi and Andrew_G. like this.

Share This Page