What's Going On...";
Echo $root;
include("$root/wpconfig/connect.ini");
$root = getenv("DOCUMENT_ROOT") ;
$cxn = mysqli_connect($host,$user,$password,$database)
or die ("couldn't connect to server");
$query = "SELECT * FROM wp_posts WHERE post_type = 'post' AND post_status = 'publish' ORDER BY post_date DESC LIMIT 10";
$result = mysqli_query($cxn,$query)
or die ("Cannot complete the Caffeene query");
while ($row = mysqli_fetch_assoc($result))
{
extract ($row);
$TITLE = $row['post_title'];
$URL_LINK = $row['post_name'];
$POST_DAT = $row['post_date'];
$mydate = date("F j, Y", strtotime($POST_DAT));
echo "
";
}
?>