LemonInflux Posted October 25, 2007 Share Posted October 25, 2007 Fairly straightforward questions, was just wondering what these actually do. First, this symbol: => What does it do? I've seen stuff like array('submit' => 'post'), and I was just wondering what it actually did. The second is: $this. What is $this? I wouldn't have thought much of it other than a variable, but I was editing in Dreamweaver, and it was highlighted the colour of a global variable ($_POST, $_GET etc.). So what does it mean? I'm sure these aren't at all very complex, but I'd be very grateful if someone could answer. Thanks in advance, Tom. Quote Link to comment https://forums.phpfreaks.com/topic/74698-a-couple-of-questions/ Share on other sites More sharing options...
stuffradio Posted October 25, 2007 Share Posted October 25, 2007 '$this' is a saved variable... As in, in a function you use it to refer to itself. function testing($variable) { $this->$variable = "blah"; } Don't know if that helps you much... Don't know how to explain '=>' to you, somone will though! Quote Link to comment https://forums.phpfreaks.com/topic/74698-a-couple-of-questions/#findComment-377643 Share on other sites More sharing options...
LemonInflux Posted October 25, 2007 Author Share Posted October 25, 2007 so what will that function do? Quote Link to comment https://forums.phpfreaks.com/topic/74698-a-couple-of-questions/#findComment-377646 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.