Jump to content

Recommended Posts

Posted (edited)

I'm on the PHP Logic with OOP section, and have what I think may be a pretty simple question.

In v_login.php, where I see the login form, line 27 for example has this code:

<input type="password" name="password" value="<?php echo $this->getData('input_pass'); ?>"> - This line of code takes the user input, and spits it into the form for the user to see.

Then, in login.php, there is this code on line 30:

$_SESSION['username'] = $Template->getData('input_user'); - this line of code adds to the $_SESSION variable.

As v_login.php is included in login.php, why are there two different ways of calling the getData function?  Shouldn't there just be one way to call the function, given v_login.php is included in login.php?

Thanks,

Andrew

Edited by Drew2
  • 1 month later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...