Welcome Guest, Not a member yet? Register   Sign In
HELP: Can't Display Data
#2

(This post was last modified: 07-27-2015, 10:13 AM by mwhitney. Edit Reason: fix PHP tags )

You should probably be using CodeIgniter 3 if you're just getting started. 2.2.3 will reach end of life in October.

As for your problem, you haven't included your view code or really given an accurate description of your problem. By looking at your code, $results should be either FALSE or an array of row objects, so you would check in your view (since you aren't checking in your controller):
PHP Code:
<?php if ($results === FALSE) : ?>
<p>No results found</p>
<?php 
else : 
    foreach (
$results as $row) : 
?>
<p><?php echo '<pre>' print_r($row) . '</pre>'?></p>
<?php
    
endforeach;
endif; 
Reply


Messages In This Thread
HELP: Can't Display Data - by Maaacoooo - 07-27-2015, 09:52 AM
RE: HELP: Can't Display Data - by mwhitney - 07-27-2015, 10:12 AM



Theme © iAndrew 2016 - Forum software by © MyBB