Search Issue
22 posts by 3 authors in: Forums > CMS Builder
Last Post: June 9, 2010 (RSS)
By thenetgirl - June 4, 2010
everything seems to be working on the search about midway down the page except for the years they return everything not jsut the year selected. HELP PLEASE
<form method="POST" action="granteesList.php">
<div align="center">
<table border="0" width="98%" id="table5">
<tr>
<td width="118"><font face="Arial"> <div class="normal"><b>Select Year:
</b> </div></td>
<td>
<select name="g_year" size="1" style="font-family: Arial; font-size: 12pt; width: 200px;">
<option value="" ></option>
<option value="2001" >2001</option>
<option value="2002" >2002</option>
<option value="2003" >2003</option>
<option value="2004" >2004</option>
<option value="2005" >2005</option>
<option value="2006" >2006</option>
<option value="2007" >2007</option>
<option value="2008" >2008</option>
<option value="2009" >2009</option>
</select></td>
</tr>
<tr>
<td width="118"><font face="Arial">
<div class="normal"><b>Select Name:</b></div></td>
<td><font face="Arial">
<select name="g_name" style="font-family: Arial; font-size: 9pt; width: 200px;" size="1">
<option value="" ></option>
<?php foreach ($granteesRecords as $record): ?>
<option value="<?php echo $record['g_name'] ?>"><?php echo $record['g_name'] ?></option>
<?php endforeach ?>
</select></td>
</tr>
<tr>
<td width="118"><b>Search For:</b></td>
<td><input type="text" name="g_mission_keyword" value="" style="font-family: Arial; font-size: 9pt; width: 200px;" size="1"></td>
</tr>
</table>
</div>
<p>
<input type="image" src="buttons/searchbutton.gif" border="0" name="I2">
</p>
</form>
THANKS
www.thenetgirl.com
Re: [thenetgirl] Search Issue
By Jason - June 4, 2010
Is your field "g_year" being stored in the database as a textfield, or as a date?
Let me know and we'll see what we can do.
Thanks.
Jason Sauchuk - Project Manager
interactivetools.com
Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/
Re: [thenetgirl] Search Issue
By Chris - June 4, 2010
Could you please post the full PHP source code for your granteesList.php page? I'm certain we can get this sorted out in short order.
Chris
Re: [chris] Search Issue
By thenetgirl - June 4, 2010
it fills it out but again returns everything.
here are both files.
www.thenetgirl.com
Re: [thenetgirl] Search Issue
By Chris - June 5, 2010
Can you try renaming your g_year field to, say, g_year_awarded or something that wouldn't match the pattern *_year?
Please let me know if that helps. If not, please fill out a Second Level Support Request and we'll get this figured out for you.
Chris
Re: [chris] Search Issue
By thenetgirl - June 6, 2010
but not my next problem with the trust search
<select name="trust_name" style="font-family: Arial; font-size: 9pt; width: 200px;" size="1">
<option value="" ></option>
<?php foreach ($trustsRecords as $record): ?>
<option value="<?php echo $record['trust_id'] ?>"><?php echo $record['trust_name'] ?></option>
<?php endforeach ?>
</select>
again their are 2 databases one is a list of trusts(15) and the other is the grantees(640) the one common item is the trust_id so I am thinking some type of
if trust_id on thetrusts <?php foreach ($trustsRecords as $record): ?>
= trust_id on grantess ($granteesRecords, as $record) out put this list ????
and some will have no Results and I want it to say that too.
thanks
www.thenetgirl.com
Re: [chris] Search Issue
By thenetgirl - June 7, 2010
Thanks
PG
www.thenetgirl.com
Re: [thenetgirl] Search Issue
By Jason - June 7, 2010
Since there doesn't seem to be a field called "trust_name" in the grantees table, try renaming the select field to "trust_id".
Hope this helps.
Jason Sauchuk - Project Manager
interactivetools.com
Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/
Re: [Jason] Search Issue
By thenetgirl - June 7, 2010
www.thenetgirl.com