FAQ

Frequently Asked Questions

0) { while ($row = mysqli_fetch_array($query)) { $title = $row["title"]; $string = slug ($title); $des = $row["article"]; $small = substr($des, 0, 250); $nohtml = strip_tags($small); // html tags removed echo "
".$row['title']."
$nohtml .....
"; } }else{ echo "
Nothing Found
"; } } mysqli_close($con); ?> connect_error) { die("Connection failed: " . $conn->connect_error); } $sql = "SELECT id, title, article, views FROM tblknowledgebase ORDER BY views DESC"; $result = $conn->query($sql); if ($result->num_rows > 0) { // output data of each row while($row = $result->fetch_assoc()) { $views = $row["views"]; $title = $row["title"]; $string = slug ($title); echo "
Viewed : ". $row["views"]. "
"; } } else { echo "0 results"; } $conn->close(); ?>