I have to take over a php project and I am totally new to php. I have this webpage that displays all packages sent to a customer and I want them to be able to click on the tracking number to do UPS website tracking.

The code:

<?php

$result = mysqli_query($conn, $sql);

if (!$result) {

    exit();
} else {

    if (mysqli_num_rows($result) > 0) {
        while ($row = mysqli_fetch_assoc($result)) {

            echo "<tr>";

            echo "<td><strong>";
            echo $row['trackingno'];
            echo "</td>";
            echo "<td>";
            echo $row['date_shipped'];
            echo "</td>";
            echo "<td>";
            echo $row['desc_reference2'];
            echo "</td>";
            echo "<td>";
            echo $row['status'];
            echo "</td>";
            echo "<td>";
            echo $row['date_delivered'];
            echo "</td>";

            echo "</tr>";
        }
    } else {
        echo "There are no Returns matching search!";
    }
}
?>

I need the "trackingno" to display the number but be able to clik on it and be a link to
http://wwwapps.ups.com/WebTracking/track?track=yes&trackNums=trackingno

Any suggestions will be highly apprecited.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.