OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
Subject: php3 Digest 16 Mar 2000 18:00:01 -0000 Issue 1541
From: php3-digest-helplists.php.net
Date: Thu Mar 16 2000 - 12:00:01 CST


php3 Digest 16 Mar 2000 18:00:01 -0000 Issue 1541

Topics (messages 81414 through 81496):

PHP HELP ME
        81414 by: Lars Torben Wilson <torbenpinc.com>
        81415 by: plummerkokinawa.usmc-mccs.org
        81433 by: Colin McKinnon <colinwew.co.uk>
        81491 by: Scott Gray <scottycm.math.uiuc.edu>
        81494 by: Scott Gray <scottycm.math.uiuc.edu>

crypt & Mysql
        81416 by: Kerry Colligan <kcolligagenomicsolutions.com>
        81417 by: "Jason Brooke" <jasonqgl.org>

How did you build PHP--Any Doc about what PHP based?
        81418 by: Huang <huangfcs.mt.nec.co.jp>
        81460 by: "Mark Roedel" <roedelmletu.edu>

Help on Providerissue
        81419 by: Joe <joelumbroso.com>

Win2000???
        81420 by: "Pavel Kalian" <pkalianssw.cz>

New version of pinp compiler
        81421 by: "Manuel Lemos" <mlemosacm.org>

What about Richard Lynch?
        81422 by: David Elliott <DavidEcavendish.com>
        81425 by: "Marck D. Pearlstone" <marcksilverstones.com>
        81428 by: Rasmus Lerdorf <rasmusphp.net>
        81456 by: notsubscribedjadebox.com
        81474 by: Sascha Schumann <saschaschumann.cx>
        81476 by: "Brian Leyton" <bleytoncpe-usalco.com>

includes in private directories
        81423 by: "devta" <devtazdnet-es.com>
        81432 by: Colin McKinnon <colinwew.co.uk>
        81438 by: "devta" <devtazdnet-es.com>
        81459 by: rasmusphp.net

Regex Error (14)?
        81424 by: Auke van Slooten <aukemuze.nl>

Regular Expressions, PHP and Apache
        81426 by: "Jesper Hess Nielsen" <jespergraffen.dk>
        81441 by: "Jesper Hess Nielsen" <jespergraffen.dk>
        81445 by: rasmusphp.net

efficient way of counting in array?
        81427 by: Niklas Alberth <niklas-listnetdata.nu>
        81437 by: "Tyrone Watt" <tyronis.za>
        81447 by: rasmusphp.net
        81479 by: Unnikrishnan <unnikrishnangocubs.com>

How to stop displaying... Content-Type: text/html in abrowser
        81429 by: "Mark Nold" <MarkNawi.com.au>

PHP4 on SCO Unix ?????????
        81430 by: "Paul Gardiner" <I.T.Managerbarleychalu.co.uk>

MSSQL,PHP : 4K Limit fetching text rows : textsize setting doesn't work
        81431 by: "Yan Orel" <yanorelfreemail.it>
        81448 by: xsernadreamcom.es (Dream - Xavier Serna)
        81450 by: xsernadreamcom.es (Dream - Xavier Serna)
        81452 by: rasmusphp.net
        81455 by: Cynic <cynicmail.cz>

problems running apache after php install
        81434 by: Evgeny Gechev <etgsetcom.bg>
        81435 by: Evgeny Gechev <etgsetcom.bg>

TTF image is reading backwards
        81436 by: David Dumenil <medavid-d.com>
        81453 by: rasmusphp.net

Spam/bounced mail update, as of noon
        81439 by: Sascha Schumann <saschaschumann.cx>

Split function
        81440 by: TV Karthick Kumar <karthickaspiresys.com>
        81444 by:
        81451 by: rasmusphp.net
        81484 by: Unnikrishnan <unnikrishnangocubs.com>

Postgresql - for Windows
        81442 by: TV Karthick Kumar <karthickaspiresys.com>
        81446 by: rasmusphp.net

Fw: Érdemes megpróbálni...
        81443 by: "fota" <fotasopronbutor.hu>

Oracle8.0-function
        81449 by: darwis <darwispiksi.itb.ac.id>
        81483 by: "Maria Savela (BCS)" <Maria.Savelaedt.ericsson.se>

SQL Safe Mode on when off
        81454 by: Ivan Lucas <ivan.lucaslockdown.co.uk>

Writing an include to a file?
        81457 by: Joshua Hoover <plan10compfactory.com>
        81461 by: "Tim Zickus" <infozchesco.com>
        81463 by: "Martin Edelius" <martin.edeliusspirex.se>
        81466 by: Joshua Hoover <plan10compfactory.com>
        81472 by: Steve Edberg <sbedbergucdavis.edu>

Fwd: Re: Problem with FTP
        81458 by: "Knowledge Based" <phpnovicehotmail.com>

include / require
        81462 by: Moritz Petersen <moritz.petersendisc-us.de>
        81464 by: "Martin Edelius" <martin.edeliusspirex.se>
        81468 by: Gregor Welters <gregorwelters.de>

PHP editor
        81465 by: Nick Steele <nsarchsky.com>
        81467 by: "Henry F. Marquardt" <hankyerpso.net>
        81469 by: "Chris VanderPoel" <wlvrnwlvrn.com>
        81473 by: "Robert V. Zwink" <rzwinkmicrocenter.com>

Something destroying PHP_AUTH_USER, 2nd try
        81470 by: "Boget, Chris" <chriswild.net>
        81477 by: "Chris Murtland" <chrisstudiomoxie.com>
        81478 by: rasmusphp.net

ora error 12154 using oci calls
        81471 by: php-info <php-infosoldusa.com>

Postgres connection indices
        81475 by: Paulo Jan <admindigital.ddnet.es>

Windows NT - IIS
        81480 by: Hugh Cowan <hwcowanhotmail.com>
        81487 by: mocha_php <mocha_phpyahoo.com>
        81488 by: "Henry F. Marquardt" <hankyerpso.net>

Win98, php4-beta, apache 1.3.12, ISAPI
        81481 by: mocha_php <mocha_phpyahoo.com>

php3 and apache compil
        81482 by: cagnasso <cagnassoehess.cnrs-mrs.fr>

Reply-To WAS: RE: [PHP3] What about Richard Lynch?
        81485 by: Richy <richymillorsoft.es>

How to build an associative array ??????????????
        81486 by: "sufi malak" <sufi_mhotmail.com>
        81493 by: Unnikrishnan <unnikrishnangocubs.com>

View Records by ID#
        81489 by: "Justin" <justinbigcity.nu>
        81495 by: "Henry F. Marquardt" <hankyerpso.net>

Twig and PHP
        81490 by: "Chris Mauritz" <ritzmordor.net>

Metaphone, Similiar Text, Fuzzy matching
        81492 by: "Paul Meagher" <pauldatavore.com>

mysql_query result
        81496 by: Chris Moewes-Bystrom <christophermoewes.com>

Administrivia:

To subscribe to the digest, e-mail:
        php3-digest-subscribelists.php.net

To unsubscribe from the digest, e-mail:
        php3-digest-unsubscribelists.php.net

To post to the list, e-mail:
        php3lists.php.net

----------------------------------------------------------------------

attached mail follows:


Langley writes:
> I want to learn PHP but I dont know how to get started what should i do?
> what are all the things needed in order to use php?

Hi! Welcome to PHP.

Assuming you have a grasp of programming in general, it's easy. The
best place to get the dirt on installing PHP and getting started is
http://www.php.net...which is the official PHP site. For starters,
read the "Getting Started" section of the manual
(http://www.php.net/manual/). Read it again. Decide on what
installation materials you need, and install them. If you need help
finding any of the parts you want, read the FAQ
(http://www.php.net/FAQ.php3).

Then, read the PHP Tutorial (http://www.php.net/tut.php3) and try
everything. Then, read the WebMonkey tutorial, which will equip you to
handle databasing: http://hotwired.lycos.com/webmonkey/99/21/index2a.html.

If you understand basic programming concepts, read the whole "Language
Reference" in the manual--it contains information on syntax, control
structures, data types, yada yada.

(some) Other good sites:

 http://www.zend.com (PHP4 only, although the manual is the same)
 http://www.devshed.com (Lots of info on PHP and other net
    technologies)
 
Oh yeah--don't be afraid to ask anything related to PHP on this
list. Even with Richard Lynch gone for the nonce, you'll get an answer
quickly. If you don't know Richard Lynch, you will if you hang out
here long...he and his kind are the best thing about this list. :)

Hope this gets you started,

Torben

-- 
+----------------------------------------------------------------+
|Torben Wilson <torbenphp.net>                     Netmill iTech|
|http://www.coastnet.com/~torben            http://www.netmill.fi|
|Ph: 1 250 383-9735                             torbennetmill.fi|
+----------------------------------------------------------------+

attached mail follows:


go to http://www.php.net, then read.

"Langley" <langleygalaxynet.com> on 03/16/2000 02:57:22 PM

To: php3lists.php.net cc: (bcc: Kit Plummer/MIS/MARINE MWR) bcc: Kit Plummer/MIS/MARINE MWR

Subject: [PHP3] PHP HELP ME

I want to learn PHP but I dont know how to get started what should i do? what are all the things needed in order to use php?

Thanks, any response is helpfull


attached mail follows:


At 22:23 15/03/00 -0800, Lars Torben Wilson wrote: >Langley writes: >> I want to learn PHP but I dont know how to get started what should i do? >> what are all the things needed in order to use php? >Assuming you have a grasp of programming in general, it's easy. The >best place to get the dirt on installing PHP and getting started is >http://www.php.net...which is the official PHP site. For starters, >read the "Getting Started" section of the manual >(http://www.php.net/manual/). Read it again. Decide on what >installation materials you need, and install them. If you need help >finding any of the parts you want, read the FAQ >(http://www.php.net/FAQ.php3). <snip>

But before you can actually start writing PHP, you'll need a web-server which speaks php and a browser to talk to it. I beleive that it is possible to run PHP with the 'Personal Web Server' (Microsoft?) on MS Win9X, and with MS-IIS on MS Win NT. My personal preference if for PHP + Apache on Linux as its straightforward to install (I wouldn't describe _any_ of the installations as "easy"). I did it by downloading the source code of Apache, the source code of PHP, compiling PHP (with MySQL support which I had already installed from an RPM), compiling Apache, and using the default config files.

Obviously life would be a lot simpler if you can get access to a preconfigured machine. There may be pre-compiled rpms available for Linux at one of the repositories (e.g. www.rpmfind.net).

(please don't anybody tell me how 'easy' it is to install on MS-Windows or I'll be forced to relate some of my experiences with these products)

Colin

attached mail follows:


Go to http://useractive.com they will walk you through it all at their site. You can even try code on the pages they have.

Scott Mills Gray scottycm.math.uiuc.edu

On Wed, 15 Mar 2000, Langley wrote:

> I want to learn PHP but I dont know how to get started what should i do? > what are all the things needed in order to use php? > > Thanks, any response is helpfull >

attached mail follows:


If people go to useractive.com you can learn to code PHP (by coding) and not worry about installation as of yet. Installation is harder than learning PHP itself, so why not see if you like it first before investing the time to install it?

http://useractive.com

Scott Mills Gray scottycm.math.uiuc.edu

On Wed, 15 Mar 2000, Lars Torben Wilson wrote:

> Langley writes: > > I want to learn PHP but I dont know how to get started what should i do? > > what are all the things needed in order to use php? > > Hi! Welcome to PHP. > > Assuming you have a grasp of programming in general, it's easy. The > best place to get the dirt on installing PHP and getting started is > http://www.php.net...which is the official PHP site. For starters, > read the "Getting Started" section of the manual > (http://www.php.net/manual/). Read it again. Decide on what > installation materials you need, and install them. If you need help > finding any of the parts you want, read the FAQ > (http://www.php.net/FAQ.php3). > > Then, read the PHP Tutorial (http://www.php.net/tut.php3) and try > everything. Then, read the WebMonkey tutorial, which will equip you to > handle databasing: http://hotwired.lycos.com/webmonkey/99/21/index2a.html. > > If you understand basic programming concepts, read the whole "Language > Reference" in the manual--it contains information on syntax, control > structures, data types, yada yada. > > (some) Other good sites: > > http://www.zend.com (PHP4 only, although the manual is the same) > http://www.devshed.com (Lots of info on PHP and other net > technologies) > > Oh yeah--don't be afraid to ask anything related to PHP on this > list. Even with Richard Lynch gone for the nonce, you'll get an answer > quickly. If you don't know Richard Lynch, you will if you hang out > here long...he and his kind are the best thing about this list. :) > > > Hope this gets you started, > > Torben > > -- > +----------------------------------------------------------------+ > |Torben Wilson <torbenphp.net> Netmill iTech| > |http://www.coastnet.com/~torben http://www.netmill.fi| > |Ph: 1 250 383-9735 torbennetmill.fi| > +----------------------------------------------------------------+ > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net >

attached mail follows:


I've got a table storing username and password. Data is inserted via php file calling "insert into table ... password=encrypt('$variable') ..."

How do I go about validating user input against the stored password $variable? I'm confused since crypt() is one-way. [ Please don't refer me to the mysql user manual as I've already scoured that. ]

Any help would be greatly appreciated.

Kerry Colligan

attached mail follows:


Select the user and password from the database where database-stored username = the user-supplied username.

Strip the first two characters off the database-stored password, and use those two characters as the salt for crypt()'ing the user-supplied password.

Compare the crypted user-supplied password against the database-stored password, and if it matches, it's the correct user/pass.

jason

> I've got a table storing username and password. Data is inserted via php > file calling "insert into table ... password=encrypt('$variable') ..." > > How do I go about validating user input against the stored password > $variable? I'm confused since crypt() is one-way. [ Please don't refer me > to the mysql user manual as I've already scoured that. ] > > Any help would be greatly appreciated. > > > Kerry Colligan

attached mail follows:


I am a software developer,and I am interested in something not only about HOW TO USE PHP but also HOW PHP WAS CONSTRUCTED . Yes there are many document about how to use PHP ,but few about HOW IT WAS CONSTURUCTED,what I mean that some doc like moudule's list ,PHP's architcture SPEC etc.,I need these doc because I want to make some addtion to PHP. Maybe my request is out ot scope(is it?),but I really don't want to be told "The only way to know how to improve PHP is looking into source file(which is with only little comment)" Please point out me a way to go.

Thanks.

attached mail follows:


> -----Original Message----- > From: Huang [mailto:huangfcs.mt.nec.co.jp] > Sent: Thursday, March 16, 2000 12:56 AM > To: php3lists.php.net > Subject: [PHP3] How did you build PHP--Any Doc about what PHP based? > > > I am a software developer,and I am interested in something not only about > HOW TO USE PHP but also HOW PHP WAS CONSTRUCTED . > Yes there are many document about how to use PHP ,but few about > HOW IT WAS CONSTURUCTED,what I mean that some doc like moudule's list > ,PHP's architcture SPEC etc.,I need these doc because I want to make > some addtion to PHP.

You mean something like

http://www.php.net/manual/phpdevel.php

---
Mark Roedel             |  "Blessed is he who has learned to laugh
Systems Programmer      |   at himself, for he shall never cease
LeTourneau University   |   to be entertained."
Longview, Texas, USA    |                           -- John Powell 

attached mail follows:


Stefan Carstens wrote:

> I have the problem that I'm searching a provider in germany, > which offers: > Apache Web server > +PHP3 > +perl > +sendmail (optional) > +MySQL > +min. 200Megs diskspace > +(hopefully) unlimited trafic! > > Is there a chance, or is it better to set up an own server, > thanks in advance,

also check out http://www.aigraphics.com they host http://www.dtheatre.com which is a pretty high traffic (also well made) site made out of PHP3 and seem to do good.

attached mail follows:


w2k+iis5 works the same as nt4+iis4

Pavel

----- Original Message ----- From: "Subhrajyoti Moitra" <subhraiitk.ac.in> To: <php3lists.php.net> Sent: Wednesday, March 15, 2000 6:18 PM Subject: [PHP3] Win2000???

> i am using win2000/IIS5.0 > how do i go about installing PHP3 on it .. should i use the > procedure mentioned in installing php3 on winnt4.0??? > are there any special things to be done while using php3.0 on win2000.. > thanx for your co-operation... > subhra > > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: > http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net >

attached mail follows:


Hello Auke,

On 15-Mar-00 07:40:41, you wrote:

>Hi, > there's a new version, 0.4, of the pinp 'compiler' at >http://www.muze.nl/software/tools/pinp.html >Version 0.3 had a hole which could be used to call any function from PHP. >0.4 now removes php comments before parsing the code.

You have nice PHP classes there. How about uploading them to the PHP Classes repository?

http://phpclasses.UpperDesign.com/

Uploading it here over 5.000 subscribers will be notified by e-mail and quickly you'll get many users to use and test your code. You'll be able to keep track exactly of how many users have downloaded your code and every time you add or update any of the files that you supplied the previous downloaders will be notified again so they always have your latest version without further effort from you.

If your classes get popular you will be featured in the top 10 charts pages.

http://phpclasses.UpperDesign.com/browse.html/top/

This is a free service for the PHP community. Make sure you upload nice examples and documentation if possible with your classes and your code will be very popular and you'll get plenty of nice feedback.

Regards, Manuel Lemos

Web Programming Components using PHP Classes. Look at: acm.org">http://phpclasses.UpperDesign.com/?user=mlemosacm.org

--
E-mail: mlemosacm.org
URL: http://www.mlemos.e-na.net/
PGP key: http://www.mlemos.e-na.net/ManuelLemos.pgp
--

attached mail follows:


Hi Manuel,

On 15 March 2000 at 15:45:26 GMT -0200 (which was about 17:45 where I live) Manuel Lemos <mlemosacm.org> wrote about "[PHP3] What about Richard Lynch?" and made these points:

ML> All these problems could be avoided if the PHP lists manager would not ML> set the Reply-to header to the original posters.

Pardon me I might have this wrong but if the list managers were doing as you suggested I think all of the bounced messages would have gone back to the list and it might be possible that we would all get all of the bounces.

I might have this wrong as I don't know how the list is setup.

-- 
Regards,
 David

davidecavendish.com

-------------------------------------- My tag line maker is broken! no it's not

Tag Line No 214675

Please let me know if you did not receive this. --------------------------------------

attached mail follows:


Hi David,

On 16 March 2000 at 08:41:29 GMT +0000 (which was 08:41 where I live) DavidEcavendish.com wrote and made these points:

ML>> All these problems could be avoided if the PHP lists manager ML>> would not set the Reply-to header to the original posters.

> Pardon me I might have this wrong

Pardoned.

> but if the list managers were doing as you suggested I think all of > the bounced messages would have gone back to the list and it might > be possible that we would all get all of the bounces.

Not so (fortunately). Bounces originate from a postmaster address at a server somewhere. That address is *not* a member of the list. As such the posting to the list is rejected. i.e. No Problem!

Cheers, .\\arck

-- 
Marck D. Pearlstone, Consultant Software Engineer
www: http://www.silverstones.com
PGP key: <mailto:mdaemonsilverstones.com?Body=GET%20MARCKKEY>
-----------------------------------------
Headline - Eye Drops off Shelf
-----------------------------------------

attached mail follows:


> On 15 March 2000 at 15:45:26 GMT -0200 (which was about 17:45 where I > live) Manuel Lemos <mlemosacm.org> wrote about "[PHP3] What about > Richard Lynch?" and made these points: > > ML> All these problems could be avoided if the PHP lists manager would not > ML> set the Reply-to header to the original posters. > > Pardon me I might have this wrong but if the list managers were doing as > you suggested I think all of the bounced messages would have gone back > to the list and it might be possible that we would all get all of the > bounces. > > I might have this wrong as I don't know how the list is setup.

Yes and no. There are plenty of reasons not to set the reply-to to point at the mailing list though. Read this for a good summary of the reasons:

http://www.unicom.com/pw/reply-to-harmful.html

I think the most obvious one is that some people actually do need a reply-to header because of the way their email systems are set up. If the mailing list was to wipe out that header, then nobody would be able to email these poor people directly. That is the whole reason for the reply-to field, and killing it would defeat that.

-Rasmus

attached mail follows:


>Not so (fortunately). Bounces originate from a postmaster address at a >server somewhere. That address is *not* a member of the list. As such >the posting to the list is rejected. i.e. No Problem!

I'm posting this from an unsubscribed address.

attached mail follows:


On Thu, Mar 16, 2000 at 08:14:26AM -0500, notsubscribedjadebox.com wrote: > >Not so (fortunately). Bounces originate from a postmaster address at a > >server somewhere. That address is *not* a member of the list. As such > >the posting to the list is rejected. i.e. No Problem! > > I'm posting this from an unsubscribed address.

FUD seems to be prevailing in this thread. :)

The list server

- does not reject emails from non-subscribed addresses - does not add reply-to headers - can not prevent broken software from sending emails to wrong addresses (i.e. the originator of the post)

So, if you send an email to the list and get bogus replies from broken software, please forward it to php-list-adminlists.php.net

Thank you.

- Sascha

attached mail follows:


> On Thu, Mar 16, 2000 at 08:14:26AM -0500, notsubscribedjadebox.com wrote: > > >Not so (fortunately). Bounces originate from a postmaster address at a > > >server somewhere. That address is *not* a member of the list. As such > > >the posting to the list is rejected. i.e. No Problem! > > > > I'm posting this from an unsubscribed address. > > FUD seems to be prevailing in this thread. :) > > The list server > > - does not reject emails from non-subscribed addresses > - does not add reply-to headers > - can not prevent broken software from sending emails to > wrong addresses (i.e. the originator of the post) > > So, if you send an email to the list and get bogus replies > from broken software, please forward it to > php-list-adminlists.php.net

I'll add one more point for those who insist that the Reply-To should be set to the list address instead of the originator of each list posting. I'm on a list that does that, and what ends up happening is that every time a message gets posted to the list, everyone on the list also receives an "Out of office" message from the guy who forgot to unsubscribe before going on vacation.

Considering the size of this list, and the number of messages that get posted daily, could you imagine what would have happened in the situation that started this thread? *Everyone on this list* would have received a bounce message from that guy instead of just the original poster. As bad as it was this time, the number of bounced messages was only 1 for each original posting. Can you imagine if instead of receiving one email for each one you had posted to the list, you would have instead received one for EVERY MESSAGE POSTED TO THE LIST in the last 6 months?

'nuff said.

Brian

attached mail follows:


Hi

I need to put an include in a private directory to prevent it may be browsed. But it makes to appear the user and password validation window ?How to do it without putting the included file in a public directory?

--------------------------------------------------------- Devta Singh devtazdnet-es.com devtamanantial.org ---------------------------------------------------------

attached mail follows:


At 10:13 16/03/00 +0100, devta wrote: >I need to put an include in a private directory to prevent it may be >browsed. >But it makes to appear the user and password validation window >?How to do it without putting the included file in a public directory?

Put it outside the directory hierarchy your web server uses, e.g. DocumentRoot=/home/httpd/html

require "/home/httpd/phpinclude/afile.inc";

HTH

Colin

attached mail follows:


Ok, but the thing is that this file must be accesible via FTP to the remote webmaster

> At 10:13 16/03/00 +0100, devta wrote: > >I need to put an include in a private directory to prevent it may be > >browsed. > >But it makes to appear the user and password validation window > >?How to do it without putting the included file in a public directory? > > Put it outside the directory hierarchy your web server uses, > e.g. > DocumentRoot=/home/httpd/html > require "/home/httpd/phpinclude/afile.inc";

attached mail follows:


> I need to put an include in a private directory to prevent it may be > browsed. > But it makes to appear the user and password validation window > ?How to do it without putting the included file in a public directory?

included php files can live anywhere on your file system and has nothing to do with any sort of authentication.

-Rasmus

attached mail follows:


On Wed, 15 Mar 2000, Patrick Durusau wrote:

> Greetings, > > I am trying to use the following line: > > $line_list = split("|",$line); > > to split fields on a line into an array. The fields are > delimited by the "|" character and not every field has content, i.e., > there are sometimes several "|" characters next to each other. I need that > "null" content preserved for import into the database. > > When I run the script I get an regex error (14) error at this line. >

Hm, the problem is that split uses regular expressions to chop the string in pieces and '|' has special meaning in regular expressions. If you use explode() instead it should work. Alternatively you could try : split("\|",$line)

regards, Auke van Slooten http://www.muze.nl/

attached mail follows:


Hi list

I'm still having some trouble getting PHP to work with its own bundled regular expressions. The problem is, that when I compile PHP with --with-apxs, it insists on using only the systems regex and not its own. Does anyone know how the heck I can get it to work properly? I'm using Apache 1.3.12 and PHP 3.0.15.

/Jesper

ps.. I'm on a deadline here, so any help is really greatly appreciated

attached mail follows:


Message-ID: <004301bf8f3a$c9a6a500$de0110acworkstation2> From: "Jesper Hess Nielsen" <jespergraffen.dk> To: <php3lists.php.net> Date: Thu, 16 Mar 2000 12:28:25 +0100 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_0040_01BF8F43.1FF9AB20" Subject: Regular Expressions, PHP and Apache

------=_NextPart_000_0040_01BF8F43.1FF9AB20 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable

Hi list

I'm still having some trouble getting PHP to work with its own bundled regular expressions. The problem is, that when I compile PHP with --with-apxs, it insists on using only the systems regex and not its own. Does anyone know how the heck I can get it to work properly? I'm using Apache 1.3.12 and PHP 3.0.15.

/Jesper

ps.. I'm on a deadline here, so any help is really greatly appreciated

------=_NextPart_000_0040_01BF8F43.1FF9AB20 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML><HEAD> <META content="text/html; charset=iso-8859-1" http-equiv=Content-Type> <META content="MSHTML 5.00.2920.0" name=GENERATOR> <STYLE></STYLE> </HEAD> <BODY bgColor=#ffffff> <DIV><FONT face=Arial size=2> <DIV><FONT face=Arial size=2>Hi list</FONT></DIV> <DIV>&nbsp;</DIV> <DIV><FONT face=Arial size=2>I'm still having some trouble getting PHP to work with its own bundled regular expressions. The problem is, that when I compile PHP with --with-apxs, it insists on using only the systems regex and not its own. Does anyone know how the heck I can get it to work properly? I'm using Apache 1.3.12 and PHP 3.0.15.</FONT></DIV> <DIV>&nbsp;</DIV> <DIV><FONT face=Arial size=2>/Jesper</FONT></DIV> <DIV>&nbsp;</DIV> <DIV><FONT face=Arial size=2>ps.. I'm on a deadline here, so any help is really greatly appreciated</FONT></DIV></FONT></DIV></BODY></HTML>

------=_NextPart_000_0040_01BF8F43.1FF9AB20--

attached mail follows:


> I'm still having some trouble getting PHP to work with its own bundled regular expressions. The problem is, that when I compile PHP with --with-apxs, it insists on using only the systems regex and not its own. Does anyone know how the heck I can get it to work properly? I'm using Apache 1.3.12 and PHP 3.0.15. > > /Jesper > > ps.. I'm on a deadline here, so any help is really greatly appreciated

PHP asks apxs which regex library Apache was compiled with and uses the same one. So, if you have compiled Apache with the system regex library, then PHP will use the system one as well.

Why do you care whether it uses the bundled regex library or the system one? They should both work, and they look the same from user-space.

-Rasmus

attached mail follows:


Hi!

I have a table full of 5 digit postalcodes. What I need is to count how many of them are the same. Say one field is 12345 then it should count how many occurances of 12345 there is. Output 12345 and the number of hits.

I can't figure out a smart way of doing this, I guess I will have a couple of thousand rows.

Any ideas?

--Niklas

attached mail follows:


If its in a table the use sql. Can't remember off the top of my head, I dont often use the group clause but i think it is something like.

select count(*) from TABLE group by FIELDNAME

Cheers. T

----- Original Message ----- From: Niklas Alberth <niklas-listnetdata.nu> To: php3 <php3lists.php.net> Sent: Thursday, March 16, 2000 11:54 AM Subject: [PHP3] efficient way of counting in array?

> Hi! > > I have a table full of 5 digit postalcodes. What I need is to count how > many of them are the same. > Say one field is 12345 then it should count how many occurances of 12345 > there is. Output 12345 and the number of hits. > > I can't figure out a smart way of doing this, I guess I will have a > couple of thousand rows. > > Any ideas? > > --Niklas > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net >

attached mail follows:


> I have a table full of 5 digit postalcodes. What I need is to count how > many of them are the same. > Say one field is 12345 then it should count how many occurances of 12345 > there is. Output 12345 and the number of hits. > > I can't figure out a smart way of doing this, I guess I will have a > couple of thousand rows. > > Any ideas?

If you are using PHP 4 there is an array_count_values() function that does exactly this.

For PHP 3 I would do something like:

while(list(,$v)=each($arr)) { $count[$v]++; }

while(list($k,$v)=each($count)) { echo "$k: $v<br>\n"; }

-Rasmus

attached mail follows:


it should be

select postalcode, count(*) from table group by postalcode

On Wed, 26 July 2000, "Tyrone Watt" wrote:

> > If its in a table the use sql. Can't remember off the top of my head, I dont > often use the group clause but i think it is something like. > > select count(*) from TABLE group by FIELDNAME > > Cheers. > T > > ----- Original Message ----- > From: Niklas Alberth <niklas-listnetdata.nu> > To: php3 <php3lists.php.net> > Sent: Thursday, March 16, 2000 11:54 AM > Subject: [PHP3] efficient way of counting in array? > > > > Hi! > > > > I have a table full of 5 digit postalcodes. What I need is to count how > > many of them are the same. > > Say one field is 12345 then it should count how many occurances of 12345 > > there is. Output 12345 and the number of hits. > > > > I can't figure out a smart way of doing this, I guess I will have a > > couple of thousand rows. > > > > Any ideas? > > > > --Niklas > > > > -- > > PHP 3 Mailing List <http://www.php.net/> > > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > > To search the mailing list archive, go to: > http://www.php.net/mailsearch.php3 > > To contact the list administrators, e-mail: php-list-adminlists.php.net > > > > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net

http://www.unni.com If there is a WILL there is a WAY ______________________________________________________________ Go Cubs Email - The Official Email Service of the Chicago Cubs Get your free Go Cubs Email account http://www.cubs.com

attached mail follows:


I found i had the same problem if i just copied my php3.ini to php.ini on installing PHP4 and Apache in windows.

What you need to do is modify the distributed php.ini by hand to meet your needs (I found this fixed my problem t least).

mn

Mark Nold marknalverstone.com.au Systems Consultant

>>> <rasmusphp.net> 03/15 11:27 pm >>> > ServerName http://localhost

That's not a valid server name

> DocumentRoot "C:/cgi-bin/php"

Your document root is under cgi-bin? That's really really weird.

Anyway, I will bow out now. I stopped answering Windows-related questions years ago. I should not set the precedence of starting to answer them again.

-Rasmus

attached mail follows:


Hi Fernando,

Re: PHP3

I've been looking at your problem, seems someone else had the same thing (http://bugs.php.net/bugs.php3?id=2751&edit=1). They were on 5.0.2 though.

The best thing I can suggest is contacting ( lehopaals.se ) the person who posted the bug and see if they managed to fix/get round it.

I'm sorry I can't be of any more help here as I have never used 5.0.0 or 5.0.2 and am unsure of the exact difference to my 5.0.4.

Unfortunately for me it seems PHP4 will not compile at the moment on SCO 5.0.4 either.

Please don't give up, it's worth the effort - The feeling when it compiles successfully is overwhelming :-)

Kind Regards, Paul.

----- Original Message ----- From: Fernando Ronci <fernandowaycom.com.ar> To: Paul Gardiner <I.T.Managerbarleychalu.co.uk> Sent: 13 March 2000 13:20 Subject: Re: [PHP3] PHP4 on SCO Unix ?????????

Dear Paul, My previous mail was truncated because of a dot I had put at the beginning of a sentence. As you know, mailers treat dots as end of DATA, so the remaining of the e-mail was trimmed. Here I quote my original message again (without the dot).

Best Regards,

Fernando

=========================================== Dear Paul,

Thank you very much for your help. Your script really speeds things up!! I followed all your instructions but unfortunately 'make' aborts while building PHP 3.0.15. No matter what parameters I feed to the configure script, it always fails with this error:

functions/filestat.c: In function `php3_diskfreespace´: funcions/filestat.c:151: storage size of `buf´ isn´t known make: *** [Functions/filestat.o] Error 1

I guess I have the same GNU utilities as you (from skunkware) , that is, gcc 2.95.2, gmake 3.78.1, bison 1.25, flex 2.5.4 and binutils 2.9.1 among others. The main differences are that you are working on Openserver 5.0.4 while I'm on 5.0.0 You also have the full dev system installed whereas I only have the libraries and linker which don't require a separate license. The rest seems to be the same.

I'm almost to give up. It's been a week of frustration with PHP 3.0.15. Let me tell you, I am trying to install IMP -an e-mail web interface- from http://www.horde.org/imp It requieres a lot of software, IMAP4, LDAP, MySql, Apache and PHP. In many cases, I was either able to compile them or download from http://www.sco.com/skunkware. The exception is PHP. Though there is a skunkware version of PHP, it is rather old and lacks the apache module. The version number is 3.0RC3 which I don't understand its meaning.

I failed in the last stage. Kind of unfortunate I am. If you can think of a workaround for this, please let me know.

Again, thank you very much for your help.

Best regards,

Fernando Ronci E-mail: fernandowaycom.com.ar

At 10:33 08/03/2000 +0000, you wrote: >Hi Fernando, > >Would be glad to help. Can you give me the error you're getting and also >versions of other software installed - make,bison,flex, development >system(if installed) ? > >I suspect the --with-apache=/usr/local/apache/bin/httpd directory is not >right unless this is where you have tar'd Apache source to, it should be the >top-level directory i.e. /usr/local/apache. I'm also assuming you wish to >build php as a module and not cgi. > >I have attached a script buildphp3.sh which you could have a look at and >modify - you'll have to add the --with-mysql bit in there. I usually compile >with Informix but have taken this line out for you. > >I have a directory /usr/src. in this directory is the buildphp3.sh script. >Also I have the apache_1.3.12.tar and php-3.0.15.tar files. In the script, >modify the first couple of lines to which versions you are installing, and >the directory you wish Apache to be built to. It is set to /usr/local/apache >at the moment(I think?) - it will tell you. > >Make sure you're in the /usr/src directory and then run the script using >./buildphp3.sh (make sure you set the file as executable). > >The script will tell you which versions it is about to install and the >directory apache will be built in. It will also advise to shutdown your >existing httpd if running. > >It removes the apache & php directory (if previously there) to ensure a >clean install. You can normally just 'clean' the install using if bison/flex >are installed (As I learnt the hard way), but I use the 'delete everything' >method just to be sure. It takes a little longer to build but it's not like >you're going to run this often - unless you're trying to install php4, but >that's a different story. Anyway, I'm babbling. > >After removing the directories it un-tar's the source files into their >respective directories. > >It then configures Apache. Don't worry about any flash settings here it will >be re-configured. > >Php is then configured. (add the --with-mysql and --with-xml or whatever >here). > >Php is then made (I use the GNU make - gmake version 3.78.1, you can get >this from www.sco.com skunkware section. Get the 'dist' version as it has >been pre-compiled). > >Php is then installed (copies relevant files to where they should be). > >Apache is then configured. > >Apache is then made. > >Apache is then installed. You have the option to abort at this stage in case >you wish to copy the binary to your apache/bin/ directory if you have it >already set-up. I would carry on and install if I was you. If you already >have anything of value in /usr/local/apache then back it up first! > >The script will advise to copy the php .ini file to /usr/local/lib and >configure /usr/local/apache/conf/httpd.conf where required. > >To start your new toy, just run /usr/local/apache/bin/apachectl start > >This works fine on my machine with gcc 2.95.2, gmake 3.78.1 SCO 5.0.4 + dev >system(if you do not have this I think you need to install just the library >files from the CD - you don't require a license for this). > >If you still have problems, perhaps we can go through it step by step. > >Regards, >Paul > >----- Original Message ----- >From: Fernando Ronci <fernandowaycom.com.ar> >To: Paul Gardiner <I.T.Managerbarleychalu.co.uk> >Sent: 07 March 2000 17:36 >Subject: Re: [PHP3] PHP4 on SCO Unix ????????? > > >Hi Paul, > >I wish you can give me a hand with PHP3. I've been desperately trying to >compile PHP 3.0.15 on OpenServer 5.0.0 with no success at all. I'm on gcc >2.95.2 >Though >./configure --with-mysql=/usr/local/mysql \ > --with-apache=/usr/local/apache/bin/httpd \ > --with-xml > >successfully finishes without complaints at all, 'make' miserably aborts >with this error message:

attached mail follows:


When I execute a SELECT on a varchar field, only the first 255 characters are returned.

I read the solution of setting the variables TEXTSIZE and TEXTLIMIT to a greater value in the php3.ini file. I added a MSSQL section in my php3.ini file (because there wasn't) and added the lines: -------- [MSSQL] mssql.textsize = 8192 mssql.textlimit = 8192 --------------

But this trick doesn't work.

If I execute the following statement SELECT TEXTSIZE and echo the result , i see 4096 then SET TEXTSIZE 65535 SELECT TEXTSIZE as K and echo the result , i see 65535 but if I try to retrieve my varchar field i only get the first 255 chars.

What's the problem ?

attached mail follows:


Hello Yan,

I found this problem too, and the solution is very easy, only need to put in php.ini these lines:

mssql.textsize=122880 mssql.textlimit=122880

put in the limit you want, and the problem is solved. Use regular select's and test it. Works fine for me.

Hope this helps,

> When I execute a SELECT on a varchar field, only the first 255 characters > are returned. > > I read the solution of setting the variables TEXTSIZE and TEXTLIMIT to a > greater value in the php3.ini file. > I added a MSSQL section in my php3.ini file (because there wasn't) and added > the lines: > -------- > [MSSQL] > mssql.textsize = 8192 > mssql.textlimit = 8192 > -------------- > > But this trick doesn't work. > > If I execute the following statement > SELECT TEXTSIZE > and echo the result , i see 4096 > then > SET TEXTSIZE 65535 > SELECT TEXTSIZE as K > and echo the result , i see 65535 > but if I try to retrieve my varchar field i only get the first 255 chars. > > What's the problem ? > > > > > > > > > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net >

--
Xavier Serna
 Webmaster Dream Comunicacion, S.L.
 Rbla. del Celler 133, 3er.
 08190 Sant Cugat del Valles, Barcelona
 Tel.: +34 (9)3 589 7932 - Fax: +34 (9)3 589 8234
 E-Mail: webmasterdreamcom.es
 ICQ#: 6953479
Web: 
 http://www.dreamcom.es
 http://www.musicpark.com
 http://www.fcmultimedia.com
 http://www.precioweb.com

attached mail follows:


Sorry, i''ve made a mistake on the previous post. I forgot to say that I put these lines not under the [MSSQL] header, just under [PHP_3] at the beginnig of the cfg file and works fine.

> mssql.textsize = 8192 > mssql.textlimit = 8192

--
Xavier Serna
 Webmaster Dream Comunicacion, S.L.
 Rbla. del Celler 133, 3er.
 08190 Sant Cugat del Valles, Barcelona
 Tel.: +34 (9)3 589 7932 - Fax: +34 (9)3 589 8234
 E-Mail: webmasterdreamcom.es
 ICQ#: 6953479
Web: 
 http://www.dreamcom.es
 http://www.musicpark.com
 http://www.fcmultimedia.com
 http://www.precioweb.com

attached mail follows:


> Sorry, i''ve made a mistake on the previous post. I forgot to say that > I put these lines not under the [MSSQL] header, just under > [PHP_3] at the beginnig of the cfg file and works fine.

Makes no difference actually. Those headers are just comments.

-Rasmus

attached mail follows:


Varchar is 255bytes long. Use different column type.

At 11:10 16.3.2000 +0100, Yan Orel wrote the following: -------------------------------------------------------------- >When I execute a SELECT on a varchar field, only the first 255 characters >are returned. > >I read the solution of setting the variables TEXTSIZE and TEXTLIMIT to a >greater value in the php3.ini file. >I added a MSSQL section in my php3.ini file (because there wasn't) and added >the lines: >-------- >[MSSQL] >mssql.textsize = 8192 >mssql.textlimit = 8192 >-------------- > >But this trick doesn't work. > >If I execute the following statement >SELECT TEXTSIZE >and echo the result , i see 4096 >then >SET TEXTSIZE 65535 >SELECT TEXTSIZE as K >and echo the result , i see 65535 >but if I try to retrieve my varchar field i only get the first 255 chars. > >What's the problem ? ------end of quote------ ____________________________________________________________ Cynic:

A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue.

<mailto:cynicmail.cz>cynic<mailto:cynicmail.cz>mail.cz ICQ: 2808 2505

attached mail follows:


Steve Murphy wrote:

> I have RedHat 6.1. I installed Apache rpm's from RH6.1. I installed > MySQL RPM's. I followed all instructions in the INSTALL.REDHAT file and > read every FAQ I can find. > > I tested apache and it works fine. > > I compiled php with MySQL support and /etc as the php3.ini location. I > then checked out the httpd.conf file amd the other. I then issued a > restart to the /etc/rc.d/init.d/httpd and it reported OK and OK for stop > and start. When I tried apache, nothing. Another restart yeilded > [Failed] on shutdown and [OK] on startup - no messages anywhere. > > Again, nothing from apache. And same messages from restart. > > I comment out the php lines in httpd.conf and apache works just fine. > > Am I missing something? Where can I look? I looked at apache error > log, /var/log/messages, etc. and found nothing. > > Is there anything I can do to track down the problem? > > Any help would be greatly appreciated. I've uninstalled, reinstalled, > and recompiled everything I can and it all stays the same. > > -Steve > > -- > ------------------------------------------------------------------- > Steve.MurphyTechnologist.com H:612.895.09367 W:612.883.6484 > http://www.mp3.com/steve_murphy icq:58230291 > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net

I met the same problem with Slackware 4.0 when trying to compile PHP as DSO. After whole day exploring what could be done, I finally surrendered. Then I compiled PHP as static object and everything works OK.

attached mail follows:


Steve Murphy wrote:

> I have RedHat 6.1. I installed Apache rpm's from RH6.1. I installed > MySQL RPM's. I followed all instructions in the INSTALL.REDHAT file and > read every FAQ I can find. > > I tested apache and it works fine. > > I compiled php with MySQL support and /etc as the php3.ini location. I > then checked out the httpd.conf file amd the other. I then issued a > restart to the /etc/rc.d/init.d/httpd and it reported OK and OK for stop > and start. When I tried apache, nothing. Another restart yeilded > [Failed] on shutdown and [OK] on startup - no messages anywhere. > > Again, nothing from apache. And same messages from restart. > > I comment out the php lines in httpd.conf and apache works just fine. > > Am I missing something? Where can I look? I looked at apache error > log, /var/log/messages, etc. and found nothing. > > Is there anything I can do to track down the problem? > > Any help would be greatly appreciated. I've uninstalled, reinstalled, > and recompiled everything I can and it all stays the same. > > -Steve > > -- > ------------------------------------------------------------------- > Steve.MurphyTechnologist.com H:612.895.09367 W:612.883.6484 > http://www.mp3.com/steve_murphy icq:58230291 > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net

After tracing the httpd with "strace -f", I found it catches SIGSEGV. No logging at all,

attached mail follows:


Hi, I'm trying to create a banner image and write it to a file. For some reason the Text is being created backwards (reading right to left) and upside down. On top of this it appears to be keen on writing this from top to bottom and even rotating so the string is left to right (but still unreadable) leads to the string being cut off - make the background taller and any cut off text magically appears to the right.

I've attached an example image for your convienience.

Here's the bit of code that's giving me that image:

$dimensions = IMAGETTFBBOX(48,0,"/mnt/satan/windows/fonts/impact.ttf", "The Graham Society"); Header("Content-type: image/gif"); $imageLength = $dimensions[2]; $imageHeight = $dimensions[6]; $imageLength = $imageLength +10; // A bit of clearance if ($imageHeight < 0) {$imageHeight = $imageHeight * -1;} //If it's negative make it positive $imageHeight = $imageHeight + 5;

$img = imagecreate(400,100); $imgBackground = imagecolorallocate($img,255,255,255); $imgTextColour = imagecolorallocate($img,0,0,0); IMAGEFILL($img,0,0,$imgBackground); IMAGETTFTEXT($img,24,270,10,20,$imgTextColour,"/mnt/satan/windows/fonts/impact.ttf", "The Graham Society"); ImageGif($img, "/htdocs/$socDirName/banner.gif");

My initial idea is that GD swapped it's X,Y system somewhere along the line but I had a quick scan at GD's site and came up with nought. There are two versions of GD on my system: 1.2 and 1.5 and it's my understanding (courtesy of a higher power) that I'm using version 1.2.

Any ideas folks?

David Dumenil


attached mail follows:


> I'm trying to create a banner image and write it to a file. For some > reason the Text is being created backwards (reading right to left) and > upside down. On top of this it appears to be keen on writing this from top > to bottom and even rotating so the string is left to right (but still > unreadable) leads to the string being cut off - make the background taller > and any cut off text magically appears to the right. > > I've attached an example image for your convienience.

You must be using an old version of PHP. Or you upgraded your TTF library without properly recompiling PHP. This problem happens when PHP thinks you have an older freetype library than the one you actually have.

-Rasmus

attached mail follows:


On Wed, Mar 15, 2000 at 03:45:51PM -0200, Manuel Lemos wrote: > Hello Sascha, > > On 15-Mar-00 14:31:17, you wrote: > > >> Wouldn't it be better for us that post on the list if the list was > >> configured so that the replies only go back to the list and not also > >> to the poster? > > >We cannot do anything about people's broken software. qmail/ezmlm > >employs VERP which should ensure that automatic replies are > >delivered to the list server. > > That's not accurate. VERP only ensure that return-path is set to the list > server address, but the list still sets the Reply-to: header to the > original poster. > > > >Unfortunately, some (too many) people are allowed to write broken > >software which does not respect Internet standards. > > I agree that these hand-coded mail bouncers and auto-responders are not > honouring the Return-path header as they should but rather the Reply-to > header. But we have to live with them the way they are. This wouldn't be > a problem if the list would not set explicitly the Reply-To header to the > original poster. > > So, I ask you to please take off that Reply-to header option or if possible > make it a Cc: option if you really insist that real answers should go the > real poster.

I don't know which list you are talking about, but it is definitely not any list hosted at lists.php.net.

- Sascha

attached mail follows:


Hi List...

I am a regular user of PHP version 3.0 with mySQL.

I have concatenated two string with a delimeter and let's say that's a '+' and now I want to getback the two strings and the code should be in PHP. How do I do that ?. Is there any split function in PHP ?. If so in which version does it comes and how effective is that one ?.

Any suggestions / ideas are welcome !.

Thanks in advance.

--
Regards,
TV Karthick Kumar
Aspire Systems, India
karthickaspiresys.com

attached mail follows:


use explode() see the manual

-----Original Message----- From: TV Karthick Kumar [mailto:karthickaspiresys.com] Sent: Thursday, March 16, 2000 12:12 PM To: PHPMailing List Subject: [PHP3] Split function

Hi List...

I am a regular user of PHP version 3.0 with mySQL.

I have concatenated two string with a delimeter and let's say that's a '+' and now I want to getback the two strings and the code should be in PHP. How do I do that ?. Is there any split function in PHP ?. If so in which version does it comes and how effective is that one ?.

Any suggestions / ideas are welcome !.

Thanks in advance.

--
Regards,
TV Karthick Kumar
Aspire Systems, India
karthickaspiresys.com

-- PHP 3 Mailing List <http://www.php.net/> To unsubscribe, send an empty message to php3-unsubscribelists.php.net To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 To contact the list administrators, e-mail: php-list-adminlists.php.net

attached mail follows:


> I am a regular user of PHP version 3.0 with mySQL. > > I have concatenated two string with a delimeter and let's say that's > a '+' and now I want to getback the two strings and the code should be > in PHP. How do I do that ?. Is there any split function in PHP ?. If so > in which version does it comes and how effective is that one ?. > > Any suggestions / ideas are welcome !.

You could check the documentation. There is indeed a function called split(), although you probably want explode() in this case. The docs will tell you all about them.

-Rasmus

attached mail follows:


I would prefer to use 'explode' to extract the strings

Go to http://www.php.net you will find lot of examples.

On Thu, 16 March 2000, TV Karthick Kumar wrote:

> > Hi List... > > I am a regular user of PHP version 3.0 with mySQL. > > I have concatenated two string with a delimeter and let's say that's > a '+' and now I want to getback the two strings and the code should be > in PHP. How do I do that ?. Is there any split function in PHP ?. If so > in which version does it comes and how effective is that one ?. > > Any suggestions / ideas are welcome !. > > Thanks in advance. > > -- > Regards, > TV Karthick Kumar > Aspire Systems, India > karthickaspiresys.com > > > > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net

http://www.unni.com If there is a WILL there is a WAY ______________________________________________________________ Go Cubs Email - The Official Email Service of the Chicago Cubs Get your free Go Cubs Email account http://www.cubs.com

attached mail follows:


Hi List..

As I came to know that many of them are using Postgresql database in the recent times.

But as I tried downloading - in it's homepage - only the 'tar' (*nix) version were available and as I am using only Windows 9x version, I need the Windows version of the Postgresql db.

Where will I get a copy of it for using it with PHP ?.

Thanx in advance !.

Regards, TV Karthick Kumar Aspire Systems, India karthickaspiresys.com

attached mail follows:


> As I came to know that many of them are using Postgresql database in > the recent times. > > But as I tried downloading - in it's homepage - only the 'tar' > (*nix) version were available and as I am using only Windows 9x version, > I need the Windows version of the Postgresql db. > > Where will I get a copy of it for using it with PHP ?.

I don't think it exists. Linux is only about a 15-minute install away.

-Rasmus

attached mail follows:


----- Original Message ----- From: Farkas Csaba <wolfpcspecial.hu> To: angyalosi zsuzsa <azsuzsahungaropharma.hu>; <asalamonhu.tuv.com>; Bobály László Béla <bobalypcspecial.hu>; Csilla Kivandorlo Szabo <csiszahotmail.com>; Dynamic Gergő <dynamictiszanet.hu>; Erdélyi Tamás <erdelyitiszanet.hu>; Fonyi Tamás <fotasopronbutor.hu>; Gabi Gergely <9302892sms.pgsm.hu>; Gaboca <kgabocafreemail.c3.hu>; Gergely Gabi <ggergelypgsm.hu>; Gyorgy Szekeres <szekeresnepsy.szote.u-szeged.hu>; Gyöngyi <galgyonpcspecial.hu>; Hajas Tamas <softcontacttiszanet.hu>; Igor <igorpcspecial.hu>; <katacsmkik.tiszanet.hu>; Király Zoltan <zsuzsa.angyalosyhungaropharma.hu>; Kovácsné Szilágyi Katalin <kovacsnecsmkik.tiszanet.hu>; Kukoda Hajnalka <h535177stud.u-szeged.hu>; Laci <9803834sms.pgsm.hu>; Marschall Peter <marschallmail.tiszanet.hu>; Meco Services Kft <mecomail.tiszanet.hu>; <orsi19freemail.hu>; Pilling János <pilljannet.sote.hu>; Rec Sent: Thursday, March 16, 2000 9:17 AM Subject: Fw: Érdemes megpróbálni...

> > Eredeti uzenet Vetek Janos Pecs. > > Figyelem, nem csalas, nem amitas! > Ma kaptam a kovetkezo hirt: a Microsoft es az AOL a vilag legnagyobb > internet tarsasaga.Hogy biztosak legyenek a dolgukban, valamint > teszteljek, > hogy az Internet-Explorer valoban a legtobbet hasznalt program, a > Microsoft > es az AOL egy > E-mail Beta tesztet inditott el.Ha baratoknak ismerosoknek > tovabbkuldik > ezt > a levelet ,akkor a Microsoft ezt a tenyt 2 heten belul > figyeli.Minden > egyes > szemely utan a Microsoft 245,00 USD-t fizet.Minden egyes szemely > utan > akinek > On elkuldi, es a cimzett tovabbkuldi a Microsoft 243,00 Usd-t es > minden > harmadik szemelynek,aki megkapja 241,00 usd-t fizet.Ket heten belul > a > Microsoft jelentkezik > a cimert es kuld Onnek egy csekket. > Magam is azt hittem,hogy ez atveres,de ket hettel azutan, hogy a > partnerem > megkapta ezt a mailt, felvettel vele e kapcsolatot a Microsoft es > par > > napon > belul kapott egy csekker 24.800.-Usd-rol. > Vaalszoljon mielott lejar a test.Ha valaki ilyesmit megengedhet > maganak > az > Bill Gates.Ez is az o marketingstrategiaja. > Sok sikert kivanok. > A proba megeri ! > > - att1.eml > > > >> > > > >> > > > >> > > > > > > > > > > > > > > > > > > > > > > >

attached mail follows:


Hi.. list

I'm a new comer here..

i had a problem using PHP to connect Oracle 8.0 i need to get a record count of a record set without fetch them..

so.. there are function method just like in postgree function pg_numrow()

thanks..

-darwis-

--------------------------------------------- visit : kakilimapiksi.itb.ac.id ---------------------------------------------

attached mail follows:


> i had a problem using PHP to connect Oracle 8.0 > i need to get a record count of a record set without fetch them.. > > so.. there are function method just like in postgree function > > pg_numrow()

I don't think there is one for Oracle, but why not try issuing a separate query to get the information? You could always go "select count(*) as num_records from your_table where your_criteria" and then fetch just that result set. I think it's always a good idea to check how many rows would be returned before actually selecting and fetching them. Or trying to display the result in an HTML table... I've made that particular mistake too many times to take any chances.

/Mia*

attached mail follows:


[I'm re-posting this, I got a bounce message and I don't think it got through the first time]

Can anybody help with this one? Using PHP 4.0B2:

I've turned on full error reporting with error_reporting() and I get the message:

Warning: SQL safe mode in effect - ignoring host/user/password information in /htdocs/test/checkbm.php on line 18

$con=mysql_connect("localhost","myusername","mypassword");

I've checked phpinfo() and it says:

safe_mode Off Off sql.safe_mode Off Off safe_mode_exec_dir 1 1

I don't think my service provider (vservers) allows access to php.ini, though I could be wrong.

Thanks in advance for any clues,

Ivan Lucas

attached mail follows:


I have the following code:

$Test = include("template.php");

$File = fopen("testdirectory/test.html", "w+"); fwrite($File, $Test);

What I'd like to achieve with this is to assign an include to a variable and the write that variable to a file. What happens when I run this is that the file is created, but it is 0k in size. Is there a way to make this work or a better way to achieve the same results?

Thanks in advance,

Josh Hoover

attached mail follows:


Use file() instead of include().

- Tim http://www.phptemplates.org

> I have the following code: > > $Test = include("template.php"); > > $File = fopen("testdirectory/test.html", "w+"); > fwrite($File, $Test);

attached mail follows:


Hi.

include() does not work like that. Please see http://www.zend.com/manual/function.include.php for more information. It has changed in PHP4 so I might be out on a limb here but I still don't think it's possible to do what you want to do by using include().

Best regards, Martin Edelius

Spirex Digital Design -------------------------------- www: http://www.spirex.se Mail: martin.edeliusspirex.se Phone: +46-31-514651, 0708-113711 Fax: +46-31-514331 Aröds Industriväg 3c S-422 43 Hisings Backa -------------------------------- If I haven't got back to you or done what I'm supposed to, let me know again as I have too much to do for my own good...

----- Original Message ----- From: "Joshua Hoover" <plan10compfactory.com> To: <php3lists.php.net> Sent: Thursday, March 16, 2000 2:28 PM Subject: [PHP3] Writing an include to a file?

> I have the following code: > > $Test = include("template.php"); > > $File = fopen("testdirectory/test.html", "w+"); > fwrite($File, $Test); > > What I'd like to achieve with this is to assign an include to a variable and > the write that variable to a file. What happens when I run this is that the > file is created, but it is 0k in size. Is there a way to make this work or > a better way to achieve the same results? > > Thanks in advance, > > Josh Hoover > > > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net > >

attached mail follows:


If I use file(), that won't process the PHP code I have in that file will it? Essentially I want to be able to pass variables to this template and then write it to a file.

Thanks for the help!

-Josh Hoover

> Use file() instead of include(). > > - Tim > http://www.phptemplates.org > > >> I have the following code: >> >> $Test = include("template.php"); >> >> $File = fopen("testdirectory/test.html", "w+"); >> fwrite($File, $Test); > >

attached mail follows:


Take a look at the eval($string) function, which will interpret $string as PHP code. So you'd have to read the file into a variable and then eval() it. This - I think - spawns another PHP interpreter so it isn't very efficient. Also, if this is an include file with embedded <?php...?> tags & HTML & newlines, you might have to do some preprocessing first.

But, fopen() can open pages under the web doc root, so you could do something like

$FileData = ''; $FileHandle = fopen('http://path/to/file/template.php');

while ($line = fread($FileHandle, 65535)) { $FileData .= $line; }

...

fwrite($SomeOtherFileHandle, $FileData);

...of course, add appropriate error checking.

DISCLAIMER: No caffiene has hit my brain yet, linear thought/coherence not fully achieved.

- steve

At 9:25 AM -0500 3/16/00, Joshua Hoover wrote: >If I use file(), that won't process the PHP code I have in that file will >it? Essentially I want to be able to pass variables to this template and >then write it to a file. > >Thanks for the help! > >-Josh Hoover > > > Use file() instead of include(). > > > > - Tim > > http://www.phptemplates.org > > > > > >> I have the following code: > >> > >> $Test = include("template.php"); > >> > >> $File = fopen("testdirectory/test.html", "w+"); > >> fwrite($File, $Test); > > > > >

+---------------- Splurk! Glort! Klikrunk! Ploip! Katoong!---------------+ | Steve Edberg University of California, Davis | | sbedbergucdavis.edu (530)754-9127 | | Computer Consultant http://aesric.ucdavis.edu/ | +------------------ Don Martin 18 May 1931 - 7 Jan 2000 -----------------+

attached mail follows:


Hi all, The below is my problem with FTP, any solution.

Thanks

>Knowledge Based wrote: > > > > HI Nathan, > > I am not quite sure how ftp_nlist() works, I reffered the php manual, > > accoring to the manual, should retrun a zero when no list is found and >an > > array when files found. When I try printing the array, there is only one > > column with no value in it. I am stuck here. > > Any suggestions, it will be great if you can send me a small example if > > possible. > > > > ______________________________________________________ > > Get Your Private, Free Email at http://www.hotmail.com

______________________________________________________ Get Your Private, Free Email at http://www.hotmail.com

attached mail follows:


What is better: include 'segment.php3'; or require('segment.php3'); ?

______________________________________________________ Moritz Petersen mailto:modmmp.net

attached mail follows:


Depends on what you want to do and how you want your code to behave. See http://www.zend.com/manual/function.include.php for more information on how the two functions differ.

Best regards, Martin Edelius

Spirex Digital Design -------------------------------- www: http://www.spirex.se Mail: martin.edeliusspirex.se Phone: +46-31-514651, 0708-113711 Fax: +46-31-514331 Aröds Industriväg 3c S-422 43 Hisings Backa -------------------------------- If I haven't got back to you or done what I'm supposed to, let me know again as I have too much to do for my own good...

----- Original Message ----- From: "Moritz Petersen" <moritz.petersendisc-us.de> To: <php3lists.php.net> Sent: Thursday, March 16, 2000 3:18 PM Subject: [PHP3] include / require

> What is better: > include 'segment.php3'; > or > require('segment.php3'); > ? > > ______________________________________________________ > Moritz Petersen > mailto:modmmp.net > > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net > >

attached mail follows:


At 15:26 16.03.2000, Martin Edelius wrote: >Depends on what you want to do and how you want your code to behave. See >http://www.zend.com/manual/function.include.php for more information on how >the two functions differ.

afaik, (since php4) require is processed by the precompiler, include by a runtime-compiler.

mit freundlichen Grüßen,

Gregor Welters

----------------------------- Welters PC-Service Grafenberger Allee 81 40237 Düsseldorf Germany Tel: 0211/9660096 Mobil: 0173/2776469 Fax: 0211/9660093 mailto: gwelterswelters.de look at: http://www.welters.de

attached mail follows:


Hi All

Is there such a thing as an editor for PHP scripts that checks syntax etc? If not what would be a good editor to get? I'm just starting in PHP and would like to get the best tools for the job.

Thanks

Nick Steele

attached mail follows:


This question really needs to go into the weekly post/FAQ ....

Please search the archive http://www.php.net/mailsearch.php3

This comes up several times a week, there is plenty to look at in the archive.

Hank

-----Original Message----- From: Nick Steele [mailto:nsarchsky.com] Sent: Thursday, March 16, 2000 9:51 AM To: PHP Mailing List Subject: [PHP3] PHP editor

Hi All

Is there such a thing as an editor for PHP scripts that checks syntax etc? If not what would be a good editor to get? I'm just starting in PHP and would like to get the best tools for the job.

Thanks

Nick Steele

--
PHP 3 Mailing List <http://www.php.net/>
To unsubscribe, send an empty message to php3-unsubscribelists.php.net
To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net
To search the mailing list archive, go to:
http://www.php.net/mailsearch.php3
To contact the list administrators, e-mail: php-list-adminlists.php.net

attached mail follows:


Newer members to the list (like myself) don't know that these questions have been asked. Perhaps I'll create a page that has some information on the text editors out there that people could reference. I did a bit of research on UltraEdit, EditPlus and NoteTab Pro and how they handle PHP functions and syntax.

Chris VanderPoel http://www.wlvrn.com (aviation, history and gaming stuff)

TEXT EDITORS THAT HANDLE PHP - EditPlus (http://www.editplus.com) - UltraEdit (http://www.ultraedit.com) - NoteTab Pro (http://www.notetab.com)

| -----Original Message----- | From: Henry F. Marquardt [mailto:hankyerpso.net] | Sent: Thursday, March 16, 2000 8:31 AM | To: Nick Steele; PHP Mailing List | Subject: RE: [PHP3] PHP editor | | | This question really needs to go into the weekly post/FAQ .... | | Please search the archive http://www.php.net/mailsearch.php3 | | This comes up several times a week, there is plenty to look at in the | archive. | | Hank | | -----Original Message----- | From: Nick Steele [mailto:nsarchsky.com] | Sent: Thursday, March 16, 2000 9:51 AM | To: PHP Mailing List | Subject: [PHP3] PHP editor | | | Hi All | | Is there such a thing as an editor for PHP scripts that checks syntax | etc? If not what would be a good editor to get? I'm just starting in PHP | and would like to get the best tools for the job. | | Thanks | | Nick Steele | | -- | PHP 3 Mailing List <http://www.php.net/> | To unsubscribe, send an empty message to php3-unsubscribelists.php.net | To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net | To search the mailing list archive, go to: | http://www.php.net/mailsearch.php3 | To contact the list administrators, e-mail: php-list-adminlists.php.net | | | -- | PHP 3 Mailing List <http://www.php.net/> | To unsubscribe, send an empty message to php3-unsubscribelists.php.net | To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net | To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 To contact the list administrators, e-mail: php-list-adminlists.php.net

attached mail follows:


This has already been done.

Check out http://www.itworks.demon.co.uk/phpeditors.htm for more complete information.

Robert Zwink

> -----Original Message----- > From: Chris VanderPoel [mailto:wlvrnwlvrn.com] > Sent: Thursday, March 16, 2000 11:55 AM > To: PHP Mailing List > Subject: RE: [PHP3] PHP editor > > > Newer members to the list (like myself) don't know that these > questions have > been asked. Perhaps I'll create a page that has some information on the > text editors out there that people could reference. I did a bit > of research > on UltraEdit, EditPlus and NoteTab Pro and how they handle PHP > functions and > syntax. > > Chris VanderPoel > http://www.wlvrn.com (aviation, history and gaming stuff) > > TEXT EDITORS THAT HANDLE PHP > - EditPlus (http://www.editplus.com) > - UltraEdit (http://www.ultraedit.com) > - NoteTab Pro (http://www.notetab.com) > > > | -----Original Message----- > | From: Henry F. Marquardt [mailto:hankyerpso.net] > | Sent: Thursday, March 16, 2000 8:31 AM > | To: Nick Steele; PHP Mailing List > | Subject: RE: [PHP3] PHP editor > | > | > | This question really needs to go into the weekly post/FAQ .... > | > | Please search the archive http://www.php.net/mailsearch.php3 > | > | This comes up several times a week, there is plenty to look at in the > | archive. > | > | Hank > | > | -----Original Message----- > | From: Nick Steele [mailto:nsarchsky.com] > | Sent: Thursday, March 16, 2000 9:51 AM > | To: PHP Mailing List > | Subject: [PHP3] PHP editor > | > | > | Hi All > | > | Is there such a thing as an editor for PHP scripts that checks syntax > | etc? If not what would be a good editor to get? I'm just starting in PHP > | and would like to get the best tools for the job. > | > | Thanks > | > | Nick Steele > | > | -- > | PHP 3 Mailing List <http://www.php.net/> > | To unsubscribe, send an empty message to php3-unsubscribelists.php.net > | To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > | To search the mailing list archive, go to: > | http://www.php.net/mailsearch.php3 > | To contact the list administrators, e-mail: php-list-adminlists.php.net > | > | > | -- > | PHP 3 Mailing List <http://www.php.net/> > | To unsubscribe, send an empty message to php3-unsubscribelists.php.net > | To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > | To search the mailing list archive, go to: > http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net > > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 To contact the list administrators, e-mail: php-list-adminlists.php.net

attached mail follows:


I've spent many hours the last several days looking everywhere I possibly could to find out what is going on but to no avail. I'm hoping that someone here on the list has experienced something like this and has found a solution.

Here is my problem:

I have 2 pages. Page 1 contains a form that a user fills out and upon submission of that form, the user is directed to Page 2. The Form Action for page 1 is $PHP_SELF so that I can validate the data the user entered into the form elements. Here is the code that validates the form then if everything is correct, takes them on to the next page:

(from page 1)

if( isset( $submit )) { $result = $form->validate( "ok" ); if( $result == "ok" ) { $created_by = urlencode( $broker_name ); // echo "PHP_AUTH_USER: $PHP_AUTH_USER<br>\n"; header( "Location: page2.php3" ); exit(); } HTMLHeader( $pageTitle ); showErrorMessage($result); }

When I uncomment out the echoing of the value for PHP_AUTH_USER, I get what I expect to see - the user-id.

Here are the first 2 lines of page 2:

(from page 2)

<script language="php"> echo "PHP_AUTH_USER: $PHP_AUTH_USER<br>\n";

Again, these are the very first 2 lines of the file. When the value of $PHP_AUTH_USER is echoed out here, there is no value. So somewhere between the header( "Location:..." ) call and the start of PHP pasing page 2, the value is lost and I haven't a clue as to why. I use this same logic (having the form come back to itself for validation and then redirecting to another page) all throughout my site and the value of PHP_AUTH_USER isn't deleted. But here it is and it is becoming very frustrating. Any clues, tips, suggestions as to what I could look at would be most appreciated. Thank you for your time.

Chris

attached mail follows:


On a related note, I've tried using unset to kill the value of PHP_AUTH_USER if someone tries to login and fails. I want them to be able to try again. Right now, the browser has to be closed in order for someone to try logging in again.

Any ideas?

Chris

::::::::::::::::::::::::::::::::::::::::::::::::::::::::: Chris Murtland Studio Moxie, LLC www.studiomoxie.com 336.773.1684 800.707.2367 fax 62384610 ICQ

attached mail follows:


> On a related note, I've tried using unset to kill the value of PHP_AUTH_USER > if someone tries to login and fails. I want them to be able to try again. > Right now, the browser has to be closed in order for someone to try logging > in again. > > Any ideas?

That's how http authentication works. The browser sends the auth headers on every request. There is no way to tell a browser to stop doing that.

-Rasmus

attached mail follows:


hello, I am using oracle 8i with php3-3.0.15 on Suse 6.3 linux. I have the tnsnames entry and oracle seems to work great. I compiled php with oracle support and that went fine..but i am getting these errors when i run a php script with oci calls:

Warning: oci8_open_server: Error while trying to retrieve text for error ORA-12154 in /usr/local/httpd/htdocs/shopdocs/myfile.php3 on line 5

Warning: oci8_open_server: Error while trying to retrieve text for error ORA-12154 in /usr/local/httpd/htdocs/shopdocs/myfile.php3 on line 6

Warning: OCIParse: invalid connection 0 in /usr/local/httpd/htdocs/shopdocs/myfile.php3 on line 10

Warning: OCIExecute: invalid statement 0 in /usr/local/httpd/htdocs/shopdocs/myfile.php3 on line 11

created table

Warning: OCIParse: invalid connection 0 in /usr/local/httpd/htdocs/shopdocs/myfile.php3 on line 22

Warning: OCIExecute: invalid statement 0 in /usr/local/httpd/htdocs/shopdocs/myfile.php3 on line 23

inserted hallo

any ideas would help

thanks

brad

attached mail follows:


Hi all:

I have a PHP script where I need to open two different connections to the same database, and issue different queries in each one of them. I had thought that I'd be able to differentiate between them using the index value returned by pg_connect, like in, say:

$conn=pg_connect("", "", "", "", "database1"); $connbis=pg_connect("", "", "", "", "database1");

/* Do something with $connbis pg_close($connbis);

/* Do something here with $conn pg_close($conn);

But the problem is that the value returned by $conn and $connbis is the same, so when I issue the first pg_close, it actually closes *both* connections. Why does this happen? How can I fix it? (Please CC me, since I'm not currently subbed to the list).

Paulo Jan. DDnet.

attached mail follows:


Hello,

I have a very simple basic question. I am trying to figure out what PHP runs on. I know that it can run on Unix / Linux. Can you run it on Windows NT Server?? If so, what Web Servers does it support, or is it independant of the Web Server running on the Server??

I am looking at using Windows NT Server 4.0, and Internet Information Server (IIS) 4.0 Will PHP work in the configuration?? If so, do I just download the binaries and install them?

Thanks,

Hugh

attached mail follows:


At 12:02 PM 3/16/00 -0500, Hugh Cowan wrote: >Hello, > >I have a very simple basic question. I am trying to figure out what PHP >runs on. I know that it can run on Unix / Linux. Can you run it on >Windows NT Server?? If so, what Web Servers does it support, or is it >independant of the Web Server running on the Server?? > >I am looking at using Windows NT Server 4.0, and Internet Information >Server (IIS) 4.0 Will PHP work in the configuration?? If so, do I just >download the binaries and install them?

that will work. get the binary.. 4.0beta supports ISAPI which will work with IIS, so you don't have to use the cgi version.

>Thanks, > >Hugh > > >-- >PHP 3 Mailing List <http://www.php.net/> >To unsubscribe, send an empty message to php3-unsubscribelists.php.net >To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net >To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 >To contact the list administrators, e-mail: php-list-adminlists.php.net

attached mail follows:


Yep,

Runs fine in that configuration. I've only done binary installs as I don't drag around an MS development kit with me, but I've 4 clients on that config 2 running into MSSQL and 2 running MySql.

Hank

-----Original Message----- From: Hugh Cowan [mailto:hwcowanhotmail.com] Sent: Thursday, March 16, 2000 11:02 AM To: php3lists.php.net Subject: [PHP3] Windows NT - IIS

Hello,

I have a very simple basic question. I am trying to figure out what PHP runs on. I know that it can run on Unix / Linux. Can you run it on Windows NT Server?? If so, what Web Servers does it support, or is it independant of the Web Server running on the Server??

I am looking at using Windows NT Server 4.0, and Internet Information Server (IIS) 4.0 Will PHP work in the configuration?? If so, do I just download the binaries and install them?

Thanks,

Hugh

--
PHP 3 Mailing List <http://www.php.net/>
To unsubscribe, send an empty message to php3-unsubscribelists.php.net
To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net
To search the mailing list archive, go to:
http://www.php.net/mailsearch.php3
To contact the list administrators, e-mail: php-list-adminlists.php.net

attached mail follows:


the php4 beta readme only talks about: + Installation Notes for IIS 4.0 + Installation Notes for Microsoft PWS 4.0

in regard to ISAPI. I have Win98, and I know Apache supports ISAPI. Would this combination work? What I'm trying to do is keep the development tree on my laptop as close to the unix layout as possible in order to use Apache's PHP directives to control each virtual server. PHP's cgi version doesn't give me that control, ie. include directories etc.

Thanks

attached mail follows:


i have solaris 7 and gcc. i make :

for php3 : configure --with-apache=../apache_1.3. --enable-track-vars 12 --enable-sysvshm --with-ldap with-imap make make install

all good

mbut for apache :i make configure --prefix=/usr/local/apache --activate-module=src/modules/php3/libphp3.a good but after at the make : # make ===> src ===> src/regex <=== src/regex ===> src/os/unix <=== src/os/unix ===> src/ap <=== src/ap ===> src/main <=== src/main ===> src/lib ===> src/lib/expat-lite <=== src/lib/expat-lite <=== src/lib ===> src/modules ===> src/modules/standard <=== src/modules/standard ===> src/modules/php3 <=== src/modules/php3 <=== src/modules gcc -c -I./os/unix -I./include -DSOLARIS2=270 -DUSE_HSREGEX -DUSE_EXPAT -I./lib/expat-lite -DNO_DL_NEEDED `./apaci` modules.c gcc -c -I./os/unix -I./include -DSOLARIS2=270 -DUSE_HSREGEX -DUSE_EXPAT -I./lib/expat-lite -DNO_DL_NEEDED `./apaci` buildmark.c gcc -DSOLARIS2=270 -DUSE_HSREGEX -DUSE_EXPAT -I./lib/expat-lite -DNO_DL_NEEDED `./apaci` \ -o httpd buildmark.o modules.o modules/php3/libphp3.a modules/standard/libstandard.a main/libmain.a ./os/unix/libos.a ap/libap.a regex/libregex.a lib/expat-lite/libexpat.a -lgd -Lmodules/php3 -L../modules/php3 -L../../modules/php3 -lmodphp3 -lpam -lm -ldl -lsocket -lnsl -lresolv -lsocket -lnsl -lgdbm non défini premier référencé symbole dans le fichier ldap_count_values_len modules/php3/libphp3.a(ldap.o) ldap_get_dn modules/php3/libphp3.a(ldap.o) ldap_err2string modules/php3/libphp3.a(ldap.o) ldap_delete_s modules/php3/libphp3.a(ldap.o) ldap_first_entry modules/php3/libphp3.a(ldap.o) ldap_add_s modules/php3/libphp3.a(ldap.o) ldap_next_attribute modules/php3/libphp3.a(ldap.o) ldap_perror modules/php3/libphp3.a(ldap.o) ldap_value_free modules/php3/libphp3.a(ldap.o) ldap_explode_dn modules/php3/libphp3.a(ldap.o) ldap_get_values_len modules/php3/libphp3.a(ldap.o) ldap_modify_s modules/php3/libphp3.a(ldap.o) ldap_search_s modules/php3/libphp3.a(ldap.o) ldap_open modules/php3/libphp3.a(ldap.o) ldap_count_values modules/php3/libphp3.a(ldap.o) ldap_unbind_s modules/php3/libphp3.a(ldap.o) ldap_bind_s modules/php3/libphp3.a(ldap.o) ldap_msgfree modules/php3/libphp3.a(ldap.o) ldap_first_attribute modules/php3/libphp3.a(ldap.o) ldap_value_free_len modules/php3/libphp3.a(ldap.o) ldap_dn2ufn modules/php3/libphp3.a(ldap.o) ldap_next_entry modules/php3/libphp3.a(ldap.o) ldap_get_values modules/php3/libphp3.a(ldap.o) ldap_count_entries modules/php3/libphp3.a(ldap.o) ld: fatal : Erreurs de référence aux symboles. Aucun résultat écrit dans httpd collect2: ld returned 1 exit status *** Error code 1 make: Fatal error: Command failed for target `target_static' Current working directory /reseau/www/apache_1.3.12/src *** Error code 1 make: Fatal error: Command failed for target `build-std' Current working directory /reseau/www/apache_1.3.12 *** Error code 1 make: Fatal error: Command failed for target `build'

what is the error ?? thank 's

attached mail follows:


[...] >As bad as >it was this time, the number of bounced messages was only 1 for each >original posting. Can you imagine if instead of receiving one email for >each one you had posted to the list, you would have instead received one for >EVERY MESSAGE POSTED TO THE LIST in the last 6 months?

And don't forget that a reply from an autoresponder *sent to the list* is also sent to the mail address which is autoresponding. If it's badly configured and responds to his own response ... Everybody say 'endless loop'. ------------------------------------ Ricardo Luis Fuertes Mulet - r.fuertesmillorsoft.es Dep. de Programación - MillorSoft, S.L. +34 73 711203 - Fax +34 73 711218

attached mail follows:


Hi, I need to get the rank of every field in the table, for example for each city what the rank of the population, I wrote a query that return an array like this : Berlin 2293 Brookfield 2968 Brimfield 3001 Boxborough 3343 looks like the population is sorted in ASC, how can I use from this table an associative array to have this work done. For example I am looking when I have the city "Boxborough", I have to output "1th", I meant this city is ranked first for population. Thanks

______________________________________________________ Get Your Private, Free Email at http://www.hotmail.com

attached mail follows:


Hi Sufi,

There might be better way to do this, but you can use the following as well

1) Connect to database 2) run the query (use order by desc, instead of Asc) 3) get number of rows

for($i=0;$i<$numberofrows;$i++){ $rec=fetch the row from the result; echo $rec->cityname; echo ' '; echo $i; switch ($i){ case 1: echo 'st';echo '<br>';break; case 2: echo 'nd';echo '<br>';break; case 3: echo 'rd';echo '<br>';break; default: echo 'th';echo '<br>'; } }

On Thu, 16 March 2000, "sufi malak" wrote:

> > Hi, I need to get the rank of every field in the table, for example > for each city what the rank of the population, I wrote a query that > return an array like this : > Berlin 2293 Brookfield 2968 Brimfield 3001 Boxborough 3343 > looks like the population is sorted in ASC, how can I use from this table an > associative array to have this work done. > For example I am looking when I have the city "Boxborough", I have to output > "1th", I meant this city is ranked first for population. > Thanks > > ______________________________________________________ > Get Your Private, Free Email at http://www.hotmail.com > > > -- > PHP 3 Mailing List <http://www.php.net/> > To unsubscribe, send an empty message to php3-unsubscribelists.php.net > To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net > To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 > To contact the list administrators, e-mail: php-list-adminlists.php.net

http://www.unni.com If there is a WILL there is a WAY ______________________________________________________________ Go Cubs Email - The Official Email Service of the Chicago Cubs Get your free Go Cubs Email account http://www.cubs.com

attached mail follows:


Forgive me I am new to PHP and MySQL, but I am building a webpage that is connected to a MySQL database, and I would like to make it so I have a form where I type in the ID number from a particular record in the database and view only a few fields from that one record. Is there a quick and easy way to do this?

-Justin justinbigcity.nu

attached mail follows:


I think this is more an sql quesiton:

$query="select field1, field2 from yourtable where IDnum='$idnum'"; if(!($result=mysql_query($query))) { echo "Error processing query"; } else { Do your routine; }

I'm assuming you set $idnum in your form as the lookup field and that you want to display only field1 and field2 ... notice you don't need to 'select' the item that you're keying off of or any other fields in the table.

I did of course omit the connection and table selection stuff as well.

Hope that helps.

Hank

-----Original Message----- From: Justin [mailto:justinbigcity.nu] Sent: Thursday, March 16, 2000 11:25 AM To: php3lists.php.net Subject: [PHP3] View Records by ID#

Forgive me I am new to PHP and MySQL, but I am building a webpage that is connected to a MySQL database, and I would like to make it so I have a form where I type in the ID number from a particular record in the database and view only a few fields from that one record. Is there a quick and easy way to do this?

-Justin justinbigcity.nu

--
PHP 3 Mailing List <http://www.php.net/>
To unsubscribe, send an empty message to php3-unsubscribelists.php.net
To subscribe to the digest, e-mail: php3-digest-subscribelists.php.net
To search the mailing list archive, go to:
http://www.php.net/mailsearch.php3
To contact the list administrators, e-mail: php-list-adminlists.php.net

attached mail follows:


Is anyone here a TWIG user with apache/mysql/php4? If so, I'd love to bounce some questions off you without troubling the list. The twig documentation is a bit "thin." 8-)

Thanks in advance,

Chris

Chris Mauritz ritzimntv.com Independent Music Network

attached mail follows:


I am doing some online testing that involves having the user enter a word into a text box and then checking to see if the entered word matches a list of 4 possible word answers.

ENTERED =====> POSSIBLE ANSWERS investment =====> investment, fudiary,broker,derivative

The problem is that the person may mispell one of the possible answer (e.g., invesment). A human could look at this answer and quickly tell that it the person knew what the answer was but misspelled the word.

I would like my program to act like a human by overlooking spelling mistakes to see that a mispelled answer is correct.

Can anyone give me advice on:

Question 1: What is the best way to this within PHP? The metaphone function, the similiar_text function, some combination?

Question 2: What is the best way to do this? MySQL functions? Fuzzy matching?

Regards, Paul Meagher, Content Engineer