Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $DB = '//10.14.61.62:1521/XE';
- $DB_USER = 'USERNAME';
- $DB_PASS = 'password';
- $con=oci_connect($DB, $DB_USER, $DB_PASS,)or die(oci_error());
- oci_select_db("10.14.61.62:1521/JURISDB",$con);
- $query = "SELECT * from USERNAME.events ";
- $result = oci_query($query) or die(oci_error());
- $arr =array();
- while ($row = mysql_fetch_assoc($result)) {
- $arr[] = array( "date" => $row["date"], "title" => $row["title"], "description" => $row["description"], "url" => "", );
- }
- header('Content-type: application/json');
- echo json_encode($arr);
- die();
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement