On Thu, Jun 06, 2002 at 05:32:45AM -0000, James Edgar wrote: > class myClass > { > function myFunc($var) > { > include("xml.inc"); > $obj = new xml($data,"xml");
And what happened when you ran this? Why not tell us? In the future, please post error messages and/or results so we can help you more accurately. If you ran it, it'd probably say "Class declarations may not be nested." Pretty clear. The code for your xml class outside of myClass. But, you can create the object inside the class. So, put include('./xml.inc'); before class myClass and leave $obj = new xml($data, 'xml'); where it is. Enjoy, --Dan -- PHP classes that make web design easier SQL Solution | Layout Solution | Form Solution sqlsolution.info | layoutsolution.info | formsolution.info T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y 4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php