clueless about pear

This is a discussion on clueless about pear within the PHP Language forums, part of the PHP Programming Forums category; I have PHP Version 5.0.1 installed on my computer, and according to the pear manual pear is already ...


Go Back   Usenet Forums > PHP Programming Forums > PHP Language

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 09-03-2004
red
 
Posts: n/a
Default clueless about pear

I have PHP Version 5.0.1 installed on my computer, and according to the
pear manual pear is already installed. But how do I tell if it is
installed ?

for example, how do I get this line, which I found in the pear manual to
work:
require_once "HTML/Table.php";


Warning: main(HTML/Table.php) [function.main]: failed to open stream: No
such file or directory in C:\Program Files\Apache
Group\Apache2\htdocs\public\reenie\test.php on line 9

I would simply change the path, but I don't see any table.php anywhere.


red
Reply With Quote
  #2 (permalink)  
Old 09-03-2004
JV
 
Posts: n/a
Default Re: clueless about pear

"red" <groups@reenie.org> wrote in message
news:90TZc.649664$6p.119874@news.easynews.com...
> for example, how do I get this line, which I found in the pear manual to
> work:
> require_once "HTML/Table.php";


this line indicates that the file table.php will be loaded as indicated here
http://us4.php.net/require_once
if table.php is not in your html/ directory then it cant be loaded
which is why you are getting this message

> Warning: main(HTML/Table.php) [function.main]: failed to open stream: No
> such file or directory in C:\Program Files\Apache
> Group\Apache2\htdocs\public\reenie\test.php on line 9
>
> I would simply change the path, but I don't see any table.php anywhere.
>
>
> red


try reading back through your book and see if table.php is a php file it
asks you to write to contain some functions.

JV


Reply With Quote
  #3 (permalink)  
Old 09-03-2004
red
 
Posts: n/a
Default Re: clueless about pear

JV wrote:
> "red" <groups@reenie.org> wrote in message
> news:90TZc.649664$6p.119874@news.easynews.com...
>
>>for example, how do I get this line, which I found in the pear manual to
>>work:
>>require_once "HTML/Table.php";

>
>
> this line indicates that the file table.php will be loaded as indicated here
> http://us4.php.net/require_once
> if table.php is not in your html/ directory then it cant be loaded
> which is why you are getting this message
>

yes I know
>
>>Warning: main(HTML/Table.php) [function.main]: failed to open stream: No
>>such file or directory in C:\Program Files\Apache
>>Group\Apache2\htdocs\public\reenie\test.php on line 9
>>
>>I would simply change the path, but I don't see any table.php anywhere.
>>
>>
>>red

>
>
> try reading back through your book and see if table.php is a php file it
> asks you to write to contain some functions.
>
> JV


The code is take from the pear manual on how to write table with pear. .
HTML/Table.php is supposed to be in pear, already installed. But I
don't
see any HTML directory anywhere.
>
>

Reply With Quote
  #4 (permalink)  
Old 09-03-2004
red
 
Posts: n/a
Default Re: clueless about pear

red (I)wrote:
>
> The code is take from the pear manual on how to write tables with pear. .
> HTML/Table.php is supposed to be in pear, already installed. But I don't
> see any HTML directory anywhere.
>


I have gotten the examples in the Core Components section of the PEAR
manual to work, so apparently I do have PEAR installed. Apparently the
HTML_table package is not installed along with PEAR on PHP. I have
loaded the package using the command line, but still get the no can find
message: "main(HTML/Table.php) [function.main]: failed to open stream:
No such file or directory "

When I loaded the package, nothng everindicated WHERE it was being
loaded . I sill can't find a HTML directory or Table.php file anywhere.
Any ideas ? I have been pouring over the manual and googling, to no
avail. My goal right now is to use get ANY PEAR package to work. Why is
this so hard ?

red
>>
>>

Reply With Quote
  #5 (permalink)  
Old 09-03-2004
Alvaro G. Vicario
 
Posts: n/a
Default Re: clueless about pear

*** red escribió/wrote (Fri, 03 Sep 2004 05:09:25 GMT):
> I have PHP Version 5.0.1 installed on my computer, and according to the
> pear manual pear is already installed. But how do I tell if it is
> installed ?


Try <? php_info() ?> and check the "Configure Command" cell: you may find
something like --with-pear=/usr/share/pear.

In any case, PEAR is just a collection of regular *.php files. I believe
than installing them consists in having them somewhere in your hard disk.
So check your disk (especially the PHP installation folder) for a "pear"
folder full of *.php files.

> require_once "HTML/Table.php";


Check again phpinfo() output. There's a setting called "include_path". If
you don't provide the full path of the file your script will search for it
in the directories specified in include_path.


--
--
-+ Álvaro G. Vicario - Burgos, Spain - ICQ 46788716
+- http://www.demogracia.com (la web de humor para mayores de 100 años)
++ «Sonríe, que te vamos a hacer una foto para la esquela»
--
Reply With Quote
  #6 (permalink)  
Old 09-03-2004
Matthias Esken
 
Posts: n/a
Default Re: clueless about pear

red wrote:

> When I loaded the package, nothng everindicated WHERE it was being
> loaded . I sill can't find a HTML directory or Table.php file anywhere.


Did you just load it or did you install it? Use
pear list
on the command line to find all installed packages.

If it's not installed, use
pear install HTML_Table
to install the package.

> My goal right now is to use get ANY PEAR package to work. Why is
> this so hard ?


Well, trying to solve a task without reading the documentation is not
easy.

Regards,
Matthias
Reply With Quote
  #7 (permalink)  
Old 09-04-2004
red
 
Posts: n/a
Default Re: clueless about pear

Matthias Esken wrote:
> red wrote:
>
>
>>When I loaded the package, nothng everindicated WHERE it was being
>>loaded . I sill can't find a HTML directory or Table.php file anywhere.

>
>
> Did you just load it or did you install it? Use
> pear list
> on the command line to find all installed packages.


Thanks, that tip really helped.
> If it's not installed, use
> pear install HTML_Table
> to install the package.
>
>
>>My goal right now is to use get ANY PEAR package to work. Why is
>>this so hard ?

>
>
> Well, trying to solve a task without reading the documentation is not
> easy.
>
> Regards,
> Matthias


That's not fair at all. I read the php documentation about PHP
installation and also the PEAR documentation, but I had trouble
understanding it. So I came here to ask questions. I thought that's what
these newsgroups were for. There's no need to get nasty about it.

Yes, the PEAR documentation says you have to install packeges, but it
seemed like it was aimed at people who were doing a complete
installation from scratch. Nowhere as far as I can tell, does it say
simply something like: "PEAR is included in PHP, but for most purposes,
you'll also need to install packeges which are not automatically
included in PHP."

I've read the part about the PFC at least three times and I still can't
figure out if the PFC is in the packages or the base installation.



red


Reply With Quote
  #8 (permalink)  
Old 09-04-2004
Matthias Esken
 
Posts: n/a
Default Re: clueless about pear

red wrote:

> Matthias Esken wrote:
>
>> Well, trying to solve a task without reading the documentation is not
>> easy.

>
> That's not fair at all.


OK. Take this Smiley

;-)

and add it to my former posting.

Regards,
Matthias *g*
Reply With Quote
  #9 (permalink)  
Old 10-06-2004
leegold2
 
Posts: n/a
Default Re: clueless about pear

Go to the PEAR website - there is documentation on this html table Class.

But, it may take some reading in a good PHP book if you don't understand
classes, objects and that sort of thing. I knew a little JAVA which is
very object oriented so I could understand PEAR.

IMHO, read for a few weeks, then at least even if you still can't do it
you will be able to ask the right questions.
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




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


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0