Datafeedr Support Forums  

Go Back   Datafeedr Support Forums > Current Version (V3) Forum > Questions
Home Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Important - The support forums are now in "read-only" mode as we transition to an alternative help desk solution. Feel free to contact us here with any of your questions or search the forums for an existing solution.
 
 
Thread Tools Search this Thread Display Modes
  #1  
Old March 24th, 2011, 08:07 PM
meperez meperez is offline
 
Join Date: Mar 2011
Posts: 43
Default Brand Filter Drop-Down with All Brands option

Hi,

I implemented the brand filter described in http://www.datafeedr.com/forums/show...dget+drop-down but would like to include an 'All Brands' option in that list as well. What value would I use for this option?

Thank you!
  #2  
Old March 24th, 2011, 08:09 PM
Eric's Avatar
Eric Eric is offline
Datafeedr Team
 
Join Date: Feb 2008
Posts: 16,902
Default

<a href="[server.url type='fullpage' query='-brand']">All Brands</a>
  #3  
Old March 24th, 2011, 08:41 PM
meperez meperez is offline
 
Join Date: Mar 2011
Posts: 43
Default

To clarify, I would just place the string you've provided in the list enclosed in the <div> tags?

<div>
<form method="get">
<span>
<?php echo datafeedr_tools()->form_select("brand",
array(
"Breville" => "Breville",
"Waring" => "Waring",
)); ?>
<input type="submit" value="Go" />
</span>
</form>
</div>
  #4  
Old March 24th, 2011, 09:42 PM
Eric's Avatar
Eric Eric is offline
Datafeedr Team
 
Join Date: Feb 2008
Posts: 16,902
Default

That could go either way. It more depends on the code that surrounds the <form> which depends on your theme.
  #5  
Old March 24th, 2011, 11:19 PM
meperez meperez is offline
 
Join Date: Mar 2011
Posts: 43
Default

I'm sorry, I've tried a few different "versions" of integrating the code (your reply to this thread question and the original code from the drop-down brand filter) and have also looked online for using some sort of php wildcard in the array but can't seem to figure it out. My site is www.thekitchentool.com and, for example, I'd like to display a brand filter that shows

All Brands
Breeville
Waring

Any further help would be appreciated!

Thanks!
  #6  
Old March 25th, 2011, 08:20 AM
Eric's Avatar
Eric Eric is offline
Datafeedr Team
 
Join Date: Feb 2008
Posts: 16,902
Default

I haven't tested this but it should work:

HTML Code:
<div>
	<form method="get">
		<span>
			<?php echo datafeedr_tools()->form_select("brand",
			array(
				"-brand" => "All Brands",
				"Breville" => "Breville",
				"Waring" => "Waring",
			)); ?>
			<input type="submit" value="Go" />
		</span>
	</form>
</div>
  #7  
Old March 25th, 2011, 08:53 PM
meperez meperez is offline
 
Join Date: Mar 2011
Posts: 43
Default

Thanks Eric, I tried this and the brand searches work fine but the 'All Brands' comes back with no products returned. Is there anything else I try?
  #8  
Old March 25th, 2011, 10:57 PM
Eric's Avatar
Eric Eric is offline
Datafeedr Team
 
Join Date: Feb 2008
Posts: 16,902
Default

Instead of putting -brand, just put nothing:

"" => "All Brands",
  #9  
Old March 26th, 2011, 12:04 AM
meperez meperez is offline
 
Join Date: Mar 2011
Posts: 43
Default

That did it! Awesome, thanks!
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Drop down Menu from filter by Brand macfink Questions 4 March 25th, 2011 09:32 AM
No drop down menu in new factory marcaustin Problems 15 March 10th, 2011 02:36 PM
Brand filter? sylviathewitch Problems 3 March 8th, 2011 08:43 AM
Weird Brands and Merchants Show in DF Widget Kaetemar Problems 1 February 9th, 2011 11:34 AM


All times are GMT -5. The time now is 05:24 AM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.