Welcome Guest, Not a member yet? Register   Sign In
[SOLVED] [1.71] Passing data
#3

[eluser]Jeroen Brussich[/eluser]
Really?

That easy???

Ok, guess my className was not that bad chosen :p

thanks!

---------------------
edit
---------------------


I was too early to cry victory.
It still doesn't work.

I guess I have to use sessions to pass data from one function to another.

Code:
class Dummy Extends Controller {
  
   var $data            = array();
  
   function __construct()
   {
        parent::Controller();
        $this->data['foo'] = 'bar';
   }
  
   function index()
   {
        print $this->data['foo'];        //works
   }
  
   function doStuff()
   {
        print $this->data['foo'];         //works
        
        $this->data['number'] = 1;
        print $this->data['number'];      //works
   }
  
   function doSomethingElse($data == $this->data)
   {
        print $this->data['foo'];         //works
        print $this->data['number'];      //fails
   }
}


Messages In This Thread
[SOLVED] [1.71] Passing data - by El Forum - 08-29-2009, 09:08 AM
[SOLVED] [1.71] Passing data - by El Forum - 08-29-2009, 09:41 AM
[SOLVED] [1.71] Passing data - by El Forum - 08-30-2009, 06:48 AM
[SOLVED] [1.71] Passing data - by El Forum - 09-02-2009, 10:44 AM
[SOLVED] [1.71] Passing data - by El Forum - 09-02-2009, 06:02 PM
[SOLVED] [1.71] Passing data - by El Forum - 09-03-2009, 06:59 AM
[SOLVED] [1.71] Passing data - by El Forum - 09-05-2009, 04:54 PM



Theme © iAndrew 2016 - Forum software by © MyBB