with user : ". $user ."and pwd ".$pwd; echo "
"; $sql= "SELECT round (cfcal(19.25),2)"; $stmt = $dbconn->query($sql); $stmt->execute(); /* Fetch only the first row from the results */ $result= $stmt->fetch(); echo "29.25oC = ".$result[0]." oF "; echo "
db closed "; /*** close the database connection ***/ $dbconn= null; } catch(PDOException $e) { echo $e->getMessage(); } ?>