curt22
-
Posts
55 -
Joined
-
Last visited
Never
Posts posted by curt22
-
-
<?php
include 'connect.php';
$sql = 'SELECT * FROM bible WHERE MATCH($_post[\'field\'])
. ' AGAINST('$_post[\'find\']' IN BOOLEAN MODE) LIMIT 0, 30 ';
$result = mysql_query($sql) or die(mysql_error());
while($row = mysql_fetch_array($result)){
echo $row['testimate'] . " " . $row['book'] . " " . $row['chapter'] . " " . $row['verse'] . " " . $row['verse text'];
echo "<br/>";
}
?> -
Ok this is as much as i can get could you please tell me what to do with it?
<?php
include 'connect.php';
$query = "SELECT * FROM bible ORDER BY bookid";
$result = mysql_query($query) or die(mysql_error());
while($row = mysql_fetch_array($result)){
echo $row['testimate'] . " " . $row['book'] . " " . $row['chapter'] . " " . $row['verse'] . " " . $row['verse text'];
echo "<br/>";
}
?>
-
Ok i will make a bookid. And i know how to order things but how do i order them the second time. I could get them to order by book but how i get them to order by chapter inside the book then the verse. ???
-
I'm new to php and mysql and I need to have the results sorted.
First its needs to sort by book.
then by chapters inside the books.
Then by verse.
For example:
if its like this now:
id testimate book chapter verse
1 old genesis 1 1
2 old Exodus 2 1
3 old genesis 2 2
it would look like this after being sorted:
1 old genesis 1 2
3 old genesis 2 2
2 old Exodus 2 1
the code im using to show the databse is:
<?php
include 'connect.php';
$sql = 'SELECT * FROM bible WHERE MATCH($_post[\'field\'])'
. ' AGAINST(\'$_post[\'find\']\' IN BOOLEAN MODE) LIMIT 0, 30 ';
$result = mysql_query($sql) or die(mysql_error());
while($row = mysql_fetch_array($result)){
echo $row['testimate'] . " " . $row['book'] . " " . $row['chapter'] . " " . $row['verse'];
echo "<br/>";
}
?>
??? ??? ??? ??? ???
[SOLVED] Whats wrong with this code?
in MySQL Help
Posted