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;
}
$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

chat
hello i'm amir i need a chat source code in asp.net 2.0 without Ajax. anybody can help me?

why isn't this PHP code working ???
it's suppose to find a name on the database.

<?php

$s = $_POST["lname&

Simultaneous select/update/insert
Hi

How would I need to go about when 2 users update a single row simultaneous? And how would

PHP hyperlinks generator
Hi

I need some help to get this done using php:


1 - I have few hyperlinks say 500

problem with php server update from mid 2009
Hi,

I have this navigation menu on 2 websites which used to work just fine. After a recent up

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

array_combine() error
getting an "Warning: array_combine() [function.array-combine]: Both parameters should have an e

calculator
I can't figure out why this code doesn't work. No error messages. Page loads.

Code: <

can i optmize image to 50% quality before uploading 2 server
Hi there

i have jus written a php program to upload and display images but when i try to uplo

Filtering Tables
Hello Thanks for any help any one can give Im very new to PHP..

I need to pull data for clien

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