Hi all, as you know I am disabled and still very new to PHP.

I have a SQL database and would like to display the data in the "Web Link" column of the DB as hyperlinks. Can someone please assist me to accomplish this. I have checked on the internet first to see if I can't get it sorted by myself, but no joy.

Below is the code for my index.php page:

[CODE]

<?php require_once('connections/gauInfoConn.php'); ?>
<?php
if (!function_exists("GetSQLValueString")) {
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
{
if (PHP_VERSION < 6) {
$theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;
}

$theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);

switch ($theType) {
case "text":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "long":
case "int":
$theValue = ($theValue != "") ? intval($theValue) : "NULL";
break;
case "double":
$theValue = ($theValue != "") ? doubleval($theValue) : "NULL";
break;
case "date":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "defined":
$theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
break;
}
return $theValue;
}
}

$currentPage = $_SERVER["PHP_SELF"];

$maxRows_allInfo = 10;
$pageNum_allInfo = 0;
if (isset($_GET['pageNum_allInfo'])) {
$pageNum_allInfo = $_GET['pageNum_allInfo'];
}
$startRow_allInfo = $pageNum_allInfo * $maxRows_allInfo;

mysql_select_db($database_gauInfoConn, $gauInfoConn);
$query_allInfo = "SELECT shop_name, bus_route, stop_no, shop_cat, address, web_link, more_info FROM shops_on_routes ORDER BY bus_route ASC";
$query_limit_allInfo = sprintf("%s LIMIT %d, %d", $query_allInfo, $startRow_allInfo, $maxRows_allInfo);
$allInfo = mysql_query($query_limit_allInfo, $gauInfoConn) or die(mysql_error());
$row_allInfo = mysql_fetch_assoc($allInfo);

if (isset($_GET['totalRows_allInfo'])) {
$totalRows_allInfo = $_GET['totalRows_allInfo'];
} else {
$all_allInfo = mysql_query($query_allInfo);
$totalRows_allInfo = mysql_num_rows($all_allInfo);
}
$totalPages_allInfo = ceil($totalRows_allInfo/$maxRows_allInfo)-1;
$pageNum_allInfo = 0;
if (isset($_GET['pageNum_allInfo'])) {
$pageNum_allInfo = $_GET['pageNum_allInfo'];
}
$startRow_allInfo = $pageNum_allInfo * $maxRows_allInfo;

mysql_select_db($database_gauInfoConn, $gauInfoConn);
$query_allInfo = "SELECT shop_name, bus_route, stop_no, shop_cat, address, web_link, more_info FROM shops_on_routes ORDER BY shop_name ASC";
$query_limit_allInfo = sprintf("%s LIMIT %d, %d", $query_allInfo, $startRow_allInfo, $maxRows_allInfo);
$allInfo = mysql_query($query_limit_allInfo, $gauInfoConn) or die(mysql_error());
$row_allInfo = mysql_fetch_assoc($allInfo);

if (isset($_GET['totalRows_allInfo'])) {
$totalRows_allInfo = $_GET['totalRows_allInfo'];
} else {
$all_allInfo = mysql_query($query_allInfo);
$totalRows_allInfo = mysql_num_rows($all_allInfo);
}
$totalPages_allInfo = ceil($totalRows_allInfo/$maxRows_allInfo)-1;

$queryString_allInfo = "";
if (!empty($_SERVER['QUERY_STRING'])) {
$params = explode("&", $_SERVER['QUERY_STRING']);
$newParams = array();
foreach ($params as $param) {
if (stristr($param, "pageNum_allInfo") == false &&
stristr($param, "totalRows_allInfo") == false) {
array_push($newParams, $param);
}
}
if (count($newParams) != 0) {
$queryString_allInfo = "&" . htmlentities(implode("&", $newParams));
}
}
$queryString_allInfo = sprintf("&totalRows_allInfo=%d%s", $totalRows_allInfo, $queryString_allInfo);
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><!-- InstanceBegin template="/Templates/gau-info-template.dwt.php" codeOutsideHTMLIsLocked="false" -->
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!-- InstanceBeginEditable name="doctitle" -->
<title>Gau-Info: Home</title>

<meta name="description" content="Gautrain, Gautrain busses, Bus routes, Database of shops on routes">

<meta name="keywords" content="Gautrain, Gautrain busses, Bus routes, Database of shops on routes">



<!-- InstanceEndEditable -->
<!-- InstanceBeginEditable name="head" -->
<style type="text/css">
#apDiv3 {
position:absolute;
width:148px;
height:115px;
z-index:1;
left: 747px;
top: 172px;
}
</style>
<style type="text/css">
h1,h2,h3,h4,h5,h6 {
font-weight: bold;
}



/style>
<style type="text/css">
a:visited {
color: #03F;

}
</style>
<link href="file:///C|/xampp/htdocs/gau_info/styles/gau-info-styles.css" rel="stylesheet" type="text/css" />
<!-- InstanceEndEditable -->
<link href="styles/gau-info-styles.css" rel="stylesheet" type="text/css" />
<style type="text/css">
#apDiv1 {
position:absolute;
left:635px;
top:456px;
width:154px;
height:35px;
z-index:1;
}
#apDiv2 {
position:absolute;
left:764px;
top:478px;
width:127px;
height:32px;
z-index:1;
}
</style>
</head>

<body>
<div id="gi-main-container">
<div id="gi-header"><!-- InstanceBeginEditable name="Breadcrumbs" -->
<div id="breadcrumb-trail"><a href="index.php">home</a> &gt;</div>
<!-- InstanceEndEditable --></div>
<!-- InstanceBeginEditable name="TopNavigation" -->
<div id="menu-container">
<!--Nav Tab 1 start -->
<div id="navigation-tab-background-active">
<div id="navigation-tab-active"><a href="index.php">Home</a></div>
</div>
<div id="navigation-tab-background-inactive">
<div id="navigation-tab-inactive"><a href="search.php">Search</a></div>
</div>



<div id="navigation-tab-background-inactive">
<div id="navigation-tab-inactive"><a href="routes.php">Routes</a></div>
</div>

<div id="navigation-tab-background-inactive">
<div id="navigation-tab-inactive"><a href="feedback.html">FeedBack</a></div>

</div>

<div id="navigation-tab-background-inactive">
<div id="navigation-tab-inactive"><a href="admin/indexcms.php">CMS</a></div>
</div>

<!--Nav Tab 4 end -->
</div>
<!-- InstanceEndEditable -->
<div id="body-container"><!-- InstanceBeginEditable name="SideMenu " -->
<div id="gi-left-column">
<h1>General..</h1>
<p><a href="centHighv_c1.php"></a>This website was created to supply information to the bus user. It consists of a database which contains all the information on the various bus routes. You can obtain the required information by searching our database or by simply going to the routes tab where all the stops of every route can be found.</p>
<p> <a href="centRooih_C2.php"></a></p>
<p><a href="centRooih_C2.php"></a></p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p><a href="sandtFourw_s5.php"></a><img src="images/Company-Logo.png" width="150" height="32" /></p>
</div>
<!-- InstanceEndEditable --><!-- InstanceBeginEditable name="BodyContent" -->
<div id="gi-body-column">
<h1>All info.. </h1>
<p>&nbsp;</p>
<table width="692" border="0" cellpadding="2" id="db displ">
<tr align="center" bordercolor="#0516FC" bordercolorlight="#0516FC" bordercolordark="#0516FC" bgcolor="#000000" id="dbDisplHeading">
<th width="102" scope="col">Name</th>
<th width="50" nowrap="nowrap" scope="col">Route</th>
<th width="50" scope="col">Stop No</th>
<th width="89" nowrap="nowrap" scope="col">Category</th>
<th width="83" nowrap="nowrap" scope="col">Address</th>
<th width="98" nowrap="nowrap" scope="col">Web Link</th>
<th width="85" nowrap="nowrap" scope="col">More Info</th>
</tr>


<?php do { ?>
<tr bgcolor="#CCCCCC" id="dbDisplRow" style="font-family: Arial, Helvetica, sans-serif; font-size: 9px; font-weight: normal; color: #000;">



<td><?php echo $row_allInfo['shop_name']; ?></td>
<td width="50"><?php echo $row_allInfo['bus_route']; ?></td>
<td width="50"><?php echo $row_allInfo['stop_no']; ?></td>
<td><?php echo $row_allInfo['shop_cat']; ?></td>
<td><?php echo $row_allInfo['address']; ?></td>
<td><?php echo $row_allInfo['web_link']; ?></td>
<td width="85"><?php echo $row_allInfo['more_info']; ?></td>
</tr>
<?php } while ($row_allInfo = mysql_fetch_assoc($allInfo)); ?>
</table>
<table border="0">
<tr>
<td><?php if ($pageNum_allInfo > 0) { // Show if not first page ?>
<a href="<?php printf("%s?pageNum_allInfo=%d%s", $currentPage, 0, $queryString_allInfo); ?>"><img src="first db.png" alt="First" border="0" id="sprytrigger1" title="First" /></a>
<?php } // Show if not first page ?></td>
<td><?php if ($pageNum_allInfo > 0) { // Show if not first page ?>
<a href="<?php printf("%s?pageNum_allInfo=%d%s", $currentPage, max(0, $pageNum_allInfo - 1), $queryString_allInfo); ?>"><img src="prev db.png" alt="Prev" border="0" title="Prev" /></a>
<?php } // Show if not first page ?></td>
<td><?php if ($pageNum_allInfo < $totalPages_allInfo) { // Show if not last page ?>
<a href="<?php printf("%s?pageNum_allInfo=%d%s", $currentPage, min($totalPages_allInfo, $pageNum_allInfo + 1), $queryString_allInfo); ?>"><img src="next db.png" alt="Next" border="0" title="Next" /></a>
<?php } // Show if not last page ?></td>
<td><?php if ($pageNum_allInfo < $totalPages_allInfo) { // Show if not last page ?>
<a href="<?php printf("%s?pageNum_allInfo=%d%s", $currentPage, $totalPages_allInfo, $queryString_allInfo); ?>"><img src="last db.png" alt="Last" border="0" title="Last" /></a>
<?php } // Show if not last page ?></td>
</tr>
</table>
<p>&nbsp;</p>
<p>



</p>

<p>&nbsp;</p>
<p>&nbsp;</p>
</div>
<!-- InstanceEndEditable --><!-- InstanceBeginEditable name="RightColumn" -->
<div id="gi-right-column">



</div>
<!-- InstanceEndEditable --></div>

<div id="gi-footer">
<div class="credits"></div>
</div>
</div>
</div>
</body>
<!-- InstanceEnd --></html>
<?php
mysql_free_result($allInfo);
?>


[CODE]

Any help would be highly appreciated!!