Foreach loop does not working and print row data

Hi i am trying to get row data through foreach loop .Every thing Ok Print_is doing good width $alleventsdetail variable but when I am trying to print It’s does not work echo stripslashes($alleventsdetail->short_description);

 <?php
global $objCource;
if(!empty($_REQUEST['event_id_dropdown'])){
    $detail = $objCource->getCourceEventByCourceId($_REQUEST['event_id_dropdown']);
    $_REQUEST['event_id'] = $detail[0]->event_cource_id;

$alleventsdetails = $objCource->getEventCourceDetailbyId($_REQUEST['event_id']);
print_r($alleventsdetails);
if(!empty($alleventsdetails)){

    foreach($alleventsdetails as $alleventsdetail) {
            $bookcheck = $alleventsdetail->book_detail_id;
          echo stripslashes($alleventsdetail->short_description); 
    }       
}
}
?>

Read more here: Foreach loop does not working and print row data

Leave a Reply

Your email address will not be published. Required fields are marked *