This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
following the php/saas tutorial on solaris, when in ja or zh locale (not the utf-8 versions of them) - the project does not run, browser says it can't find a certain file whereas in fr non utf-8 locale and en locale, it runs ok. I realize at this point, I don't know if issue is one of web services or php, but filing in php at this time since thats context of tutorial. problem is: > Have followed steps in tutorial; am on solaris. >> http://wiki.netbeans.org/SaaSPHPTutorial >> >> and the Http_Request and other pkgs are installed or were installed >> and have restarted netbeans also. >> >> but on running the project get this in browser: >> >> Fatal error: Class 'HTTP_Request' not found in /opt/coolstack/apache2/htdocs/PhpProject88/org_netbeans_saas/RestConnection.php on line 36 >> >> line 36 of that file has >> $this->req =& new HTTP_Request($this->url); >> below is email thread about it - as mentioned there, there is no project or file name or path using multibyte, nor is nb installed where there is nor is project dir nor htdocs dir have it in path. and when using zh locale, I am using a non pseudo localized nb, so its not a matter of some message translated that should not be. I reviewed my entries of php.ini and even copied the HTTP dir to be under php5/lib/php/PEAR (on coolstack solaris its capitalized) but then found out the problem seems to happen in at least solaris ja and zh locales (zh is not pseudo localized, so its not a pseudo localization problem) however does not happen in fr locale or even zh_CN.UTF-8 locale. the project encoding is default utf-8 always. but even when have project encoding of gb2312 and in zh locale, for which gb2312 is default encoding, the problem happens. There are no use of multibyte in project name, project path, path to coolstack apache or php. ---> seems like some problem in at least asian locales - what code is looking for the Request.php - is it the yahoo code, our nb code, php or pear or apache ? maybe there is some clue there to see why in certain locales it show the error ? Ken Ayub Khan wrote: > Hi Ken, > > There could be 2 reasons > > 1. php.ini do not have pear in its include_path > > For example (on Mac OSX 10.5) > > Macintosh:etc ayubkhan$ pwd > /Applications/xampp/etc > Macintosh:etc ayubkhan$ grep pear php.ini > ; A warning appears if the specified function is not defined, or if the > ;***** Added by go-pear > include_path=".:/Applications/xampp/xamppfiles/lib/php:/Applications/xampp/xamppfiles/lib/php/pear" > > 2. HTTP/Request.php not found > > Macintosh:pear ayubkhan$ pwd > /Applications/xampp/xamppfiles/lib/php/pear > Macintosh:pear ayubkhan$ ls HTTP/ > Request Request.php > > Thanks > Ayub > > Ken Frank wrote: >> Have followed steps in tutorial; am on solaris. >> http://wiki.netbeans.org/SaaSPHPTutorial >> >> and the Http_Request and other pkgs are installed or were installed >> and have restarted netbeans also. >> >> but on running the project get this in browser: >> >> Fatal error: Class 'HTTP_Request' not found in /opt/coolstack/apache2/htdocs/PhpProject88/org_netbeans_saas/RestConnection.php on line 36 >> >> line 36 of that file has >> $this->req =& new HTTP_Request($this->url); >> >> >> Are there some steps that might not have been done ok ? >> won't be able to try on other platforms right now however but assuming >> it would need to work on solaris also. >> >> Thanks - Ken >> >
>> Fatal error: Class 'HTTP_Request' not found in /opt/coolstack/apache2/htdocs/PhpProject88/org_netbeans_saas/RestConnection.php on line 36 >> >> line 36 of that file has >> $this->req =& new HTTP_Request($this->url); The error is clear - you don't include HTTP_Request class in your PHP script or do not have it on your PHP include path. If you exactly followed the tutorial, the bug is probably there.
reopening until can understand more about why closed as its not clear at all. below mentions - The error is clear - you don't include HTTP_Request class in your PHP script or do not have it on your PHP include path. If you exactly followed the tutorial, the bug is probably there. but it is mentioned in script and on include path, and as mentioned in issue, it only happened on some locales (one of them being not a pseudo localized situation) thus if problem happens only in some situations, that does not seem like problem with what is mentioned above. are you saying that there is a bug in tutorial if its followed exactly ? ken.frank@sun.com
I will look at the tutorial but probably not now because it will be quite time-consuming (going through the tutorial, investigating why the error could happen). But first - Ken, have you tried the tutorial on the same PC just somehow switching locale? If no, I would say that there's very like bug in your PHP/PEAR setup (as I wrote, the error clearly says that you are missing some file - it would be the same like in Java file with missing import - not related to IDE). But I will investigate more. Marking as INCOMPLETE till the questions are answered. Thanks.
as mentioned in issue, am not on pc for this, on solaris 10.
Clarified - you have only one PHP environment and you are somehow changing locale in it - I will look at it.
Adding Marek to CC, he will look at the tutorial. Thanks a lot.
Before I start evaluating this, please confirm that you have php_http extension enabled in all cases.
what is php_http extension ? is it mentioned in tutorial or in php docs about setup ? in any case, what are the steps to enable it ? ken.frank@sun.com
Sorry, my mistake - it seems that you should have Http_Request enabled through PEAR from the tutorial steps. Could you please attach the output of the following command?: pear list There should be the Http_Request there. We still don't know if you are running this on one machine and one OS, or using different machines and/or OSs for different locales.
here's the list from pear list Installed packages, channel pear.php.net: ========================================= Package Version State Archive_Tar 1.3.2 stable Console_Getopt 1.2.3 stable HTTP_Request 1.4.2 stable Net_Socket 1.0.9 stable Net_URL 1.0.15 stable PEAR 1.7.1 stable Structures_Graph 1.0.2 stable as mentioned in this issue, am running on solaris 10 and under the locales mentioned below. ken.frank@sun.com ken.frank@sun.com
Ken, could you please attach your php.ini file? The one which is used by Apache server. Thanks.
Ken, I went through the tutorial and - it _cannot_ be related to locale changes. Please, provide _exact_ steps to reproduce, otherwise I will close it as INVALID (look at my first comment to find out the reason). Thanks.
attached is php.ini file on solaris. the include path has multiple entries since wanted to make sure things were covered. the spelling of PEAR in all caps is correct since that is how it is on solaris. I do need to do this on windows to compare. ken.frank@sun.com
Created attachment 66209 [details] php.ini
on pc its ok, using xamplite pkg even though I don't see any output in the browser, there are no error msgs like on some locales of solaris. I have not added the new code to index.php to display it nicely since pasting it in led to syntax errors, but the original code should work ok since it did on solaris - its just that its not showing anything, or that using 0710 on windows so perhaps that is it. I still need to provide detailed steps on solaris. ken.frank@sun.com
Ken, could you please attach output of the following commands? Thanks. ls -l /opt/coolstack/php5/lib/php ls -l /opt/coolstack/php5/bin/pear ls -l /opt/coolstack/php5/lib/php/PEAR ls -l /opt/coolstack/php5/lib/php/HTTP ls -l /opt/coolstack/php5/lib/php/PEAR/HTTP
Created attachment 66322 [details] list of some /opt/coolstack dirs
attached is solaris dir listing of certain php dirs as requested. ken.frank@sun.com
Ken, could you please try this code (somewhere in the top of your script): include_once("HTTP/Request.php"); Then try to run it and let me know whether there is some error on not. Thanks.
Ken, could you please try this code (somewhere in the top of your script): include_once("HTTP/Request.php"); Then try to run it and let me know whether there is some error on not. Thanks. ==> yes, adding that line, it runs ok in ja locale will remove the incomplete keywd. ken.frank@sun.com
> ==> yes, adding that line, it runs ok in ja locale > will remove the incomplete keywd. That means that this issue has no relation to NetBeans so my very first comment in this issue was right.
does the line then need to be added to the sample code ? the include once ( ...) statement disucssed below since only when that was included did it work when in other locale. ken.frank@sun.com
No idea - you probably have to contact the author of the tutorial.
maybe I'm missing something here, but I assume since the bug seems to be about that line being needed ion code, but its not in the tutorial, but yet its marked as invalid - am confused --- is it that the line is really not needed when running in other locales and I was doing something else not correctly ? but if the line is needed, then why is the issue invalid ?
This issue is invalid because there's nothing NB could help you with. I guess that: - something wrong is in your PHP setup, or/and - something wrong is in the code of the tutorial?
Tomas, I agree with you that it could be either of those 2 reasons. the reason I filed the issue under php category is that I viewed php sample project as a part of php overall - if that is incorrect then can someone on php team let me know under what category this should be filed. But if other things about php sample project would be viewed as being under php category, then I think this one would be also. ken.frank@sun.com
What I said in last comment is not correct; I was confusing the php sample project, air alliance, which has its own issue related to i18n under php category, with this one - am sorry. thus my question for this one, is the php/saas sample an official kind of sample for netbeans.org and if so, what category should I change this issue to or is an issue even appropriate for tutorials like this if from netbeans.org ? ken.frank@sun.com
Aha, I understand now - I don't think that this tutorial belongs to the PHP component at all - I would guess Web Services? But as I wrote already, I don't know anything about it. You should probably ask Ayub Khan (you mentioned him in your first description).