I am using the DOMPDF library to export a web page to a pdf file. Everything works just fine on my pc (localhost) but on Altervista it doesn't seem to work.
I get the following error message:
Fatal error: require_once() [function.require]: Failed opening required '.../dompdf/lib/html5lib/Parser.php' (include_path='.:') in .../dompdf/dompdf_config.inc.php on line 320
It's likely to be a path issue. Or maybe some kind of configuration is required in dompdf.
Can anyone help? Thanks!
alessandro
Related
I have very basic knowledge of coding, I took a copy of our company's website to practice making changes to it.
But when I try to run it I get this error
Warning: require_once(/var/www/html/classes/database_class_pdo.php):
failed to open stream: No such file or directory in
D:\xampp\htdocs\HJ\top.php on line 10
Fatal error: require_once(): Failed opening required
'/var/www/html/classes/database_class_pdo.php'
(include_path='D:\xampp\php\PEAR') in D:\xampp\htdocs\HJ\top.php on
line 10
Please, can someone tell me the issue here?
Thank you.
It's because your php file is trying to open a file named /var/www/html/classes/database_class_pdo.php but cannot find it. Try to see if the path is correct or if the file exists.
Configure error logging.
I'm working with PHP, and I'm on the support side, but I do not know the error system. Is there any material I can read to help me?
My biggest problem is this, many errors are written to the log this way:
PHP Fatal error: require_once(): Failed opening required 'vc-icon-element.php' (include_path='.;C:\php\pear') in D:\home\site\wwwroot\wp-content\plugins\js_composer\config\conte on line 6
But it seems the path is not complete and I do not know which file made the request for vc-icon-element.php. How would I do to find out which file or page that generated this log? Is it normal that the path does not reach a .php file?
I am having the same problem on the Windows-with-xampp side of the fence as Gerardo Tarragona is having on the Ubuntu-with-lampp side. Ref: How to install phpChart lite library?
I have tried a couple or few things and the roadblock I am hitting (see PHP error messages from browser below the code snippet) seems to be that the conf.php file is trying to require_once('phpChart.php') but I cannot find this file phpChart.php anywhere on disk. It does not seem to be with the phpChart_Lite extracted download. Can anybody shed light on this ? What am I missing ?
Here is the conf.php file code:
<?php
define('SCRIPTPATH','/phpChart_Lite/');
define('DEBUG', true);
/******** DO NOT MODIFY ***********/
require_once('phpChart.php');
/**********************************/
?>
Warning: require_once(phpChart.php): failed to open stream: No such file or directory in C:\xampp\htdocs\phpChart_Lite\conf.php on line 10
Fatal error: require_once(): Failed opening required 'phpChart.php' (include_path='.;C:\xampp\php\PEAR') in C:\xampp\htdocs\phpChart_Lite\conf.php on line 10
Depending on your system, change SCRIPTPATH to
define('SCRIPTPATH','/phpChart_Lite');
or
define('SCRIPTPATH','phpChart_Lite/');
When I moved MediaWiki from Localhost to the server I started getting the below error. I am using the latest version and tried to use php 5.3, 5.4 and 5.5 but error exists for all version of php. I know this might not be php version related but just cross checked.
Warning:
require_once(/home/meuser/public_html/site_dir\extensions\Cite\Cite.php):
failed to open stream: No such file or directory in
/home/meuser/public_html/site_dir/LocalSettings.php on line 132
Fatal error: require_once(): Failed opening required '/home/meuser/public_html/site_dir\extensions\Cite\Cite.php'
(include_path='.:/opt/php54/lib/php') in
/home/meuser/public_html/site_dir/LocalSettings.php on line 132
When I commented Cite extension (to disable the extension) to cross check, it gives the same error for the next extension. So I believe there is something wrong in moving server?
I have just uploaded all files to the server and changed database and site url settings in Localsettings.php and imported database.
Is there any extra step required?
There's an issue with the directory separators in your paths. Notice how they're all forward slashes until you reach site_dir. Fix these and it should work perfectly. Based on this code the paths you need to change are in LocalSettings.php
i think this will help you
Syntax:
require_once($_SERVER['DOCUMENT_ROOT']./your file location with only '/' slash);
ie.,
require_once($_SERVER['DOCUMENT_ROOT']./site_dir/extensions/Cite/Cite.php);
I have applied the google map to my local server via Xampp. I have moved it to my web hosting server and I can not get it to connect to the databse. I was able to get other db connections to work but the issue here is I must be puting the file path in incorrectly. I am using the same file structure as on my local machine.
The Errors:
Warning: require(../includes/core/db/map_dbinfo.php) [function.require]: failed to open stream: No such file or directory in /home/xxxxxxx/public_html/includes/state_map/phpsqlajax_genxml2.php on line 2
Fatal error: require() [function.require]: Failed opening required '../includes/core/db/map_dbinfo.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/xxxxxxx/public_html/includes/state_map/phpsqlajax_genxml2.php on line 2
Anyone know why it's throwing these errors now but not on local machine and how I can go about fixing it?
I really have no idea where to start or even how to word this question. Any help would be appreciated. Thanks
You are standing in .../includes/states_map/phpsqlajax_genxml2.php and trying to reach "../includes/core/db/map_dbinfo.php". If you go back one directory from states_map you get to includes, and then you try to find includes under the includes directory.
Change the include to ../../includes/core/db/map_dbinfo.php
Why this is happening? Probably because you on your local server has .../includes added in you r include_path in php, which then will try includes/../includes/...