|
|
#1 |
|
Use of undefined constant foundnum line 54
hi, can someone help me with this error pls. the error is Use of undefined constant in line 54. what is it thats not defined pls
<?php include ('connect.php'); error_reporting(E_ALL); ini_set('display_errors', '1'); $submit = $_GET['submit']; $search = $_GET['search']; $x=0; $construct=''; $foundnum=""; if (!'submit') echo "you didnt submit a keyword."; else { if (strlen($search)<=2) echo "search term to short."; else { echo " You searched for <b>$search</b><hr size='1'>"; //connect to our database $search_exploded = explode(" ",$search); foreach($search_exploded as $search_each) { // construct query $x++; if ($x==1) $construct .= " location LIKE '%$search_each%'"; else $construct .= " OR rent LIKE '%$search_each%'"; } // echo out construct $construct = "SELECT * FROM flats WHERE $construct"; $run = mysql_query($construct); $foundnum = mysql_num_rows($run); if (foundnum==0) echo "No results found."; else { echo "$foundnum result found!<p>"; while ($runrows = mysql_fetch_assoc($run)) { // get data $select = $runrows['type']; $title = $runrows['title']; $location = $runrows['location']; echo " echo $title; echo <br>; echo $select; echo <br>; echo $rent; echo <br>; echo $location"; } } } } ?> |
|
|
|
0
|
|
|
#2 |
|
Please use the PHP code block when posting code to improve readability.
The error concerns this line, PHP Code:
|
|
|
|
0
|
|
|
#3 |
|
Also...
PHP Code:
__________________
Jim Goldbloom Sr. Web Developer, owner GoldTechPro, LLC http://www.GoldTechPro.com
|
|
|
|
0
|
![]() |
|
«
Previous Thread
|
Next Thread
»
| Thread Tools | Search this Thread |
| Display Modes | |
|
|
Similar Threads
|
||||
| thread | Thread Starter | Forum | Replies | Last Post |
| After a week of constant use of GM, it actually works well. | iBug2 | Mac OS X 10.7 Lion | 9 | Jul 7, 2011 08:51 PM |
| Vertical lines covering half of my display | bobbytomorow | MacBook | 13 | Jan 2, 2011 09:35 PM |
| Macbook Air 13" 2010 thin white lines across bottom half of screen | ishopukisfake | MacBook Air | 6 | Dec 16, 2010 05:11 PM |
| Website problems (Use of undefined constant str_pad_left) | Brendon Bauer | Web Design and Development | 3 | Jul 27, 2008 01:26 PM |
| Notice: Use of undefined constant PHP ERROR HELP PLEASE | Cabbit | Web Design and Development | 5 | Jun 2, 2007 11:03 AM |
All times are GMT -5. The time now is 08:17 AM.







Jim Goldbloom
Linear Mode

