I have a function.
This code is working.
But if try that
Than i have an error:
PHP Fatal error: Class 'clearos\\apps\\server_1c\\DOMDocument' not found in /usr/clearos/apps/server_1c/libraries/Server_1C.php on line 564, referer: https://192.168.1.22:81/app/server_1c
Why if use view_form webconfig said that DOMDocument not found. But if i use function without view_form all works fine.
Why?
function rpmlist()
{
$this->load->library('Server_1C');
$dom = new DOMDocument;
$dom->loadHTML($postResult);
}
This code is working.
But if try that
function rpmlist()
{
$this->load->library('Server_1C');
$dom = new DOMDocument;
$dom->loadHTML($postResult);
$data = array();
$data['rpmlist'] = $this->server_1c->login1c('login,'Password');
$this->page->view_form('app/rpmlist', $data, lang('server_1c_web_app_name'));
}
Than i have an error:
PHP Fatal error: Class 'clearos\\apps\\server_1c\\DOMDocument' not found in /usr/clearos/apps/server_1c/libraries/Server_1C.php on line 564, referer: https://192.168.1.22:81/app/server_1c
Why if use view_form webconfig said that DOMDocument not found. But if i use function without view_form all works fine.
Why?
Share this post:
Accepted Answer
I can't explain why you're seeing what you're seeing, but I don't think view_form is the problem.
If your app is executing in Webconfig, make sure you have webconfig-php-xml. If your app is using the Apache/PHP, make sure you have php-xml installed (for whatever version of PHP you're using if you are using php-engines).
One other thing to try is to add a backslash in front of your objection creation...eg:
B
If your app is executing in Webconfig, make sure you have webconfig-php-xml. If your app is using the Apache/PHP, make sure you have php-xml installed (for whatever version of PHP you're using if you are using php-engines).
One other thing to try is to add a backslash in front of your objection creation...eg:
$dom = new \DOMDocument();
B
Responses (1)
-
Accepted Answer
Maybe i was something wrong in my explaination. I have an error when i try to executing DOMDocument from Library Class. And so \DOMDocument it is working.
[root@clearosdev controllers]# yum list installed | grep php-xml
php-xml.x86_64 5.4.16-45.el7 @clearos-centos
rh-php56-php-xml.x86_64 5.6.25-1.el7 @clearos-centos-sclo-rh
rh-php56-php-xmlrpc.x86_64 5.6.25-1.el7 @clearos-centos-sclo-rh
rh-php70-php-xml.x86_64 7.0.27-1.el7 @clearos-centos-sclo-rh
rh-php71-php-xml.x86_64 7.1.8-1.el7 @clearos-centos-sclo-rh
webconfig-php-xml.x86_64 5.4.16-45.v7 @clearos
Please login to post a reply
You will need to be logged in to be able to post a reply. Login using the form on the right or register an account if you are new here.
Register Here »