WOW... I'm even more confused now! This script continues to display NOTHING. I did, however, enclose lines 43-51 inside a while loop and had along w/ a counter. The counter only goes up to the # of results! So it is pulling the results, I'm just unable to print them out.
But what is just COMPLETELY giving me a headache is that I decided to skip this script for now and go on to another one. Here is the code for that one:
Code:
1 <?
2 $pg_title = "Home";
3
4 include_once "header.php";
5
6 $query = "SELECT date, name, country, phone, phonetype FROM lead_info";
7 $result = sqlite_query($query, $db) or die("Select Query Failed");
8 ?>
9
10 <table width="1000" align="center" border="1">
11
12 <?
13 while($row = sqlite_fetch_array($result))
14 {
15 print("<tr>");
16 print(" <td>" . $row["date"] . "</td>");
17 print(" <td>" . $row["name"] . "</td>");
18 print(" <td>" . $row["country"] . "</td>");
19 print(" <td>" . $row["phone"] . "</td>");
20 print(" <td>" . $row["phonetype"] . "</td>");
21 print("</tr>");
22 }
23 ?>
24
25 </table>
26
27 <?
28 include_once "footer.php";
29 ?>
THIS PAGE WORKS! IT DISPLAYS EVERYTHING! Does anyone see any difference in the query or the way that the retrieved vars are handled and printed?
EDIT: PS: Before posting this last reply, I went back to the original script and changed $row['foo'] to $row["foo"], but the problem continued.
Bookmarks