How to redirect using $this-session-userdata(country_territory) |
(09-28-2019, 03:42 AM)InsiteFX Wrote: You can store the users id in the session then assign it to the view data. Thanks InsiteFX. I've created the variable in the Adverts Controller- PHP Code: $user_id = $this->session->userdata('user_id'); And this link in the view- PHP Code: <a href="<?php base_url('createadvert/'.$user_id);?>">CreateAdvert</a> My system rejected the above, first by the 2nd "=" so I deleted that, but it is still giving an error. I realize I need to do a lot more work. Once the advert is created I want it saved by the user_name presumably in the root directory. However, I first want to get the Layout to work. |
Welcome Guest, Not a member yet? Register Sign In |