Go Back   CodingForums.com > :: Server side development > PHP

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 11-14-2006, 07:06 PM   PM User | #1
LondonBoy
Regular Coder

 
Join Date: Aug 2006
Posts: 105
Thanks: 0
Thanked 0 Times in 0 Posts
LondonBoy is an unknown quantity at this point
Where can I get PHP/Pear extension?

Hi All,


I did this:
define("CTXPATH", "rqf/");
define("ABS_APP_PATH", DOCUMENT_ROOT.CTXPATH);


I've used this code: require_once(ABS_APP_PATH."/Statement.php"); directive and I got this error message:

Fatal error: main() [function.require]: Failed opening required 'c:/inetpub/wwwroot/Statement.php' (include_path='.;c:\php4\pear')

So i'm guessing that's because i'm missing the Pear extension, is that it?

I just just configured PHP 4.4 on my IIS 5.1 Server and it's works.
But does the message mean I need the Pear extension, isn't it available in the PHP Windows Installer?

Where do I download Pear? I went to the php.net website and I only saw pear for PHP 5

Plz help out if you can

thx

Last edited by LondonBoy; 11-14-2006 at 07:12 PM..
LondonBoy is offline   Reply With Quote
Old 11-14-2006, 07:13 PM   PM User | #2
CFMaBiSmAd
Senior Coder

 
CFMaBiSmAd's Avatar
 
Join Date: Oct 2006
Location: Denver, Colorado USA
Posts: 2,744
Thanks: 2
Thanked 256 Times in 248 Posts
CFMaBiSmAd is a jewel in the roughCFMaBiSmAd is a jewel in the roughCFMaBiSmAd is a jewel in the roughCFMaBiSmAd is a jewel in the rough
You need to post the code that is causing the error in order to get specific help.

Just because the error message lists the current include_path and that this mentions pear, does not mean that this has anything to do with pear.
__________________
If you are learning PHP, developing PHP code, or debugging PHP code, do yourself a favor and check your web server log for errors and/or turn on full PHP error reporting in php.ini or in a .htaccess file to get PHP to help you.
CFMaBiSmAd is offline   Reply With Quote
Old 11-14-2006, 07:38 PM   PM User | #3
CFMaBiSmAd
Senior Coder

 
CFMaBiSmAd's Avatar
 
Join Date: Oct 2006
Location: Denver, Colorado USA
Posts: 2,744
Thanks: 2
Thanked 256 Times in 248 Posts
CFMaBiSmAd is a jewel in the roughCFMaBiSmAd is a jewel in the roughCFMaBiSmAd is a jewel in the roughCFMaBiSmAd is a jewel in the rough
Constants my only contain - boolean, integer, float and string data. DOCUMENT_ROOT refers to a variable (the proper way to refer to it is $_SERVER['DOCUMENT_ROOT']) and you cannot make a defined constant the way it is.

Edit: Actually, if you do the following, the define does what you want it to -
PHP Code:
define("ABS_APP_PATH"$_SERVER['DOCUMENT_ROOT']."/".CTXPATH); 
Edit2: Because your define has a trailing slash "rqf/" when you combine this with the "/Statement.php" you will end up with two slashes.

When in doubt what a constant or variable contains, echo it to make sure it contains the expected contents.
__________________
If you are learning PHP, developing PHP code, or debugging PHP code, do yourself a favor and check your web server log for errors and/or turn on full PHP error reporting in php.ini or in a .htaccess file to get PHP to help you.

Last edited by CFMaBiSmAd; 11-14-2006 at 07:57 PM..
CFMaBiSmAd is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 11:11 AM.


Advertisement
Log in to turn off these ads.