Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

how to create object in php

//define a class
class MyClass{
  //create properties, constructor or methods
}

//create object using "new" keyword
$object = new MyClass();
 
//or wihtout parenthesis
$object = new MyClass;
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #create #object #php
ADD COMMENT
Topic
Name
6+4 =