Page 1 of 1

what is the PROBLEM with this CODE?

Posted: Sun Aug 05, 2007 6:27 am
by raahatazim
feyd | Please use

Code: Select all

,

Code: Select all

and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read:  [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]

Code: Select all

<?php
$html = '
<html>
  <head>
    <title>test</title>
  </head>
  <body>
    <p>paragraph</p>
  </body>
</html>';

$tidy = tidy_parse_string($html);

$body = tidy_get_body($tidy);
echo $body->value;
?>

feyd | Please use

Code: Select all

,

Code: Select all

and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read:  [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]

Posted: Sun Aug 05, 2007 8:38 am
by superdezign
What's the problem? That you wrote it, and pretty much had no idea what you were doing. Read the documentation for... whatever it is that you are using, or give us an actual problem. No one is going to go through all the effort required to find the class you are working with and then debug your code for you.

Posted: Sun Aug 05, 2007 10:20 am
by kaszu
As i understand you took it from http://lv2.php.net/manual/en/function.tidy-get-body.php
Do you have this library installed and your php is > 5.0.0 ?
If yes, then that what superdezign aready said.

Posted: Sun Aug 05, 2007 7:45 pm
by feyd
I'm having a difficulty seeing what this thread has to do with phpdeveloper.org. Please explain.

Posted: Mon Aug 06, 2007 12:35 am
by raahatazim
thanzzz for ur effort FEYD...........finding something other than the SOLUTION.

Posted: Mon Aug 06, 2007 12:55 am
by toasty2
Being rude to other people (especially moderators) isn't the best idea...they're trying to tell you a some things:
1) You need to say what exactly your problem is and provide more code.
2) You posted in the wrong forum section.