ajax.php
changeset 419 b8b4e38825db
parent 417 b76ebe229548
child 468 194a19711346
equal deleted inserted replaced
418:322fa0c91303 419:b8b4e38825db
   113           $db->die_json();
   113           $db->die_json();
   114         
   114         
   115         if ( $db->numrows() > 0 )
   115         if ( $db->numrows() > 0 )
   116         {
   116         {
   117           $have_draft = true;
   117           $have_draft = true;
       
   118           $draft_row = $db->fetchrow($q);
   118         }
   119         }
   119       }
   120       }
   120       else if ( $src !== false )
   121       else if ( $src !== false )
   121       {
   122       {
   122         $allowed = true;
   123         $allowed = true;
   143           'have_draft' => false
   144           'have_draft' => false
   144         );
   145         );
   145       
   146       
   146       if ( $have_draft )
   147       if ( $have_draft )
   147       {
   148       {
   148         $row = $db->fetchrow($q);
   149         $row =& $draft_row;
   149         $return['have_draft'] = true;
   150         $return['have_draft'] = true;
   150         $return['draft_author'] = $row['author'];
   151         $return['draft_author'] = $row['author'];
   151         $return['draft_time'] = enano_date('d M Y h:i a', intval($row['time_id']));
   152         $return['draft_time'] = enano_date('d M Y h:i a', intval($row['time_id']));
   152         if ( isset($_GET['get_draft']) && @$_GET['get_draft'] === '1' )
   153         if ( isset($_GET['get_draft']) && @$_GET['get_draft'] === '1' )
   153         {
   154         {