include_once 'showData.php';
class dbInsertion {
function db_insertShow($showData_obj)
{}
$showData is a class object how can i get its data members in this db_insertShow function
here is the class showdata
class ShowData {
var $show_id;
var $type_id;
var $priority;
var $name;
var $sDescription;
var $lDescription;
var $bookinguntil;
var $runtime;
var $matinee;
var $evening;
var $pricefrom;
}
Inside your class you can retrieve the members like this:
Also you might want to have a look at the concept of getters and setters. Essentially they are just methods that are used to retrieve and set members. The bonus you get out of using getters and setters is that you can do extra stuff that might be required when retrieving the member. For this to make sense you should define your members as private though.
Then, instead of the above example, you can access the members like this: