Welcome Guest, Not a member yet? Register   Sign In
question about redirect
#1

[eluser]Hitesh Chavda[/eluser]
I have a little question.

Can I send data with redirect.

If yes, how?
#2

[eluser]Dam1an[/eluser]
Yes, and you'll most likely want to use flashdata (or normal userdata if you need it to last multiple requests)
Read all about it on the sessions page in the user guide
#3

[eluser]Hitesh Chavda[/eluser]
Thanks man
#4

[eluser]8th wonder[/eluser]
yes you can use it!!!!

before redirect just do

Code:
$_SESSION=$_POST;
redirect("example.php");

and in example.php
Code:
$_POST=$_SESSION;
$userid=$_POST['userid'];

have fun dude!!!!
#5

[eluser]Dam1an[/eluser]
[quote author="8th wonder" date="1252423602"]yes you can use it!!!!

before redirect just do

Code:
$_SESSION=$_POST;
redirect("example.php");

and in example.php
Code:
$_POST=$_SESSION;
$userid=$_POST['userid'];

have fun dude!!!![/quote]

That's a terrible idea! In the first case you've be overwritting the session array and in the second case, the post array, both of which may contain other data
#6

[eluser]Hitesh Chavda[/eluser]
True, I like to use

Code:
$this->session->set_flushdata('item','value');




Theme © iAndrew 2016 - Forum software by © MyBB