I suppose the problem with using Dreamweaver to write php/mysql for me is that I don't get to know what's going on!
With the help of DW I have managed to display on a webpage various pieces of text from a mysql table. However it is only displaying text from the first record!
I would like to know how I can simply instruct it to look at other records by specifying the number of the Primary Key. The relevant code is, I think:
<?php require_once('../../../Connections/tormented3.php'); ?>
<?php
mysql_select_db($database_tormented3, $tormented3);
$query_rstcool = "SELECT * FROM cell_cont";
$rstcool = mysql_query($query_rstcool, $tormented3) or die(mysql_error());
$row_rstcool = mysql_fetch_assoc($rstcool);
$totalRows_rstcool = mysql_num_rows($rstcool);
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" etc etc
and later;
<?php echo $row_rstcool['cel_org']; ?></span> <!-- Insert Title of Organisation -->
<?php if ($row_rstcool['cel_tel']) echo 'tel. ' ; echo $row_rstcool['cel_tel']; ?><br> <!-- Check for, and Insert Tel Number -->
What piece of code can I insert just before this second piece of code to determine which data record is read, please? This does not need to be a variable value as the data will change whilst the Primary Key will remain the same.
I hope I make sense. Thanks for your help.
With the help of DW I have managed to display on a webpage various pieces of text from a mysql table. However it is only displaying text from the first record!
I would like to know how I can simply instruct it to look at other records by specifying the number of the Primary Key. The relevant code is, I think:
<?php require_once('../../../Connections/tormented3.php'); ?>
<?php
mysql_select_db($database_tormented3, $tormented3);
$query_rstcool = "SELECT * FROM cell_cont";
$rstcool = mysql_query($query_rstcool, $tormented3) or die(mysql_error());
$row_rstcool = mysql_fetch_assoc($rstcool);
$totalRows_rstcool = mysql_num_rows($rstcool);
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" etc etc
and later;
<?php echo $row_rstcool['cel_org']; ?></span> <!-- Insert Title of Organisation -->
<?php if ($row_rstcool['cel_tel']) echo 'tel. ' ; echo $row_rstcool['cel_tel']; ?><br> <!-- Check for, and Insert Tel Number -->
What piece of code can I insert just before this second piece of code to determine which data record is read, please? This does not need to be a variable value as the data will change whilst the Primary Key will remain the same.
I hope I make sense. Thanks for your help.