예제 #1
0
<?php

require 'journal.php';
$journal = new journal();
if (isset($_GET['entryID']) && is_numeric($_GET['entryID']) && $_GET['entryID'] > 0) {
    echo json_encode($journal->getJournalEntry($_GET['entryID']));
} else {
    echo json_encode($journal->getJournalHeadlines());
}