Answer Posted / kapil dhiman
<?php
class DemoTesting{
public $val="India is great";
public function checkThis()
{
//$this-> object of current class
echo $this->val;
}
}
$obj= new DemoTesting();
$obj->checkThis();
?>
| Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
How to define a user function?
What is $_ request?
What are the types of variables in php?
What is the difference between super () and this ()?
What does empty mean in php?
Explain what are the three classes of errors that can occur in php?
What are the three parts of an http request?
How to execute an sql query? How to fetch its result?
What are the encryption functions available in PHP?
Does php have a future?
How a variable is declared in php?
What language is php based on?
How to replace a substring in a given string in php?
Which function is used to read a single character from a file in PHP.
What is session_start () in php?