Results 1 to 4 of 4

Specify Search Criteria with dropdown box(not by Attributes)

This is a discussion on Specify Search Criteria with dropdown box(not by Attributes) within the osCommerce 2.2 Modification Help forums, part of the osCommerce 2.2 Forums category; Hello All Is it possible to have drop down boxes in the advance search page for certain criteria of keywords ...

      
  1. #1
    zel
    zel is offline
    New Member
    Join Date
    Feb 2005
    Posts
    7
    Rep Power
    0


    Default Specify Search Criteria with dropdown box(not by Attributes)

    Hello All

    Is it possible to have drop down boxes in the advance search page for certain criteria of keywords etc

    EG Year - 2000, 2001, 2004
    Person - Fred, George
    Make - Epson, Cannon


    I have tried the contribution "Advanced Search Atrributes" but this shows all attributes. A Bit confusing I think.

    The idea behind this is that all products will have certain keywords to help people search for the right product eg year and then a person perhaps (as above). This will then bring up all products with the same year and person as per the words in their product description.

    I hope this makes sense. At the present time the search keywords do not seem to sort the years even though they are different in the product description.

    I am using Osc Max V1.7 and I am using easy populate to update my cart.

    Thanking you in advance.

    Regards
    Zel

  2. #2
    Active Member developer_x's Avatar
    Join Date
    Nov 2004
    Location
    Digital Infoway
    Posts
    109
    Rep Power
    0


    Default

    I am using oscommerce 2ms2.2. But I think I can help you a bit. I had to enable the client to search tablets with respect to their strength. I made a new table. Inserted the values of strength in it. Then I used this function in search.php and advanced_search.php

    function tep_draw_pull_down_menu($name, $values, $default = '', $parameters = '', $required = false)


    at the right place and in the right way to extract the fields of the strenght from the database into the drop down menu. Then I was able to perform search on it.

    Example at: www.paylessdrugstores.com

    Most of the contributions made for oscommerce work for oscmax 1.7 too. So give my procedure a try.
    Best of luck.

  3. #3
    zel
    zel is offline
    New Member
    Join Date
    Feb 2005
    Posts
    7
    Rep Power
    0


    Default

    Thank you for your help, may I impose a little more.....

    My knowledge of Mysql is limited but learning fast, could you give me an example of what the new table to insert into mysql looked like.

    Also, apologies for the 50 questions, the function in the search.php etc if you have three categories eg name, person, year would you put this in separately for each category (so to speak)

    Thank you for you help

    Regards
    Zel

  4. #4
    Active Member developer_x's Avatar
    Join Date
    Nov 2004
    Location
    Digital Infoway
    Posts
    109
    Rep Power
    0


    Default

    Quote Originally Posted by zel
    Thank you for your help, may I impose a little more.....

    My knowledge of Mysql is limited but learning fast, could you give me an example of what the new table to insert into mysql looked like.
    This is the query I used to make a table for strengths.

    CREATE TABLE strengths (
    strengths_id int(5) NOT NULL auto_increment,
    strengths_value decimal(10,2) default NULL,
    PRIMARY KEY (strengths_id)
    ) TYPE=MyISAM;
    If you install phpmyAdmin, manipulating the database becomes very easy.
    The new table needs to be defined in the includes/database_tables.php of catalog and/or (depends upon your requirements) admin folder.

    define('TABLE_STRENGTHS','strengths');
    Quote Originally Posted by zel
    Also, apologies for the 50 questions, the function in the search.php etc if you have three categories eg name, person, year would you put this in separately for each category (so to speak)
    I am not getting you much. Any how you can create multiple dropdown menus with the same function. That's why we use functions.

    Feel free to come there. And do read the oscDox guide for customizing your store.

Similar Threads

  1. product attributes - "option type" dropdown missin
    By test_fsait in forum osCMax v2 Features Discussion
    Replies: 12
    Last Post: 02-13-2007, 06:05 PM
  2. Catagorie dropdown has disappeared?
    By delphi1 in forum osCommerce 2.2 Discussion
    Replies: 2
    Last Post: 01-18-2006, 04:28 AM
  3. Full text search in advanced search
    By Anonymous in forum osCmax v1.7 Discussion
    Replies: 0
    Last Post: 04-15-2004, 03:00 PM
  4. Search by Attributes
    By raveoverseas in forum osCommerce 2.2 Modification Help
    Replies: 0
    Last Post: 07-31-2003, 09:56 AM
  5. How toCreate Dropdown menu
    By Anonymous in forum osCommerce 2.2 Modification Help
    Replies: 0
    Last Post: 10-24-2002, 09:28 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •