extending tidy


Posted on 16th Feb 2014 07:03 pm by admin

I have problem with type-hinting and extending tidy. This code creates error:
Code: class cMyTidy extends tidy
{
public $tralala;
Did you know?Explore Trending and Topic pages for more stories like this.
}
$oMyTidy = new cMyTidy();

doSomething($oMyTidy);

function doSomething(cMyTidy $oObject)
{
var_dump($oObject);
}
PHP Fatal error: Argument 1 passed to doSomething() must be an instance of cMyTidy......
If I change type-hinting in function from cMyTidy to tidy everything is OK.
Where is the problem?
No comments posted yet

Your Answer:

Login to answer
122 Like 41 Dislike
Previous forums Next forums
Other forums

update sql when refresh - php
hi
I have made a table (attachement)

the users can update the sql database using + or x bu

error reporting
hey everyone

I have a production server in which I want error reporting but only on some page

PHP login form help (Done Most of It)
Hi i am having a problem, when i try logging in it is always saying "Invalid Login" im not

shift numbers with paging
Hi

How would i be able to display 10 numbers 1 2 3 4 5 6 7 8 9 10
and when I click next

how do I show what a user have selected from a checkbox?
From my code below, how would i show which check boxes have been checked and which radio buttons sel

cstdatomic (c++0x std::atomic) / g++ 4.4
Hello,

I'm trying to use cstdatomic (std::atomic in the upcoming c++0x standard) in g++

PHP Code reffering to database, doing something wrong.. pls help
Well i am quite new with PHP
and for school we have to make a PHP script which reffers to a Data

array_combine() trouble w/csv file
I have a problem with a piece of code I wrote to import some records from a csv file into mysql. I h

PHP mail() returns true but doesn't work
First off I apologize if this is a newbie question, and I generally don't like asking questions that

PHP Game
hy i was wondering what's the best method in order to make some automatic updates in a php game
<

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash