[eluser]Zero-10[/eluser]
[quote author="theprodigy" date="1308560610"]you don't have a FROM line in your sql.[/quote]
Of course! lol
Anywhoo, I did it a lot more simple than to join. What I did is that I defined the username from the session and then passed it over to my model which grabbed all the info needed and in my view file I did...
Code:
<?php foreach ($userinfo->result_array() as $row): ?>
<? echo $row["username"]; ?><br/>
<? echo $row["first_name"]; ?> <br/>
<? echo $row["last_name"]; ?> <br/>
etc...
<? endforeach; ?>
And it pulls the data just fine :3 It's thanks to your FROM comment that triggered all of this haha because I did forget that in my earlier code. Thanks again!
EDIT: If this is poor practice to output data like this, please let me know. I know very little about security and even though I am doing this out of interest, I would prefer knowing whether or not I'm doing it correctly as i know my method requires database table names in the html file "last_name" for example.