![]()  | 
	
	
		
 Searching Extra Fields 
		
		
		
		Now I need to add to the Advanced search page - I will have a drop down box with a list of values that may be found in ANY of the extra fields. So, I want to add the value selected to the advanced search. 
	The problem is that I think the values assigned in the <Select> drop down list need to be passed through smarty (?) somehow and then I would add this to the query: Code: 
	        $search_ef_condition = " AND ($sql_tbl[products].param01 like '%$ef_search%' or $sql_tbl[products].param02 like '%$ef_search%' or $sql_tbl[products].param03 like '%$ef_search%' or $sql_tbl[products].param04 like '%$ef_search%' or $sql_tbl[products].param05 like '%$ef_search%' or $sql_tbl[products].param06 like '%$ef_search%' or $sql_tbl[products].param07 like '%$ef_search%' or $sql_tbl[products].param08 like '%$ef_search%') "(Note: I am skipping param00 and param09 intentionally) $ef_search would be the value of what was selected in the drop-down, but HOW do I get it to pick up the value from the <select> box?? The drop down looks something like this: Code: 
	        <select class="combobox" name="ef_search" size="1">And I modified the $search_query to include the $search_ef_condition: Code: 
	        $search_query = "($sql_tbl[products].product like '%$substring%' or $sql_tbl[products].descr like '%$substring%') and $sql_tbl[categories].category like '$search_category%' and $sql_tbl[products].forsale='Y' and $sql_tbl[categories].avail='Y' $search_ef_condition $price_condition ";It's looking like I'm in over my head, but I feel I am close. Any ideas? Am I going about this the wrong way? You see what I am wanting to add to the query - Search all of the param0x fields for a value that was selected from the drop down added to the advanced search page. Help? :cry:  | 
	
		
 Print the complete query string and give it a whirl in phpMyAdmin to see if you've got any syntax errors or if you need to restructure the query. 
	hth. ;)  | 
	
		
 To do that, I would have to translate the variables first and this is exactly the problem - the $ef_search is not getting set by the drop down value. I believe it has to go through smarty because the other variables in the advanced search page have this: value="{$smarty.get.substring}" 
	I don't know enough to be able to pass the value selected in the drop down, through smarty (if that's what I need) and then to the search.php script, so the $ef_search variable contains the value selected in the drop down.  | 
	
		
 Any progress? 
		
		
		
		Any progress?   
	It would be realy nice if the search could search feilds that are in the extra feilds. Thanks, John7  | 
| All times are GMT -8. The time now is 04:13 AM. | 
	Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.