Re: [PHP] Loading modules not compiled in php

2002-12-21 Thread Tony Earnshaw
I have a site hosted at JTL Networks, and I'm looking into setting up
 a spell checker for my message boards.  The problem is, JTL doesn't have
 pspell compiled in with their php build, and it may be some time before
 they do (if they ever do).  Does anyone know of a way to include
 something like pspell support in php dynamically?  Like by using a
 .htaccess file to call it or something?

At the last count (Apache 1.3.27/PHP4.2.3), aspell doesn't get compiled into
PHP. It just sits in /usr/bin on RH Linux, at least..

The bad news is, that your code will have to be written for it. The good news
is, that you can cheese the code off Horde's Imp.

Best,

Tony

-- 

When all's said and done, there's nothing left to say or do ...
http://www.billy.demon.nl

-
This mail sent through IMP: http://horde.org/imp/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] overview of current app frameworks

2002-12-11 Thread Tony Earnshaw
ons, 2002-12-11 kl. 22:29 skrev Jonathan Ellis:

 horde --  main point in its favor is it is quite actively developped,
 and has an active community (mailing list has rougly 10x activity of the
 others here), but the docs are pathetic.

The docs are the PHP4 and PEAR manuals. Those who can not be bothered to
read them, does not deserve to work with PHP at all.

 (maybe that is why there is so
 much mailing list activity. :)  Whoever designed Horde's rudimentary
 data model was clueless --  primary key of the user table is the screen
 name, for instance.

Whoever criticises Horde's data model ought well to consider a job
mending roads (delivering Pizzas is o.k. as an alternative).

Best,

Tony

-- 

Tony Earnshaw

When all's said and done ...
there's nothing left to say or do.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] OpenSSL Encryption to a browser.

2002-11-30 Thread Tony Earnshaw
fre, 2002-11-29 kl. 12:50 skrev Comunica2 s. coop.:

 I would like to use OpenSSL to send encrypted information to a browser. The
 information would be encrypted to a public key that has its private
 counterpart installed in the browser. The idea is that the information would
 be decrypted automatically, but only when the destination browser has the
 right private key installed.

PKI encryption just does not work like that. Read up on the Openssl docs
and especially Ralf Engelschall's mod_ssl docs. The rsasecurity web site
PKI FAQ is also a good one to read, mark, learn and inwardly digest it
all. Given the existence of Carnivore and wireless networks, it's a
'must' for tomorrow's computing.

Best,

Tony


-- 

Tony Earnshaw

When all's said and done ...
there's nothing left to say or do.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] getaddrinfo failed: No address associated with hostname

2002-11-28 Thread Tony Earnshaw
tor, 2002-11-28 kl. 05:22 skrev Godzilla:

 Warning: php_network_getaddresses: getaddrinfo failed: No address associated
 with hostname

Your DNS doesn't work any more?

Best,

Tony

-- 

Tony Earnshaw

When all's said and done ...
there's nothing left to say or do.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] Report on: LDAP specific?

2002-11-15 Thread Tony Earnshaw
tor, 2002-11-14 kl. 11:50 skrev Krzysztof Dziekiewicz:

  I can show a jpeg using a href with a target, either in a new page or a
  frame. To do this, PHP needs to be fed 'header(Content-type:
  image/jpeg)'. This can be put more or less anywhere in the very short
  script used for showing the jpeg and works. However, if I try to put any
  more html code into the script, i.e. 'print html';, print 'body';
  etc, *anywhere*, I get a headers already sent error.

 You can not put any html code with image code.
 If you send some html you mean to send
 header(Content-Type: text/html)
 with
 header(Content-type: image/jpeg)
 Where do you want go to ?
 
 You can do so:
 There is on the page http://xxx/user.html?name=smith some html code where a user can 
act.
 Among the html code you insert img src=http://xxx/userfoto.html?name=smith;
 On http://xxx/userfoto.html you send  header(Content-type: image/jpeg) and the
 image content and no html code.

This fscking well works!!! It works with frames (one frame can be
hidden) and it works with pages.

I would *never* have had the intelligence to have found this out for
myself, well maybe it woould have taken me a month.

Krzysztof and php-general, I love you all like brothers.

Best,

Tony

-- 

Tony Earnshaw

Cricketers are strange people. They wake up
in October, only to find that their wives had
left them in May.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] How to break a while loop ?

2002-11-15 Thread Tony Earnshaw
fre, 2002-11-15 kl. 16:22 skrev Hacook:

 I made a while loop and i'd like to know the comand to break it from inside.
 Here is my script :
 
 while ($michou=$maxFiles){
 /// My script  and ate the end :
 if ($michou$michoumax) {
 break;
 }
 }
 
 But it doesnt work
 Can i put 2 conditions in the while() command ? if yes, what is the
 structure ?
 Thanks,
 hacook

'if/continue' instead of 'if/break'? I wondered what it was doing in
alien code today, so I looked it up.

Best,

Tony

-- 

Tony Earnshaw

Cricketers are strange people. They wake up
in October, only to find that their wives had
left them in May.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Reasons for error message: Warning: Failed opening'/www/servers/webGNOM/test.php' for inclusion(include_path='.:/usr/local/lib/php') in Unknown on line 0

2002-11-15 Thread Tony Earnshaw
fre, 2002-11-15 kl. 20:49 skrev Lee P. Reilly:

 Warning: Failed opening '/www/servers/webGNOM/test.php' for inclusion
 (include_path='.:/usr/local/lib/php') in Unknown on line 0

Permissions? Ownership?

Best,

Tony

-- 

Tony Earnshaw

Cricketers are strange people. They wake up
in October, only to find that their wives had
left them in May.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] LDAP specific?

2002-11-14 Thread Tony Earnshaw
People,

I'm trying to produce a book of mugs (a 'mug' is a 'face') for people
at work to be able to manage and change, as far as they are allowed to,
their own personal details in the org's directory database.

It's based on PHP 4.2.3/Apache and Openldap 2.1.8 and above and/or
Novell eDirectory NLDAP 8.0 or above.

One of the things I have to do, is show and change jpeg photos from the
user's browser. Browsers are the latest IE, Netscape or Mozilla. No
problem with that, only a problem with the following (Code sample
below):

I can show a jpeg using a href with a target, either in a new page or a
frame. To do this, PHP needs to be fed 'header(Content-type:
image/jpeg)'. This can be put more or less anywhere in the very short
script used for showing the jpeg and works. However, if I try to put any
more html code into the script, i.e. 'print html';, print 'body';
etc, *anywhere*, I get a headers already sent error. So I can't
include code for changing the BGCOLOR, sizing the image or anything like
that.

Anybody know a workaround? I've cheesed as much code as i can from the
recoginized tools, such as LDAPExplorer, John Hallam's magnificent yet
not widely known contrib. and the Wrox books, but none of them even
attempts to address what I want.

Best,

Tony

P.s., thanks for what is probably the most *patient minded* and catholic
mailing list on the Internet, and all the good advice.

?php

// Code to show a jpeg from an attribute sent on a previous page
// $headers = getallheaders();
// foreach ($headers as $name = $content) {
//echo headers[$name] = $contentbr\n;
// }

$ds=ldap_connect($Host, $Port);

if ($ds)  {
  @$r=ldap_bind($ds);

  if ($r) {
@$these_attrs = array($Attribute);
@$result = ldap_search($ds, $BaseDN, $target, $these_attrs);
if ($result) {
  @$result_id = ldap_first_entry($ds, $result);
  if ($result_id) {
@$foto=ldap_get_values_len($ds, $result_id, $Attribute);
header(Content-type:image/jpeg);
print $foto[0];
  }
}
  }
}
?

-- 

Tony Earnshaw

Cricketers are strange people. They wake up
in October, only to find that their wives had
left them in May.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] LDAP specific?

2002-11-14 Thread Tony Earnshaw
tor, 2002-11-14 kl. 11:14 skrev Chris Hewitt:

 frame. To do this, PHP needs to be fed 'header(Content-type:
 image/jpeg)'. This can be put more or less anywhere in the very short
 script used for showing the jpeg and works. However, if I try to put any
 more html code into the script, i.e. 'print html';, print 'body';
 etc, *anywhere*, I get a headers already sent error. So I can't

 The headers must be the first thing that is sent to the browser. Do all 
 your other html afterwards, or use output buffering.

Thanks for the answer, Chris. I realise this, but that just does not
work - been there, seen it, done it.

Wherever (even as 1st line) *any* PHP4 header stuff is put in the
script, adding html code later results in the same headers already
sent error. That's why I asked for a workaround, by name.

Best,

Tony

-- 

Tony Earnshaw

Cricketers are strange people. They wake up
in October, only to find that their wives had
left them in May.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] LDAP specific?

2002-11-14 Thread Tony Earnshaw
tor, 2002-11-14 kl. 11:14 skrev Chris Hewitt:

 The headers must be the first thing that is sent to the browser. Do all 
 your other html afterwards, or use output buffering.

Please nobody else bother, it's my own stupid fault for not knowing
enough.

I'm halfway there, output buffering will prove to be the answer and like
everything else with PHP it's a question of reading and practicing. I'm
an OS man rather than a programmer.

Best and thanks,

Tony

-- 

Tony Earnshaw

Cricketers are strange people. They wake up
in October, only to find that their wives had
left them in May.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] LDAP specific?

2002-11-14 Thread Tony Earnshaw
tor, 2002-11-14 kl. 11:50 skrev Krzysztof Dziekiewicz: 

 You can not put any html code with image code.
 If you send some html you mean to send
 header(Content-Type: text/html)
 with
 header(Content-type: image/jpeg)
 Where do you want go to ?
 
 You can do so:
 There is on the page http://xxx/user.html?name=smith some html code where a user can 
act.
 Among the html code you insert img src=http://xxx/userfoto.html?name=smith;
 On http://xxx/userfoto.html you send  header(Content-type: image/jpeg) and the
 image content and no html code.

tor, 2002-11-14 kl. 09:20 skrev BigDog: 

 I create a php page that gets the image and sends the correct header. 
 Then in my other php page that displays the details about a user i
call
 img src=showperson.php?name=$fullname. Then in showperson i send
the
 correct image headers and the image is displayed properly.
 
 HTH...
__

These are the answer. Bless you both, pretty sirs.

Best,

Tony

-- 

Tony Earnshaw

Cricketers are strange people. They wake up
in October, only to find that their wives had
left them in May.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] icmp ping, check port, etc.

2002-11-14 Thread Tony Earnshaw
tor, 2002-11-14 kl. 20:32 skrev Ewout de Boer:

 You could exec the ping command and analyze its output using regular
 expressions.

I just wondered whether Bryan wasn't trying to reinvent the wheel
(www.nessus.org, www.insecure.org, etc.)

Best,

Tony

-- 

Tony Earnshaw

Cricketers are strange people. They wake up
in October, only to find that their wives had
left them in May.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Swear word substitution

2002-11-14 Thread Tony Earnshaw
tor, 2002-11-14 kl. 16:54 skrev CJ:

 There was not a swear word in my original post but there was a word that
 contained a swear word but is itself not a swear word.  The word is Scu
 
 n
 
 thorpe

Don't believe it.

-- 

Tony Earnshaw, Yorkshireman, ah cum fra Scunthorpe mesemn.

Cricketers are strange people. They wake up
in October, only to find that their wives had
left them in May.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] remove/uninstall php3 on linux

2002-10-29 Thread Tony Earnshaw
tir, 2002-10-29 kl. 19:28 skrev MIke Pogue:

 Do you have any ideas how could I remove/uninstall an old php3 version on linux?
 Should I delete the files manually?

linux is a many splendored thing. On mine, I go about it exactly the
same way as I did on SCO OpenServer, UnixWare and Solaris when I used to
compile and install my own Open source software on them. Or I just
install over the top of what I had. But that's the easy way.

Perhaps you use rpms or apt-gets or suchlike, who can tell?.

Best,

Tony

-- 

Tony Earnshaw

Could have been Henrik Ibsen's, Ole Bull's,
Henrik Wergelands's, Camilla Collet's and more's
last words, but weren't: «Fanden helder, helder
det at have sadset, end det at ikke have sadset
i det hele taget.»

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl





--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] how to configure with ldap?

2002-10-13 Thread Tony Earnshaw

fre, 2002-10-11 kl. 20:11 skrev Jody Cleveland:

 Well, I installed openldap, and it tests out good. Now, I want to configure
 php to work with it. My question now is, where exactly is ldap located? I
 tried a few paths:
 ./configure --with-mysql --with-apxs2=/www/bin/apxs
 --with-ldap=/usr/local/etc/openldap
 ./configure --with-mysql --with-apxs2=/www/bin/apxs
 --with-ldap=/usr/local/libexec

 And, I get this error:
 checking for LDAP support... yes
 configure: error: Cannot find ldap.h

 So, I searched for ldap.h and used that path:
 ./configure --with-mysql --with-apxs2=/www/bin/apxs --with-ldap=/usr/include
 Same thing, cannot find.

 Any ideas?

Using LDAP needs specialist knowledge - you can't just bung it in and
expect it to work. You can't really compare it to SQL in that respect,
it's a niche - like PHP :-)

ftp://kalamazoolinux.org/pub/pdf/ldapv3.pdf
http://www.redbooks.ibm.com/pubs/pdfs/redbooks/sg244986.pdf
http://www.redbooks.ibm.com/pubs/pdfs/redbooks/sg245110.pdf

Best,

Tony

-- 

Tony Earnshaw

There are many people who can't face the truth ... If you rob a
normal person of life's lies, at the same time you'll be robbing
him of his happiness.

From Henrik Ibsen's Vildanden, The wild Duck.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] php 4.3.0pre and openssl 0.96g compile error

2002-10-13 Thread Tony Earnshaw

søn, 2002-10-13 kl. 01:48 skrev Jochen Kächelin:

 I tried to compile PHP with OpenSSL (0.96g) support with
 --with-openssl=/usr/src/web/openssl/current
 the way I did it since 4.1.0.

 I  always  get  the  message,  that  php  can't  find  the  openssl
 include-files.
 
 Any suggestions?

See if you have /usr/include/openssl . Which you most probably don't
have. If not, do: 'ln -s /usr/local/ssl/include/openssl
/usr/include/openssl' .

Best,

Tony

-- 

Tony Earnshaw

There are many people who can't face the truth ... If you rob a
normal person of life's lies, at the same time you'll be robbing
him of his happiness.

From Henrik Ibsen's Vildanden, The wild Duck.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl





--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] what do you think?

2002-09-28 Thread Tony Earnshaw

fre, 2002-09-27 kl. 14:26 skrev Ford, Mike [LSS]:

 I think the page needs a drastic proof-read and grammar check -- I have trouble 
understanding what some of it is even trying to say.  And I haven't a clue what 
ASSAY TO INTEGRATE MANAGEMENT is supposed to mean!

 It looks like a nice product, but I wouldn't even evaluate it after looking at this 
because I'd be worried about having to spend too much time trying to decipher it's 
output.

Beheading gnats:

1:

its (genitive) does *not* have an apostrophe.

it's a nice day - right;
it's output - wrong.

2: Please keep your line length to below 76 characters.

Best,

Tony

-- 

Tony Earnshaw

Growing old is compulsory, growing up is optional.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl
gpg public key: http://www.billy.demon.nl/tonni.armor

Telefoon:   (+31) (0)172 530428
Mobiel: (+31) (0)6 51153356

GPG Fingerprint = 3924 6BF8 A755 DE1A 4AD6 FA2B F7D7 6051 3BE7 B981
3BE7B981





signature.asc
Description: Dette er en digitalt signert meldingsdel


Re: [PHP] pardon the previous mis-topic

2002-09-19 Thread Tony Earnshaw

tor, 2002-09-19 kl. 05:27 skrev Monique Y. Herman:

 I'd started another question, realized the answer to it, and typed in another
 question without checking the subject ... mea culpa!

The only one in the whole wide world I've ever seen apologize for this.
Straight out, the only one.

Go straight to heaven, Monique, and experience the joy of eternal
self-justification. All the others must for ever suffer the pangs that
indolence confers.

Best,

Tonni

-- 

Tony Earnshaw

Tha can allway tell a Yorkshireman, but tha canna tell 'im much.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl
gpg public key: http://www.billy.demon.nl/tonni.armor

Telefoon:   (+31) (0)172 530428
Mobiel: (+31) (0)6 51153356

GPG Fingerprint = 3924 6BF8 A755 DE1A 4AD6 FA2B F7D7 6051 3BE7 B981
3BE7B981





signature.asc
Description: Dette er en digitalt signert meldingsdel


Re: [PHP] PHP Installation

2002-09-19 Thread Tony Earnshaw

ons, 2002-09-18 kl. 20:00 skrev Sascha Braun:

 It told me at last something about the cgi installation and some things i dont 
understand,
 so i feel very insecure.
 Please help me a little.

A ... den stakkars, stakkars Sascha :-(

In the directory in which you ran './configure', did you by any chance
see a number of files called README.something and one called
INSTALL? Did you read them especially INSTALL?

Don't you think it might be a good idea to do so? That's what I always
do.

Best,

Tony

-- 

Tony Earnshaw

Tha can allway tell a Yorkshireman, but tha canna tell 'im much.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl
gpg public key: http://www.billy.demon.nl/tonni.armor

Telefoon:   (+31) (0)172 530428
Mobiel: (+31) (0)6 51153356

GPG Fingerprint = 3924 6BF8 A755 DE1A 4AD6 FA2B F7D7 6051 3BE7 B981
3BE7B981





signature.asc
Description: Dette er en digitalt signert meldingsdel


RE: [PHP] jpeg thumbnail errors

2002-09-17 Thread Tony Earnshaw

tir, 2002-09-17 kl. 09:53 skrev Michael Egan:

 You would need to recompile PHP so that such support is
 offered - no mean feat from my own experiences. I gave up :-(

What's your exact problem, Michael?

I'm so new to PHP4 (done nothing at all with PHP for the last 3-4 years,
now I need to), that I'm reading, practicing reading etc. I don't even
have any questions, yet, I'm so green.

But I *do* know that I have compiled in jpg and png support to PHP 4.2.3
(phpinfo).

On Red Hat 7.2 +++, './configure --with-gd' - and other things, of
course.

Best,

Tony

-- 

Tony Earnshaw

Tha can allway tell a Yorkshireman, but tha canna tell 'im much.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl
gpg public key: http://www.billy.demon.nl/tonni.armor

Telefoon:   (+31) (0)172 530428
Mobiel: (+31) (0)6 51153356

GPG Fingerprint = 3924 6BF8 A755 DE1A 4AD6 FA2B F7D7 6051 3BE7 B981
3BE7B981





signature.asc
Description: Dette er en digitalt signert meldingsdel


Re: [PHP] A mailing list

2002-09-13 Thread Tony Earnshaw

fre, 2002-09-13 kl. 10:31 skrev John Wards:

 Guys and Gals sorry if this is off topic but I hope someone can answer this
 question.
 I need some mailing list software that works like this list i.e. its all
 done through email and has a web based archive.
 I know of mailman but I cannot get it to work and my questions go unanswered
 on the mailman help list.
 This is pretty urgent please help!

This is 100% OT, but very quickly said/written:

Stick at Mailman. Or explore alternatives such as ezmlm or Majordomo.
This is custom-written software and one couldn't *possibly* equal it
with a PHP-based approach.

I've implemented Mailman with Exim smtp server for different firms and
customers; there's a complete Exim how to and so on and so on.

Don't know what smtp software you run, or whether you're using procmail
or what, doesn't matter. Stick at Mailman.

Best,

Tony

-- 

Tony Earnshaw

Tha can allway tell a Yorkshireman, but tha canna tell 'im much.

e-post: [EMAIL PROTECTED]
www:http://www.billy.demon.nl
gpg public key: http://www.billy.demon.nl/tonni.armor

Telefoon:   (+31) (0)172 530428
Mobiel: (+31) (0)6 51153356

GPG Fingerprint = 3924 6BF8 A755 DE1A 4AD6 FA2B F7D7 6051 3BE7 B981
3BE7B981





signature.asc
Description: Dette er en digitalt signert meldingsdel