Jump to content

help with code - $variable_name = $connection->Execute(


Terry Cragg

Recommended Posts

Hi

I am newish to PHP and have been thrown in at the deep end by being given an unfinished project to undertake at my office. There are various parts of the code I don't understand and I don't even know if some bits are PHP or MySQL as it is far in advance of my experience. If I give some examples I would be grateful if anyone could give me some pointers on what the code means.

 

Example 1:

 

$variable_name = $connection->Execute('SELECT etc, etc, etc')

 

I have already tried to find the answers on the PHP and MySQL websites and searched on Google to no avail.

 

Thanks in advance for any help.

$connection in an instance of a database class. Somewhere there is a statement $connection = new class_name(); The class_name would indicate what class it is an instance of.

 

->Execute in a method of that database class and its name implies that it executes the database query that it is supplied as a parameter when it is called. The result that the method returns is assigned to $variable_name.

 

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.