Warning: Cannot use a scalar value as an array in /home/admin/public_html/forum/include/fm.class.php on line 757

Warning: Invalid argument supplied for foreach() in /home/admin/public_html/forum/include/fm.class.php on line 770
Форумы портала PHP.SU :: Версия для печати :: Как установить tidy?
Форумы портала PHP.SU » PHP » Программирование на PHP » Как установить tidy?

Страниц (1): [1]
 

1. Ovak - 12 Апреля, 2008 - 16:51:22 - перейти к сообщению
че-то я не догоняю...
1) добавил в пхп.ини extension=php_tidy.dll
и extension_dir = "c:\php\ext\"
2) добавил в переменные среды в Path c:\php\; и c:\php\ext;
Проверил на двух примерах:
1)
<?php
$html = '<HTML><HEAD></HEAD><BODY>Hello World</BODY></HTML>';
$tidy = new tidy;
$config = array(
'indent' => true,
'output-xhtml' => true,
'wrap' => 200);
$tidy->parseString($html, $config, 'utf8');
$tidy->cleanRepair();
$html = $tidy;
?>

Пишет Class 'tidy' not found

2)
<?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;
?>

пишет call to undefined function tidy_parse_string()


У меня Виста, php5.
Подскажите пожалуйста в чем проблема...

 

Powered by ExBB FM 1.0 RC1