|
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 25 Apr 2000 04:57:40 -0000 Issue 1628
From: php3-digest-help
lists.php.netDate: Mon Apr 24 2000 - 23:57:40 CDT
- Next message: php3-digest-help
lists.php.net: "php3 Digest 25 Apr 2000 23:54:04 -0000 Issue 1629"
- Previous message: php3-digest-help
lists.php.net: "php3 Digest 24 Apr 2000 16:57:44 -0000 Issue 1627"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
php3 Digest 25 Apr 2000 04:57:40 -0000 Issue 1628
Topics (messages 87426 through 87521):
Research
87426 by: "Erdal Yazicioglu" <eyazicioglu
mindspring.com>
87428 by: Matt McClanahan <cardinal
dodds.net>
Still more ld signal 11 errors
87427 by: "Sergio A. Murillo" <sam
marrder.com>
My ?
87429 by: "SANIsoft" <tarique
nagpur.dot.net.in>
87443 by: Perry J. Blalock <badger
pongo.org>
list of exec return codes?
87430 by: "Paul Evad - ISO Productions Inc." <paul
isoproductions.com>
Getting the HTTP_REFERER (Apache and PHP)
87431 by: Donald Undeen <dundee
gator.net>
87432 by: "Craig Vincent" <webmaster
webdream.com>
87435 by: Donald Undeen <dundee
gator.net>
87436 by: Rasmus Lerdorf <rasmus
php.net>
Get the title of a website
87433 by: "Leon Mergen" <leon
solatis.com>
87434 by: idban secandri <idban
satunet.com>
87439 by: Zak Greant <zak
freeimages.com>
87441 by: "Leon Mergen" <leon
solatis.com>
How count Items in array
87437 by: gunnar
vortex.is (Gunnar Kristjansson)
87438 by: Rasmus Lerdorf <rasmus
php.net>
D/B shopping cart
87440 by: charette
sneezy.org
Linking from web page on server to Visual Basic application
87442 by: Alexis Birkill <snoopy
alexisbirkill.com>
migration from mySQL to Oracle
87444 by: "Adam Powell" <adam
powlex.com>
87445 by: "Adam Powell" <adam
powlex.com>
FilePro -- Please help!
87446 by: Dan Mostert <dan
delhitel.com>
87453 by: Zak Greant <zak
freeimages.com>
Multiple File Uploads
87447 by: Mark Lo <markloky
netvigator.com>
87448 by: "Richard Heyes" <php
heyes-computing.net>
programmer
87449 by: "Bruno Mosconi" <bmosconi
fnazca.com.br>
[Fwd: Re: [PHP3] Linking from web page on server to Visual Basic application]
87450 by: Ricardo Núñez <rinunez
usb.ve>
87472 by: Ricardo Núñez <rinunez
usb.ve>
Sybase RPM?
87451 by: "Sergio A. Murillo" <sam
marrder.com>
searching files for keywords
87452 by: Ricardo Núñez <rinunez
usb.ve>
87454 by: Zak Greant <zak
freeimages.com>
How to count items in array ... update
87455 by: gunnar
vortex.is (Gunnar Kristjansson)
87458 by: Michael Pohl <michael
newtopia.com>
87460 by: Zak Greant <zak
freeimages.com>
PCRE backreferences
87456 by: David L Rubin <rubin
redconnect.net>
Newbie; PWS4, W98
87457 by: "Pierre Mercan" <pmercan
wanadoo.fr>
[PHP-DEV] Re: [PHP3] PHP Speed Optimization
87459 by: Ron Chmara <ron
opus1.com>
87470 by: "Faisal Nasim" <faisal
nasim.org>
87495 by: Ron Chmara <ron
opus1.com>
PHP Speed Optimization
87461 by: Ron Chmara <ron
opus1.com>
cheap databases 4 windows...
87462 by: "William X. Kerber" <dgoa
ou.edu>
87486 by: "PHPList" <phplist
wowmation.com>
87508 by: Bob Lutz <php3
lutz-engr.com>
dynamic forms and reading them in
87463 by: Russ Demarest <demarest
thinkquest.org>
87464 by: "Boget, Chris" <chris
wild.net>
PHP3 based majordomo archiv?
87465 by: Philipp Flesch <flesch
informatik.tu-muenchen.de>
possibly dangerous behaviour in OCI API
87466 by: "Adam Powell" <adam
powlex.com>
Linking from web page on server to Visual Basic application]
87467 by: Alexis Birkill <snoopy
alexisbirkill.com>
"Clean" a MySQL Insert (from "' and anything nasty)
87468 by: Duccio Gasparri <dgasparri
tin.it>
87477 by: Marcus D Hanwell <linux
cryos.net>
New in PHP4 - COM support
87469 by: "Boget, Chris" <chris
wild.net>
87471 by: Zak Greant <zak
freeimages.com>
87475 by: "Boget, Chris" <chris
wild.net>
87480 by: Sterling Hughes <sterling
designmultimedia.com>
87484 by: Zak Greant <zak
freeimages.com>
87491 by: Patrick Shafer <PDShafer-phx
netsolutionsllc.com>
87509 by: Bob Lutz <php3
lutz-engr.com>
[PHP-DEV] Compiling PHP3 with IBM DB2 support
87473 by: "Thomas E. Ruth" <truth
ichaos.com>
[PHP-DEV] Re: [PHP3] Re: [PHP-DEV] Re: [PHP3] PHP Speed Optimization
87474 by: Andi Gutmans <andi
zend.com>
php3 and sybase
87476 by: "Doug Poland" <dpoland
execpc.com>
sql query
87478 by: Glenn MacGregor <gtm
oracom.com>
87481 by: "Jonathan Griffin" <jgriffin
mmind.net>
87483 by: Zak Greant <zak
freeimages.com>
PHP's method for connecting to MS SQL Server?
87479 by: "Jonathan Griffin" <jgriffin
mmind.net>
TEST ! PLEASE IGNORE!
87482 by: "the illusive one" <illusive
illusives.tiddlywinks>
addslashes C source?
87485 by: "Mitch Vincent" <mitch
venux.net>
87496 by: Doug Semig <dougslist
c3net.net>
87497 by: David L Rubin <rubin
redconnect.net>
PHP4 and .htaccess
87487 by: Kevin Waterson <kevin
kevin.oceania.net>
87520 by: Devon Young <webmaster
abreathoflife.com>
Fonts and PHP
87488 by: Joshua Hoover <plan10
compfactory.com>
Newbie Help
87489 by: Robert Hough <rch
qserve.net>
87492 by: Robert Hough <rch
qserve.net>
87493 by: Zak Greant <zak
freeimages.com>
87498 by: Doug Semig <dougslist
c3net.net>
87499 by: Doug Semig <dougslist
c3net.net>
Win32 Apache+PHP Authentication
87490 by: digit4l
ns.sympatico.ca (John Marr)
mod_php3.c
87494 by: David Daugherty <doc
wcug.wwu.edu>
FW: Need Help On ODBC Connect To Visual Foxpro.
87500 by: chchar <chchar
mcms.com>
session variables in memory
87501 by: vader seventy-seven <vader77
excite.com>
87502 by: Rasmus Lerdorf <rasmus
php.net>
87503 by: "Peter Kocks" <peter.kocks
baygate.com>
project suggestions ?
87504 by: Mikhail Avrekh <ami
ocf.Berkeley.EDU>
ForceType based on URL
87505 by: "Waldo L. Jaquith" <waldo
waldo.net>
Executing a script in another script
87506 by: Thomas Merlin <merlin
club-internet.fr>
preg_match_all help?
87507 by: mocha_php <mocha_php
yahoo.com>
Where is PHPMySQL Admin?
87510 by: Diana Cassady <diana
vivaladata.com>
87511 by: Michael Pohl <michael
newtopia.com>
87519 by: "TV Karthick Kumar" <tvkarthick
mailops.com>
HELP!HOW TO POP OUT 'SAVEAS' ?
87512 by: hendry <hendry
mcms.com>
Generating table rows
87513 by: "David Loke" <dihuei
theoikoses.com>
include() from another domain
87514 by: Clint Skidmore <skidmore
netidea.com>
87521 by: Doug Semig <dougslist
c3net.net>
fsockopen() parameter count error??
87515 by: CDitty <mail
redhotsweeps.com>
87516 by: Matt Allen <Matt
LinuxWorx.com.au>
87517 by: CDitty <mail
redhotsweeps.com>
Dynamic downloading of zipped files
87518 by: dataweaver
netzero.net
Administrivia:
To subscribe to the digest, e-mail:
php3-digest-subscribe
lists.php.net
To unsubscribe from the digest, e-mail:
php3-digest-unsubscribe
lists.php.net
To post to the list, e-mail:
php3
lists.php.net
----------------------------------------------------------------------
attached mail follows:
I am doing a paper on impacts of PHP on e-commerce. Please fell free to answer and email me back if you have any opinions.
Questions.
1- Why PHP?
2- What are the advantages of PHP on other languages?
3- How PHP handles the following topics?
a- Web database intergration
b- File parsing
I will be contunuie to post questions.
Thank you
Erdal Yazicioglu
Kennesaw State University
MS in Information Technology
404 248 0226
http://eyazicioglu.home.mindspring.com
attached mail follows:
On Mon, 24 Apr 2000, Erdal Yazicioglu wrote:
> I am doing a paper on impacts of PHP on e-commerce. Please fell free to
> answer and email me back if you have any opinions.
>
> Questions.
>
> 1- Why PHP?
> 2- What are the advantages of PHP on other languages?
> 3- How PHP handles the following topics?
> a- Web database intergration
> b- File parsing
>
> I will be contunuie to post questions.
The answers to all of these, and much more, are at your fingertips in the
mailing list archives. We have, at length, covered these topics multiple
times, and people have posted a lot of high quality explainations and
arguments to address your questions.
http://www.geocrawler.com/lists/3/Web/1/0/
Some suggested search terms:
why php
advantages of php
php vs (asp, jsp, coldfusion, whatever. We've done it all)
file parsing
I'm not sure what you mean by 3.b, Web database integration. Could you
give an example of what exactly you're looking to accomplish? PHP's
database support is quite extensive, so I'm sure it's an easy one to
answer.
Matt
attached mail follows:
I still get the ld sig 11 errors! I did a memory test with memtest 2.x and
the memory was ok. I have tried the same instalation on a Compaq Proliant
3000R, RedHat 6.2 with the same result. I also tried on a dual procesor
machine with RH 6.1 and nothing. And on a 500Mhz PIII, 128MB, 9GB U-SCSI
RedHat 6.2 with the
same result. Please help...
I'm trying to compile php-3-0-16 with the following options
with-apxs, with-mysql, with-pgsql, with-sybase-ct, with-xml,
with-zlib,libtiff,ligbjpeg , -with-openssl. I tried with pdflib 3.0 but
PHP does not like it so i removed this last option.
The configure script goes well and most of the make also, but as soon as
the make calls the apxs script I get the message,
collect2: ld was terminated with signal 11
I had compiled apache previously so i would have a fresh apxs script.
So I decided on a static library. The php make went sith no problems but
in the apache amke I get the same error as soon as it tries to compile the
libphp.a file.
Apache-1.3.12 has the following options.
with-openssl, with-rsa, with-mm (memory manager 1.0.2) with-mod_ssl, and
of course with php.
It;s really frustrating.
I know there is a third option compiling as a cgi-bin, but not sure how to
do it. I can;t beleive nobody has had the same problems so it must be
something I;m doing wrong.
Does anyone have a similar build the can send me... Will this work?
Thank all for your help.
Sergio
attached mail follows:
Hi Ashwin,
working on those lines - basically the Idea is to have small inc files which
are included on the basis of user preferences - variables which are stored
as a string, and then exploded
the auth, perm and sess are being managed by PHPLib
Tarique
=======================================
Creating not just Web Sites but Web Applications
http://www.sanisoft-india.com
Search Engine for Nagpur http://nagpurcity.net
=======================================
-----Original Message-----
From: Ashwin Kutty <Ashwin.Kutty
Dal.Ca>
To: php3
lists.php.net <php3
lists.php.net>
Date: Monday, April 24, 2000 3:56 PM
Subject: [PHP3] My ?
>Hi,
>
>I was wondering if there was something already out there (in terms of
code),
>that lets users setup a My WebPage interface.. i.e. something along the
lines of
>My Netscape or My Yahoo etc..
>
>Thanks..
>
>--
>Ashwin
>kutty..
>Systems Administrator
>Dalhousie University Libraries
>
>
>
>
>--
>PHP 3 Mailing List <http://www.php.net/>
>To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net
>To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
>
attached mail follows:
I saw something like this on www.freshmeat.net ... just do a search for "php," browse through the listing, and you'll find the one.
hth
> Hi,
> I was wondering if there was something already out there
> (in terms of code),
> that lets users setup a My WebPage interface.. i.e.
> something along the lines of
> My Netscape or My Yahoo etc..
> Thanks..
> --
> Ashwin
> kutty..
> Systems Administrator
> Dalhousie University Libraries
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to
> php3-unsubscribe
lists.php.net
> To subscribe to the digest, e-mail:
> php3-digest-subscribe
lists.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-admin
lists.php.net
attached mail follows:
A function mysteriously stopped working for me this weekend.
I was calling a perl script using the exec() statement (have been
doing so happily for months).
Now, I'm not getting any results from it.. though the script has not
changed, and it still functions properly from the command line.
I checked the 'return code' and it is 127, which doesn't tell me
much. Does anyone know of a list on the net of what standard error
codes are?
We did recompile the machines kernel recently... would that have effected it?
I also tried the backtick operator... no difference.
If the error code 127 has any meaning... it may help shed some light
on the problem.
Thanks for any and all help.
_ paul
-------------ISO FileMaker Magazine for FileMaker users----------------
Paul Evad - Webmaster ISO Productions Inc. (925) 454-0187
paul
isoproductions.com 4049 First St. Ste. 141
http://www.isoproductions.com Livermore, CA USA 94550
***********************************************************************
Want Everything for FileMaker Pro? Get Volume III of the everything CD!
http://www.everythingcd.com/filemaker/
Want to stay on top of FileMaker News?
http://www.fmnewswire.com
Another free service brought to the FileMaker Community by
ISO Productions Inc.
---------------"We're reducing your learning curve"------------------
attached mail follows:
hmm, I complied that module in, can see that it's in my list of loaded modules
in my phpinfo() page, yet the
referer variable doesn't exist still.
If that's compiled in, then what could be keeping php from knowing about it?
Don Undeen
dundee
gator.net
Craig Vincent wrote:
> > I can't seem to get the $GLOBALS["HTTP_REFERER"] variable to be set.
> >
> > I've complied in mod_log_referer in apache, I'm using PHP4RC1, using
> > Dynamic Libraries (mod_so complied into apache). I can get both up and
> > running, but when I do php_info, the HTTP_REFERER isn't listed under
> > "HTTP Request Headers." I can look at my referer_log, and see that the
> > referer is being logged at least "some " of the time.
>
> It's not the mod_log_referer module you need...it's the mod_env module that
> must be compiled into Apache to pass environment variables to php & cgi
> scripts.
>
> Sincerely,
>
> Craig Vincent
attached mail follows:
> hmm, I complied that module in, can see that it's in my list of
> loaded modules
> in my phpinfo() page, yet the
> referer variable doesn't exist still.
> If that's compiled in, then what could be keeping php from
> knowing about it?
Doh!!! I know why...it's because when you're accessing the phpinfo() page
it's because the browser currently doesn't have an HTTP_REFERER...so because
the field is blank PHP omits it.
If you really wish to test simply create another online page with a link
simply going to the phpinfo page...then go through the newly created
page....I'll bet you the HTTP_REFERER variable shows up then :)
Sincerely,
Craig Vincent
attached mail follows:
Craig Vincent wrote:
> > hmm, I complied that module in, can see that it's in my list of
> > loaded modules
> > in my phpinfo() page, yet the
> > referer variable doesn't exist still.
> > If that's compiled in, then what could be keeping php from
> > knowing about it?
>
> Doh!!! I know why...it's because when you're accessing the phpinfo() page
> it's because the browser currently doesn't have an HTTP_REFERER...so because
> the field is blank PHP omits it.
>
> If you really wish to test simply create another online page with a link
> simply going to the phpinfo page...then go through the newly created
> page....I'll bet you the HTTP_REFERER variable shows up then :)
>
> Sincerely,
>
> Craig Vincent
You are the MAN! Though it would've been nice to SEE the blank variable, so I'd
know that it at least was LOOKING for it....
Don
attached mail follows:
> You are the MAN! Though it would've been nice to SEE the blank variable, so I'd
> know that it at least was LOOKING for it....
HTTP_REFERER is something that is set by the web server. PHP doesn't know
which variables any particular web server might set. So, a blank variable
list would be infinitely long.
-Rasmus
attached mail follows:
How can I fetch the title of a website?
I do know about the $metatags = get_meta_tags("$url",1); command, but I need to fetch the title of the website.
Carpe diem,
- Leon (ICQ # 55677353)
attached mail follows:
see and modify it for your own good
http://www.zend.com/codex.php?id=98&single=1
> Leon Mergen wrote:
>
> How can I fetch the title of a website?
>
> I do know about the $metatags = get_meta_tags("$url",1); command, but
> I need to fetch the title of the website.
>
>
> Carpe diem,
>
> - Leon (ICQ # 55677353)
-- idban secandri || idbansatunet.com Q : why php? A : bcoz not asp! Q : why not perl A : bcoz no need 755 Q : why 755 A : bcoz if i set 000 you can ask anymore!
attached mail follows:
At 07:53 PM 4/24/00 +0200, Leon Mergen wrote: >How can I fetch the title of a website? > >I do know about the $metatags = get_meta_tags("$url",1); command, but I >need to fetch the title of the website.
Hi Leon and List!
First, use fopen and fgets to read data in from the url. Then use a regular expression to match the title tags.
Here is some quick and dirty untested code:
/* open a read only stream to a website */ $url_pointer = fopen ('http://www.somesite.com', 'r');
/* make sure that your are not at the end of the file */ while (! feof ($url_pointer)) { /* grab 1k from the url */ $temp_line .= fgets ($url_pointer, 1024);
/* if the line has a closing title tag in it then exit the loop use case insensitive matching (stristr) */ if (stristr ($temp_line, '<\title>' )) break; }
/* find the title tags in $temp_line and extract the content that is between them use case-insensitive matching (eregi_replace) */ $title = eregi_replace ( '.*<title>(.*)<\title>', '\\1', $temp_line);
The are many, many ways to solve this problem - this is just one of the quicker examples to code.
Good Luck!
Zak
attached mail follows:
Thank you! I used this one :
$fp = fopen("$url", "r");
$build = ""; $flag = 0;
for ($i = 0; !feof($fp); $i++) {
$line = fgets($fp, 1024); if (eregi("<TITLE>", $line)) { $flag = 1; } if ($flag == 1) { $build = $build.$line; } if (eregi("</TITLE>", $line)) { $flag = 0; }
}
if ($build > ""): $build = eregi_replace("<TITLE>", "", $build); $build = eregi_replace("</TITLE>", "", $build); $build = trim($build); endif;
fclose($fp);
$title = $build;
Carpe diem,
- Leon (ICQ # 55677353)
-----Original Message-----
From: Zak Greant <zak
freeimages.com>
To: Leon Mergen <leon
solatis.com>; php3
lists.php.net <php3
lists.php.net>
Date: Monday, April 24, 2000 8:14 PM
Subject: Re: [PHP3] Get the title of a website
>At 07:53 PM 4/24/00 +0200, Leon Mergen wrote: >>How can I fetch the title of a website? >> >>I do know about the $metatags = get_meta_tags("$url",1); command, but I >>need to fetch the title of the website. > >Hi Leon and List! > >First, use fopen and fgets to read data in from the url. >Then use a regular expression to match the title tags. > >Here is some quick and dirty untested code: > >/* open a read only stream to a website */ >$url_pointer = fopen ('http://www.somesite.com', 'r'); > >/* make sure that your are not at the end of the file */ >while (! feof ($url_pointer)) > { > /* grab 1k from the url */ > $temp_line .= fgets ($url_pointer, 1024); > > /* if the line has a closing title tag in it then exit the loop > use case insensitive matching (stristr) > */ > if (stristr ($temp_line, '<\title>' )) > break; > } > >/* find the title tags in $temp_line and extract the content that is >between them > use case-insensitive matching (eregi_replace) >*/ >$title = eregi_replace ( '.*<title>(.*)<\title>', '\\1', $temp_line); > >The are many, many ways to solve this problem - this is just one of the >quicker examples to code. > > >Good Luck! > >Zak
attached mail follows:
How can I count all the Items in array ??
Gunnar
gunnar
vortex.is
attached mail follows:
count()
On Mon, 24 Apr 2000, Gunnar Kristjansson wrote:
> How can I count all the Items in array ??
>
> Gunnar
> gunnar
vortex.is
>
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
>
>
attached mail follows:
>1. Most users IP addresses change when they log off the internet.
Heck, users can have multiple IPs on one page request! Take a look at what AOL does - I've seen multiple IPs, one per http GET connection, for one user because of their multiple cache strategy. Don't depend on an IP for anything other than identifying a particular connection for a particular request. Other than that, with dynamic proxies/caches/whathaveyous, all bets are off. Unique sessionids & time-out hashes are about as good as you can get with a stateless protocol.
Mark Charette
sneezy.org
attached mail follows:
Hi,
I am pretty new to PHP, but a friend suggested that it would be possible to do this via php.
I am running a IIS server on my home computer to display a series of pages. I have already configured the server to process PHP files correctly.
I want to have a button of some kind on a page that can be viewed by a client on the internet, that, when pushed, sends a message to a visual basic program running on the same computer as the server.
It strikes me that this should be reasonably easy to do, but I am unsure on even the basics. If you have any ideas, could you please let me know.
Many thanks,
Alexis.
attached mail follows:
paulo
paulo.com.br
16-Apr-2000 11:04
It would be nice if we could have a mode to return the row as an object, just like mysql_fetch_object(), what do you think? It would be a lot easier to migrate from mysql to oracle.... :)
Do you think this would be possible to write? Is there a function out there that duplicates this behaviour at all (preferably returning the object with lower-case column names.
Im trying to convert my code from mySQL to Oracle with as little hassle as possible, but there are some things in there like mysql_fetch_object that arent converting easily.
Thanks, Adam
attached mail follows:
Sorry, I am referring to the OCIFetchInto function :)
Adam
----- Original Message -----
From: Adam Powell
To: php3
lists.php.net
Sent: Monday, April 24, 2000 11:36 AM
Subject: [PHP3] migration from mySQL to Oracle
paulo
paulo.com.br
16-Apr-2000 11:04
It would be nice if we could have a mode to return the row as an object, just like mysql_fetch_object(), what do you think? It would be a lot easier to migrate from mysql to oracle.... :)
Do you think this would be possible to write? Is there a function out there that duplicates this behaviour at all (preferably returning the object with lower-case column names.
Im trying to convert my code from mySQL to Oracle with as little hassle as possible, but there are some things in there like mysql_fetch_object that arent converting easily.
Thanks, Adam
attached mail follows:
Hello Everybody, This is my third try on this topic because of no response. Because of PHP's growth, I'm again appealing to the list for help, in case someone new knows the answer.
I have read all I can find on PHP and filePro's relationship, and I do have it working - sort of. According to the PHP manual and my PHP book "Core PHP Programming" I'm using every filePro function available, but it's still not doing what I'd like it to. Using the function to connect to a map file works, but I'm not sure how useful that is. I can see how many fields are in the map file and see what they contain, but that's pretty useless when it comes to looking at data. I would like to be able to see the data that is in the database, not the data that defines the database. Maybe I'm misinterpreting what the filePro functions are for?
Thanks, Dan
attached mail follows:
Dan wrote: >Hello Everybody, >This is my third try on this topic because of no response. Because of >PHP's growth, I'm again appealing to the list for help, in case someone >new knows the answer. > >I have read all I can find on PHP and filePro's relationship, and I do >have it working - sort of. According to the PHP manual and my PHP book >"Core PHP Programming" I'm using every filePro function available, but >it's still not doing what I'd like it to. Using the function to connect >to a map file works, but I'm not sure how useful that is. I can see how >many fields are in the map file and see what they contain, but that's >pretty useless when it comes to looking at data. I would like to be >able to see the data that is in the database, not the data that defines >the database. Maybe I'm misinterpreting what the filePro functions are >for?
Hi Dan,
I do not use filePro or have access to it, but I will give it a shot! :)
I would guess that this code would dump the data out of the database:
$directory = 'directory_name';
// Connect to the database filepro ($directory) or die ("Sorry I could not connect to a filePro database in $directory");
// Find the number of columns & rows $fields = filepro_fieldcount(); $rows = filepro_rowcount();
print '<table>';
/* Loop through the rows in the database */ for ($current_row=1; $current_row < $rows; ++$current_row ) { print '<tr>'; /* Loop through the fields in the database */ for ($current_field=1; $current_field < $fields; ++$current_field ) { // Display a field $field = filepro_retrieve ($current_row, $current_field); print "<td>$field</td>"; } print '</tr>'; }
print '<table>';
Cross your fingers - and please let me know if this works!
Zak
attached mail follows:
hi,
using two or more <input type="file" name="firstone"> <input type="file" name="secondone">....so on...
hope this is what u r looking for. mark
Jay Lepore wrote:
> Has anybody seen a script that allows for more than one file to be uploaded but using only one submit button?
>
> I have been trying painfully to pull that one off.
>
> Sincerely,
>
> Jay Lepore
> Cox Enterprises
> TrackerOnline
> 1-800-543-8085 Ext#205
> mailto:Jay.Lepore
trackeronline.com
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
attached mail follows:
> Has anybody seen a script that allows for more than one file to > be uploaded but using only one submit button? > > I have been trying painfully to pull that one off.
Simply have two file inputs in your form:
<INPUT TYPE="FILE" NAME="file1"> <INPUT TYPE="FILE" NAME="file2">
When submited the php script will have the usual four variables for each file uploaded, eg:
$file1, $file1_name, $file1_type, $file1_size and $file2, $file2_name, $file2_type, $file2_size.
HTH
-- Richard Heyes
attached mail follows:
I´m looking for a *good* Brazilian PHP programmer!
later, Bruno
attached mail follows:
-------- Original Message --------
Subject: Re: [PHP3] Linking from web page on server to Visual Basic
application
Date: Mon, 24 Apr 2000 14:49:05 -0400
From: Ricardo Núñez <rinunez
usb.ve>
Organization: Universidad Simón Bolívar
To: Alexis Birkill <snoopy
alexisbirkill.com>
References: <3904902E.1722F551
alexisbirkill.com>
Alexis Birkill wrote:
>
> Hi,
>
> I am pretty new to PHP, but a friend suggested that it would be possible
> to do this via php.
>
> I am running a IIS server on my home computer to display a series of
> pages. I have already configured the server to process PHP files
> correctly.
>
> I want to have a button of some kind on a page that can be viewed by a
> client on the internet, that, when pushed, sends a message to a visual
> basic program running on the same computer as the server.
>
> It strikes me that this should be reasonably easy to do, but I am unsure
> on even the basics. If you have any ideas, could you please let me
> know.
>
> Many thanks,
>
> Alexis.
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
Take a look at http://www.php.net/manual/language.variables.external.php
Note: I understand that in Windows you have to run PHP through CGI.
I hope it helps,
--
Ing. Ricardo Núñez
Encargado del Servidor www.dst.usb.ve (prof.usb.ve)
Dirección de Servicios Telemáticos
E-Mail: rinunez
usb.ve
attached mail follows:
-------- Original Message --------
Subject: Re: [PHP3] Linking from web page on server to Visual Basic
application
Date: Mon, 24 Apr 2000 17:12:31 -0400
From: Ricardo Núñez <rinunez
usb.ve>
Organization: Universidad Simón Bolívar
To: Alexis Birkill <snoopy
alexisbirkill.com>
References: <3904902E.1722F551
alexisbirkill.com>
<39049721.BA38DDD6
usb.ve> <3904B1E6.1E94AB57
alexisbirkill.com>
Alexis Birkill wrote: > > > Take a look at http://www.php.net/manual/language.variables.external.php > > > > Note: I understand that in Windows you have to run PHP through CGI. > > > > I hope it helps, > > Sorry, I'm still confused.. I don't understand how I can use this to link into a > visual basic application. All I want to do is to have a form on a page that, when > the user clicks the submit button, runs the application on the server and passes > the form variables to it. > > Alexis.
Hi,
I think that you do not understand very well how forms work. You should learn that before trying to program that in php3. In fact, php is NOT necessary if all that you want is to have a HTML FORM file that submits to a VB application.
In the URL I told you, there is an example that I will change a little bit:
Part of a HTML file (let's call it index.html):
<form action="/cgi/vb_app.exe" method="post"> Name: <input type="text" name="name_prueba"><br> <input type="submit"> </form>
This will pass the variable "name_prueba" in the URL to the VB executable. In the URL because I understand in Windows IIS you should do that via CGI (I am a Unix WebMaster). You should find out how you analyze the URL in the VB application.
I am not telling you that there are others ways to get to the goal.
Still in doubt?
Ing. Ricardo Núñez
Encargado del Servidor www.dst.usb.ve (prof.usb.ve)
Dirección de Servicios Telemáticos
E-Mail: rinunez
usb.ve
attached mail follows:
is there a sybase-ct rpm file for php?
Sergio
attached mail follows:
Mike Sears wrote: > > one of the projects I'm working on requires me to check the /etc/passwd file > for existing entries. now I can open the file easy enough, but I'm not sure > as to how about actually searching the file for specific keywords.
I advise you to read about sed and awk (perhaps cut).
>
> Matrix
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
Bye,
--
Ing. Ricardo Núñez
Encargado del Servidor www.dst.usb.ve (prof.usb.ve)
Dirección de Servicios Telemáticos
E-Mail: rinunez
usb.ve
attached mail follows:
Ricardo Núñez wrote: >Mike Sears wrote: > > > > one of the projects I'm working on requires me to check the /etc/passwd > file > > for existing entries. now I can open the file easy enough, but I'm not sure > > as to how about actually searching the file for specific keywords. > >I advise you to read about sed and awk (perhaps cut).
Check out the regular expression functions. Also take a look at strcmp in the string functions.
Good Luck!
Zak
attached mail follows:
This do's not work .. How do I get it to work <?
$array =array("a"=>"orange","b"=>"banana","c"=>"apple"); count($array); printf("%s",$array["a"]); printf("This is it:%i",count($array)); printf("This is it:%i",sizeof($array)); ?>
attached mail follows:
On Mon, 24 Apr 2000, Gunnar Kristjansson wrote:
> This do's not work .. How do I get it to work > <? > > $array ray("a"=>"orange","b"=>"banana","c"=>"apple"); > count($array); > printf("%s",$array["a"]); > printf("This is it:%i",count($array)); > printf("This is it:%i",sizeof($array)); > ?>
Change %i to %d or %s. Also, the bareline "count($array);" is extraneous.
michael
attached mail follows:
At 07:49 PM 4/24/00 +0000, Gunnar Kristjansson wrote: ><? > >$array =array("a"=>"orange","b"=>"banana","c"=>"apple"); >count($array); > printf("%s",$array["a"]); > printf("This is it:%i",count($array)); > printf("This is it:%i",sizeof($array)); > ?>
Hi Gunnar,
The PHP implementation of printf is different from the C implementation. While %i is a valid conversion specification in C, but in PHP it has no value.
Try using %d or %s instead.
Also, when you are having a problem with a function not behaving as you think it should, try to place the function in the simplest environment possible for testing.
With this previous problem, just doing a print count ($array) would have gotten you on the right track for debugging.
HTH,
Zak
attached mail follows:
On Sat, 22 Apr 2000, Adrian Kubala wrote:
> I can't get any kind of simple backreferences in PHP 4rc1. "/(a)\1/" doesn't > match "aa"... what the heck am I doing wrong?
You have to use two backslashes: preg_replace(..., "\\1...");
david
-- David L Rubin rubinredconnect.net http://63.71.143.54:8080/~rubin gpg key fingerprint: 07D9 BB21 433F 0178 383B 1982 C972 284F E353 FBA9
attached mail follows:
I installed php3 on PWS4 under W98 and have the following message (translated) whenever I try to download a page on the IE5 threw the server : The specified CGI application didn't work sending uncomplete HTTP Headers headers sent are : PHP: Unable to parse configuration file.
Any Idea ?
attached mail follows:
Faisal Nasim wrote: > | > Try not using functions. > | > You will get approximately 30+ % more speed. > This doesn't make much difference.... its an interpreted language,
er... there are differences between PHP3 and PHP4, no? User-defined functions are often slower in PHP3. The advantage they have is in *coding*, not parsing. I havn't done the headwork on PHP4 yet, but in three.. oy. Part of the problem is that PHP users tend to think less lines of code is faster (not the case, the two are unrelated in issues of speed), and rather than making the fastest code, they tend to concentrate on making the _smallest_ code. This is assuming a bycycle is faster than a Concorde SST, because it's more compact. :-)
> and the only speed loss I can think about is the initialization of > another pool to store local variables.
Say you have 30 user-built functions in *one* file, 200 lines of code. Depending on your code base/version, if those are called 10 times per page, you need to include that code for the parser (file call), and then as you go through the page, it substitutes out the function code.... plus you've added 20 useless functions of overhead for *every* parsed page. (Hence, the speed differences between 3 and 4, and the problem with using functions in 3. They *will* bog your execution down)
Lots and lots of overhead in that. If you can strip excess functions out, and speed is your goal, by all means, dump them over the side as fast as you can, and explicitly code using PHP's internal functions. Try two or three variants on your code, to see if, for example, you could get a faster result from a printf or an echo, a faster loop by only testing (if/case) under a smaller set of circumstances, and, if you can, avoid *ever* using requires or includes....
If that's still not fast enough, look into coding directly in C.
Now, of course, this all makes for faster execution, but your code can bloat like mad, or become almost unreadable. If the goal, however, is speed, that is a sacrifice you may *have* to make...
The author of "Real programmers don't use Pascal" once told me of a four line block of code that he worked on optimizing for three solid days. When he was done with it, it was 5 pages of code, and 4000% faster.... ugly as sin, but _fast_.
> I don't know for sure but I wonder if functions are saved in > the form of special tokens which don't need rechecking > for syntax once compiled... Zeev?
Well, this would be a PHP4 approach. Some of us are still using quite a bit of 3 (and still migrating from 2). :-) The rules changed a bit.
-Bop
-- Brought to you from boop!, the dual boot Linux/Win95 Compaq Presario 1625 laptop, currently running RedHat 6.1. Your bopping may vary.
attached mail follows:
| Say you have 30 user-built functions in *one* file, 200 lines of code. | Depending on your code base/version, if those are called 10 times per page, | you need to include that code for the parser (file call), and | then as you go through the page, it substitutes out the function code.... | plus you've added 20 useless functions of overhead for *every* | parsed page. (Hence, the speed differences between 3 and 4, and the | problem with using functions in 3. They *will* bog your execution | down)
Its there parsed once sitting in the memory, it doesn't actually substitute the function contents with the function call and then process is as if it was embedded in the code itself! Its done through a smart method.
| | Lots and lots of overhead in that. If you can strip excess functions | out, and speed is your goal, by all means, dump them over the side | as fast as you can, and explicitly code using PHP's internal | functions. Try two or three variants on your code, to see if, for | example, you could get a faster result from a printf or an echo, | a faster loop by only testing (if/case) under a smaller set of | circumstances, and, if you can, avoid *ever* using requires or | includes....
Seems like you have mixed C with PHP. PHP functions don't have overhead like C does (unless they are inline, the overhead is negligible, but its there!)
| | If that's still not fast enough, look into coding directly in | C.
You will choose PHP when you don't need C or you need rapid development with easy interchangeable database connectivity and blah blah.
| | Now, of course, this all makes for faster execution, but your | code can bloat like mad, or become almost unreadable. If the goal, | however, is speed, that is a sacrifice you may *have* to make...
This might look like a silly example, but it demonstrates the goal.
I don't use PHP3, sorry. This is done with PHP4 (CVS, not latest).
<?
for ( $i = 0 ; $i < 100000 ; $i++ )
$array[$i] = $i . "COOOOLLLLLLLLLLLLASDFWMASDFMASDGN#
";
$cnt = 0;
$now = time();
while ( $x = current ( $array ) )
{
if ( ++$cnt % 2 == 0 )
{
$cnt++;
$z .= "a"; $z .= "b"; $z .= "c"; $z .= "d"; $z .= "e";
$z .= "f"; $z .= "g"; $z .= "h"; $z .= "j"; $z .= "k";
$z .= "sdf"; $z .= "1"; $z .= "`"; $z .= "42"; $z .= "x";
$z .= "aasd"; $z .= "1a"; $z .= "23a"; $z = sin ( $i );
$z = strrev ( $z );
$z = join ( "!" , split ( "." , $z ) );
ereg ( "#
" , $z , $y );
next ( $array );
}
else
{
$y = soundex ( $z );
$a = similar_text ( $y , $z );
$b = sprintf ( "%.50f" , $z );
$z = strrev ( str_replace ( "a" , "b" , AddSlashes
( join ( "." , split ( "." , join ( "." , split ( "." ,
$z ) ) ) ) ) ) );
}
}
$n = time();
print "Took: ($now-$n) " . ( $n- $now ) . " seconds"; ?>
Three runs: All report 36 seconds.
<?
for ( $i = 0 ; $i < 100000 ; $i++ )
$array[$i] = $i . "COOOOLLLLLLLLLLLLASDFWMASDFMASDGN#
";
$cnt = 0; $now = time(); while ( $x = current ( $array ) ) { if ( ++$cnt % 2 == 0 ) func1(&$z); else func2(&$z);
next ( $array ); } $n = time();
print "Took: ($now-$n) " . ( $n- $now ) . " seconds";
function func1 ( $z )
{
$cnt++;
$z .= "a"; $z .= "b"; $z .= "c"; $z .= "d"; $z .= "e";
$z .= "f"; $z .= "g"; $z .= "h"; $z .= "j"; $z .= "k";
$z .= "sdf"; $z .= "1"; $z .= "`"; $z .= "42"; $z .= "x";
$z .= "aasd"; $z .= "1a"; $z .= "23a"; $z = sin ( $i );
$z = strrev ( $z );
$z = join ( "!" , split ( "." , $z ) );
ereg ( "#
" , $z , $y );
}
function func2 ( $z ) { $y = soundex ( $z ); $a = similar_text ( $y , $z ); $b = sprintf ( "%.50f" , $z ); $z = strrev ( str_replace ( "a" , "b" , AddSlashes ( join ( "." , split ( "." , join ( "." , split ( "." , $z ) ) ) ) ) ) ); } ?>
Three runs: All report 22 seconds.
On Windows 2000, 192 (128+64)mb of ram with all other programs shutdown for testing.....
What do you say now?
Thanks.
Faisal
attached mail follows:
Faisal Nasim wrote: > Seems like you have mixed C with PHP. PHP functions don't > have overhead like C does (unless they are inline, the overhead > is negligible, but its there!)
Hence, my emphasis in this thread between user generated functions, and PHP internal functions.... they are not the same, but user functions can (and do) suck up CPU and RAM when loading and parsing. Here, make a web page with 2Mb of unused functions in the page, and at the bottom: echo "Hello World";
Let me know if it's as fast as only one line, no excess function loading, echo "Hello World";
> | If that's still not fast enough, look into coding directly in > | C. > You will choose PHP when you don't need C or you need rapid > development with easy interchangeable database connectivity > and blah blah.
Right. Different tools for different jobs. If you need maximum execution speed, avoid PHP and use C. If you want rapid development and don't need blistering speed, PHP is great.
> | Now, of course, this all makes for faster execution, but your > | code can bloat like mad, or become almost unreadable. If the goal, > | however, is speed, that is a sacrifice you may *have* to make... > This might look like a silly example, but it demonstrates the goal. > I don't use PHP3, sorry. This is done with PHP4 (CVS, not latest).
Well then, for starters, perhaps you have not noticed my point about speeds in PHP3 vs. PHP4, and that speed coding isn't a one-size-fits-all metality. :-)
No functions, PHP 4, Win2000, custom code: > Three runs: All report 36 seconds.
With functions, PHP 4, Win2000, custom code: > Three runs: All report 22 seconds.
My speeds on PHP3.0.14:
Well, for starters, your functions won't run in PHP3, as you stuck them at the end of the file (and your have to delcare them in the beginning). So, I moved them up, and got: Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 19 bytes) in /www/functiontest2.php3 on line 3
Well, gee. What's the speed of dark? So:
I ran a 1/10 of the iterations (Dual 500Mhz, 512Mb of RAM, live ldap/mail/web/db server averaging 300-500 active users) on the PHP3 code, 14/14/14 seconds, for PHP3.
To run the second test, I had to move your functions to the top, and got 10/10/10 for the tests. In this code block, with a tenth of the iterations, in PHP3, functions would be the way to go. With half the iterations, I had 53/18/25/28 seconds *with* functions, 25/23/19 seconds without. Why the funky numbers? The server was getting bogged, with 66MB of http processes alone.
> On Windows 2000, 192 (128+64)mb of ram with all other programs shutdown > for testing..... > What do you say now?
I'd say that in PHP, on a large code blocks with many iterations, and enough RAM to hold the entire code block, you have demonstrated a case where functions *are* faster. What is faster in one case is _still_ not the fastest in all cases. I can write hundreds of poorly coded functions that would run horribly slow, or fast non-user-function code, just as you could write clean functions that ran better than explicitly invoked code.
Here's an example of how functions are resource draining:
(code from "Core PHP programming"): <? $start = time(); for($index = 0; $index < 1000000; $index++) { $value += (cos(time()%360)); }
$finish = time(); print("Elapsed Time: " . ($finish - $start) . " seconds<BR>\n"); ?>
And this <? function calculate($period) { return(cos(time()%$period)); } $start = time(); for($index = 0; $index < 1000000; $index++) { $value += calculate(360); } $finish = time(); print("Elapsed Time: " . ($finish - $start) . " seconds<BR>\n"); ?>
Running without a function, I consistantly get %50-80 of the speed I get _with_ a function.... and thats 20%-100% faster by _not_ using functions.... So, now we know that functions are faster, and slower? How fast does the abpove function code run on your PHP4 box?
-Bop-Bop
-- Brought to you from boop!, the dual boot Linux/Win95 Compaq Presario 1625 laptop, currently running RedHat 6.1. Your bopping may vary. Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 19 bytes) in /www/phptest/functiontest2.php3 on line 3
attached mail follows:
Jeff Strain wrote: > I have a Helpdesk Management Utility that I have written in PHP. It is over > 4 hundred lines of code.
Tiny. ;-)
> I was wondering to how to best optimize this. I > do have several lines of code that are repeated. My main questions are: > 1. How fast is a function contained with in a script.
Slower in 3 than in 4. Always a bit slower, how much you care about the speed loss is up to you. 3 milliseconds is nothing, unless it happens 180 times per page.....in which case those 3 milliseconds are a nightmare.
> 2. If a require is within an if statement is the code required only if > the if is true, or is it read on first scan of the document, and how fast is > a require.
Requires are _always_ read. Use includes if you're worried about RAM overhead, or stick the native code in there. Requires execute a little faster because they're always in the page, but it slows down the page when you have unused requires.
> 3. I am just curious because in today's world speed is needed, and if > someone lags for just a few seconds they can get frustrated and leave.
Yup. Optimize if it lags.
> 4. Is their a better way to speed up scripts.
Try other code. Get a faster machine. Use a fast database engine. If you're using 3, upgrade to 4.
> Right now the main problem with speed of the script is that it is still in > the development stage on my old laptop that has 32 megs of ram running > windows98, mssql server and pws.
You have a slow OS, a slow web server, very little RAM.... check your scripts on a fast OS, fast web server, with PHP loaded as part of the server. It can make a world of difference.
> The Microsoft products are a resource > hogs. I do want to know my options when I go to implement this.
Apache. On *nix. Well, that's not your _only_ option, but it's certainly the most supported one, with the fastest speed options available, AFAIK. Anybody running PHP on a 32cpu box yet?
> Also, where can I find Database performance information for MYSQL vs MSSQL > Server (as unbias as possible).
Unbiased? Heh. Not gonna happen. But I'll try to provide as little bias as possible: MSSQL is a drain if your primary goal is fast, simple, lookups and inserts.
That's because, as a database, MSSQL is designed to do much, much, more than mySQL. If you don't _need_ those features, they're getting in the way. Of course, MSSQL also is limited to slower machines and OS's, so for maximum growth and speed, you might want to look into a more portable engine anyways. If, however, you are limited to slower Win32 equipment, you really should bench _your_ data, with _your_ code.
The problem with unbiased DB testing is that there are so many variables that objective results are near impossible to get, so you really have to test with *your* specific variables (fields, data types, lookup/insert routines, etc.)....
Here's a general bench suite, showing where mySQL is good: http://www.mySQL.com/benchmark.html
One way of reading benchmarks is to remind yourself that they are showcasing their best speeds, and hiding their worst. So as long as you only use the banchmarked features, your data will scream. ;-)
Of course, if you need MSSQL features that mySQL doesn't have, then you're out of luck, without doing something like: a) Using the fast DB for the site input/reporting b) Using the robust DB for analysis, complex structures.
There's no reason to only use one if your speeds and features require two, Heck, some of my websites are using mySQL, btree'd files, PostgreSQL, and LDAP data engines, all for *one* set of transactions....
SO use what you need, when you need it!
-Bop
-- Brought to you from boop!, the dual boot Linux/Win95 Compaq Presario 1625 laptop, currently running RedHat 6.1. Your bopping may vary.
attached mail follows:
If you had to use a winNt machine and needed a cheap/powerful database, what would you use? Sybase, Mysql or Access?
Does Mysql for windows support more simultaneous connections than access? How about Sybase? Is sybase 4 windows better than Mysql 4 windows?
thanks for the info,
attached mail follows:
mySQL without a doubt :)
Ade
----- Original Message -----
From: William X. Kerber <dgoa
ou.edu>
To: PHPlist <php3
lists.php.net>
Sent: Monday, April 24, 2000 9:23 PM
Subject: [PHP3] cheap databases 4 windows...
> If you had to use a winNt machine and needed a cheap/powerful database,
what would
> you use? Sybase, Mysql or Access?
>
> Does Mysql for windows support more simultaneous connections than access?
> How about Sybase?
> Is sybase 4 windows better than Mysql 4 windows?
>
> thanks for the info,
>
>
>
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
>
attached mail follows:
NOT ACCESS!!! Multi-user it is not - more like multi-abuser :)
"William X. Kerber" wrote:
> If you had to use a winNt machine and needed a cheap/powerful database, what would
> you use? Sybase, Mysql or Access?
>
> Does Mysql for windows support more simultaneous connections than access?
> How about Sybase?
> Is sybase 4 windows better than Mysql 4 windows?
>
> thanks for the info,
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
attached mail follows:
I would like to know how people are implementing forms with a dynamic number of inputs. Is there an array in PHP i could call to? For example, I want to assign permissions based on a changing number of groups, and the page prints out the groups as checkboxes . How can I reference those fields coming back? Since there is a variable number of fields I need to create the variables (i.e. $group1, $group2) but I cannot get PHP to reference a variable I build in the script like:
while($x < $num){ if($group$x == on){ print " This group is on.<BR>\n"; }else{ print "This group is off<BR>\n"; } $x++; }
I hope this makes sense to someone. In perl it is easy, you references the form array. Can I do this in PHP and if so how?
thanks, Russ
attached mail follows:
> cannot get PHP to reference a variable I build in the script like: > while($x < $num){ > if($group$x == on){ > print " This group is on.<BR>\n"; > }else{ > print "This group is off<BR>\n"; > } > $x++; > } > I hope this makes sense to someone. In perl it is easy, you references > the form array. Can I do this in PHP and if so how?
You are on the right track. Look up variable variables in the dox. But to give you an idea, what you would need to do is modify the above IF statement as such:
if( ${$group$x} == "on" ) { I do this same thing semi-regularly and what I do is:
$fieldName = $group$x; if( ${$fieldName} == "on" ) {
that way I can reference $fieldName elsewhere in my code w/o having to stick all the variable parts of the name together each time. HTH
Chris
attached mail follows:
Hi!
Is there somewhere in the wild wild web a script for
a mail archiv based on php3 and mysql
there is a mail-account called archiv
... which gets all the mails
now I would need a routine (in perl or php3) who puts the mails into
the mysql dbase and an php3 interface to search through the mails ...
Philipp
-- Philipp Flesch (Hostmaster) Friedberger Schulnetz - Friedberg/Bay. Homepage: http://www.fsn.by.schule.de E-Mail: fleschfsn.by.schule.de Privat: E-Mail: flesch
in.tum.de
attached mail follows:
I have a function that does the following :
Function oci( $conn, $str ) { $stmt = OCIParse($conn, "$str"); OCIExecute($stmt); return $stmt; }
What its doing is basically combining the OCIParse and OCIExecute commands in one function. I dont know THAT much about how the OCI works, but this seems to do the job. Can anybody think of any reason why this could be a bad idea?
Thanks, Adam
attached mail follows:
attached mail follows:
> Take a look at http://www.php.net/manual/language.variables.external.php > > Note: I understand that in Windows you have to run PHP through CGI. > > I hope it helps,
Sorry, I'm still confused.. I don't understand how I can use this to link into a visual basic application. All I want to do is to have a form on a page that, when the user clicks the submit button, runs the application on the server and passes the form variables to it.
Alexis.
attached mail follows:
Hi all, is there a function that automatically cleans a mysql string? I have to insert into a table a user input, and it's filled with " and ' Beside, i would like to avoid the: happynewyear";drop abcd;
input. Is there something to clean a string of characters? I know it should be easy to do it with regex, but i think something already done is a) faster b) better constructed. Any idea?
Thank you, Duccio.
attached mail follows:
Duccio Gasparri wrote:
> Hi all, is there a function that automatically cleans a mysql string? I > have to insert into a table a user input, and it's filled with " and > ' Beside, i would like to avoid the: > happynewyear";drop abcd; > > input. Is there something to clean a string of characters? I know it should > be easy to do it with regex, but i think something already done is a) > faster b) better constructed. Any idea? > > Thank you, > Duccio. >
Use the addslashes() and stripslashes() function, i.e.
$string = addslashes($string); [Now do your imsert and these characters should have all been escaped.
HTH
Marcus D Hanwell
attached mail follows:
"COM/DCOM support PHP 4.0 provides COM/DCOM support (on Windows only) for seamlessly accessing COM objects and instantiating them."
2 questions:
* Does "(on Windows only)" mean that it will only work on web servers that are running on a windows based OS? Or that it will only work for end users browsing your site on a windows based OS?
* Where can I find more information on the above? I've scoured the Zend website and the most I've been able to really find on it is some sample code. Where can I find some really meaty info on this functionality?
Chris
attached mail follows:
At 04:07 PM 4/24/00 -0500, Boget, Chris wrote: >"COM/DCOM support >PHP 4.0 provides COM/DCOM support (on Windows only) for >seamlessly accessing COM objects and instantiating them." > >2 questions: > >* Does "(on Windows only)" mean that it will only work on web > servers that are running on a windows based OS? Or that it > will only work for end users browsing your site on a windows > based OS?
Considering that everything else in PHP is server-side, I would guess that you would need to be serving from a Win32 platform ; )
Ciao,
Zak
attached mail follows:
> At 04:07 PM 4/24/00 -0500, Boget, Chris wrote: > >"COM/DCOM support > >PHP 4.0 provides COM/DCOM support (on Windows only) for > >seamlessly accessing COM objects and instantiating them." > >* Does "(on Windows only)" mean that it will only work on web > > servers that are running on a windows based OS? Or that it > > will only work for end users browsing your site on a windows > > based OS? > Considering that everything else in PHP is server-side, I > would guess that you would need to be serving from a > Win32 platform ; )
I don't want to get too offtrack of the other part of my question, but I just want to comment that I think that it could go either way (w/o looking at the hard dox which is the other part of my ?) because the apps (Excel, Word, Etc.) are going to be residing on the client's PC.
Chris
attached mail follows:
"Boget, Chris" wrote: > > > At 04:07 PM 4/24/00 -0500, Boget, Chris wrote: > > >"COM/DCOM support > > >PHP 4.0 provides COM/DCOM support (on Windows only) for > > >seamlessly accessing COM objects and instantiating them." > > >* Does "(on Windows only)" mean that it will only work on web > > > servers that are running on a windows based OS? Or that it > > > will only work for end users browsing your site on a windows > > > based OS? > > Considering that everything else in PHP is server-side, I > > would guess that you would need to be serving from a > > Win32 platform ; ) > > I don't want to get too offtrack of the other part of my question, but > I just want to comment that I think that it could go either way (w/o > looking at the hard dox which is the other part of my ?) because the > apps (Excel, Word, Etc.) are going to be residing on the client's PC. >
Wrong. COM objects are strictly server-side. They manipulate applications on the server not applications on the client.
Sterling
attached mail follows:
At 04:17 PM 4/24/00 -0500, Boget, Chris wrote: > > At 04:07 PM 4/24/00 -0500, Boget, Chris wrote: > > >"COM/DCOM support > > >PHP 4.0 provides COM/DCOM support (on Windows only) for > > >seamlessly accessing COM objects and instantiating them." > > >* Does "(on Windows only)" mean that it will only work on web > > > servers that are running on a windows based OS? Or that it > > > will only work for end users browsing your site on a windows > > > based OS? > > Considering that everything else in PHP is server-side, I > > would guess that you would need to be serving from a > > Win32 platform ; ) > >I don't want to get too offtrack of the other part of my question, but >I just want to comment that I think that it could go either way (w/o >looking at the hard dox which is the other part of my ?) because the >apps (Excel, Word, Etc.) are going to be residing on the client's PC.
Hmmm... (grinding gears, smoke pouring out of ears..) errr... isn't automation for apps handled by ActiveX - has MS gone and renamed OLE again while I wasn't looking?
Zak
attached mail follows:
> * Does "(on Windows only)" mean that it will only work on web > servers that are running on a windows based OS? Or that it > will only work for end users browsing your site on a windows > based OS?
It means that the COMs will need to be on the server. Remember php is a "preparser" which implies "before it reaches the client".
I think com objects are a great way to extend php's capabilities, not to mention interface with MTS.
> * Where can I find more information on the above? I've scoured > the Zend website and the most I've been able to really find on it > is some sample code. Where can I find some really meaty info > on this functionality?
unfortunatly, there isin't a manual entry for it. Of course, theres not a whole lot to say either. Every com is differen and has its own set of properties or procedures.
A good place to start is at www.microsoft.com/com Or visit MSDN for 'nitty-gritty' details.
Patrick Shafer
--------------
Senior Web Applications Engineer
pshafer
netsolutionsllc.com
http://www.netsolutionsllc.com
attached mail follows:
ActiveX and OLE are subsets of the Component Object Model (COM). DCOM is Distributed COM and dictates how different COM objects are instantiated and utilized between modules (on the same machine or distributed on a network).
Zak Greant wrote:
> At 04:17 PM 4/24/00 -0500, Boget, Chris wrote:
> > > At 04:07 PM 4/24/00 -0500, Boget, Chris wrote:
> > > >"COM/DCOM support
> > > >PHP 4.0 provides COM/DCOM support (on Windows only) for
> > > >seamlessly accessing COM objects and instantiating them."
> > > >* Does "(on Windows only)" mean that it will only work on web
> > > > servers that are running on a windows based OS? Or that it
> > > > will only work for end users browsing your site on a windows
> > > > based OS?
> > > Considering that everything else in PHP is server-side, I
> > > would guess that you would need to be serving from a
> > > Win32 platform ; )
> >
> >I don't want to get too offtrack of the other part of my question, but
> >I just want to comment that I think that it could go either way (w/o
> >looking at the hard dox which is the other part of my ?) because the
> >apps (Excel, Word, Etc.) are going to be residing on the client's PC.
>
> Hmmm... (grinding gears, smoke pouring out of ears..) errr... isn't
> automation for apps handled by ActiveX - has MS gone and renamed OLE again
> while I wasn't looking?
>
> Zak
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
attached mail follows:
I have discovered the problem is with how PHP includes files for support of various databases. This example, includes the informix files, which define things like SQLDATE and such. DB2 also defines these things in it's include files, and it gets included further down in the file that failed. If I remove the Informix support, it will compile fine.
How do I get both Informix and DB2 support in the same binary? Or can I compile the informix or DB2 parts as "extensions" or "modules" somehow?
Please help,
Thanks,
Tom
"Thomas E. Ruth" wrote:
>
> Hello,
>
> I am having great troubles getting PHP3 to compile with IBM DB2. I am
> trying to compile PHP-3.0.16 with IMBdb2 V6.1, Fixpack 3, all on Red Hat
> 6.1 with the latest patches.
>
> Thanks for any help you can give me!
>
> Tom
>
> Here is the configure options I am trying to use:
>
> [root
happy php-3.0.16]# cat /root/makephp3
> #!/bin/sh
> ./configure \
> --x-libraries=/usr/local/lib \
> --with-apxs=/usr/sbin/apxs \
> --prefix=/usr \
> --enable-safe-mode \
> --with-exec-dir=/usr/bin \
> --with-zlib \
> --with-dbase \
> --with-filepro \
> --with-config-file-path=/etc/php3/apache \
> --disable-debug \
> --enable-magic-quotes \
> --enable-debugger \
> --enable-bcmath \
> --enable-track-vars \
> --with-imap \
> --with-system-regex \
> --without-gd \
> --with-yp \
> --with-informix \
> --with-mysql \
> --with-ldap \
> --with-pdflib=/usr/local \
> --with-pdflib-dir=/usr/local \
> --with-jpeg-dir=/usr \
> --with-zlib-dir=/usr \
> --with-tiff-dir=/usr \
> --with-png-dir=/usr \
> --with-ibm-db2
>
> Here is the errors for everything and the output of all the commands I
> am trying to use:
>
> [root
happy php-3.0.16]# /root/makephp3
> creating cache ./config.cache
> checking whether build environment is sane... yes
> checking whether to enable maintainer-specific portions of Makefiles...
> no
> checking for bison... bison -y
> checking bison version... 1.28 (ok)
> checking for gcc... gcc
> checking whether the C compiler (gcc ) works... yes
> checking whether the C compiler (gcc ) is a cross-compiler... no
> checking whether we are using GNU C... yes
> checking whether gcc accepts -g... yes
> checking for gcc option to accept ANSI C... none needed
> checking for ranlib... ranlib
> checking whether gcc and cc understand -c and -o together... yes
> checking whether ln -s works... yes
> checking for perl... /usr/bin/perl
> checking for sh... /bin/sh
> checking for working const... yes
> checking if compiler supports -R... no
> checking if compiler supports -Wl,-rpath,... yes
> checking if compiler supports -Wl,--version-script... yes
> checking size of long... 4
> checking size of int... 4
> checking for sendmail... /usr/sbin/sendmail
> checking for gethostent... yes
> checking for socket in -lc... yes
> checking for gethostbyaddr in -lc... yes
> checking for crypt in -lc... no
> checking for crypt in -lcrypt... yes
> checking for dlopen in -lc... no
> checking for dlopen in -ldl... yes
> checking for sin in -lc... no
> checking for sin in -lm... yes
> checking for res_search in -lsocket... no
> checking for res_search in -lresolv... yes
> checking for pam_start in -lpam... yes
> checking for inet_aton in -lbind... no
> checking how to run the C preprocessor... gcc -E
> checking for ANSI C header files... yes
> checking for dirent.h that defines DIR... yes
> checking for opendir in -ldir... no
> checking for fclose declaration... ok
> checking for fcntl.h... yes
> checking for unistd.h... yes
> checking for crypt.h... yes
> checking for sys/file.h... yes
> checking for memory.h... yes
> checking for pwd.h... yes
> checking for grp.h... yes
> checking for sys/socket.h... yes
> checking for sys/wait.h... yes
> checking for syslog.h... yes
> checking for string.h... yes
> checking for sys/varargs.h... no
> checking for stdarg.h... yes
> checking for sys/resource.h... yes
> checking for sys/time.h... yes
> checking for signal.h... yes
> checking for netinet/in.h... yes
> checking for dlfcn.h... yes
> checking for limits.h... yes
> checking for sys/types.h... yes
> checking for sys/statvfs.h... yes
> checking for sys/statfs.h... yes
> checking for unix.h... no
> checking for db.h... yes
> checking for dbm.h... no
> checking for ndbm.h... no
> checking for db1/ndbm.h... yes
> checking for locale.h... yes
> checking for features.h... yes
> checking whether struct tm is in sys/time.h or time.h... time.h
> checking for tm_zone in struct tm... yes
> checking for tm_gmtoff in struct tm... yes
> checking for struct flock... yes
> checking for st_blksize in struct stat... yes
> checking for st_blocks in struct stat... yes
> checking for st_rdev in struct stat... yes
> checking for size_t... yes
> checking for uid_t in sys/types.h... yes
> checking for uint... yes
> checking for ushort... yes
> checking for ulong... yes
> checking for ptrdiff_t... yes
> checking for vprintf... yes
> checking for memcpy... yes
> checking for memmove... yes
> checking for strdup... yes
> checking for strerror... yes
> checking for strcasecmp... yes
> checking for strstr... yes
> checking for flock... yes
> checking for lockf... yes
> checking for putenv... yes
> checking for tempnam... yes
> checking for usleep... yes
> checking for setlocale... yes
> checking for gettimeofday... yes
> checking for setvbuf... yes
> checking for srand48... yes
> checking for lrand48... yes
> checking for srandom... yes
> checking for random... yes
> checking for link... yes
> checking for symlink... yes
> checking for regcomp... yes
> checking for getlogin... yes
> checking for cuserid... yes
> checking for vsnprintf... yes
> checking for gcvt... yes
> checking for utime... yes
> checking for crypt... yes
> checking for setitimer... yes
> checking for rint... yes
> checking for unsetenv... yes
> checking for strftime... yes
> checking for setsockopt... yes
> checking for tzset... yes
> checking for statvfs... yes
> checking for statfs... yes
> checking for inet_aton... yes
> checking for shutdown... yes
> checking for truncate... yes
> checking for getpgid... yes
> checking for getsid... yes
> checking for getrlimit... yes
> checking for snprintf... yes
> checking for ctermid... yes
> checking for setsid... yes
> checking for mkfifo... yes
> checking for getrusage... yes
> checking whether utime accepts a null argument... yes
> checking for working alloca.h... yes
> checking for alloca... yes
> checking for broken sprintf... ok
> checking for getopt... yes
> checking for declared timezone... yes
> checking for standard DES crypt... yes
> checking for extended DES crypt... no
> checking for MD5 crypt... yes
> checking for Blowfish crypt... no
> checking for Apache module support via DSO through APXS... yes
> checking whether to enable versioning... no
> checking whether to use bundled regex library... no
> checking for gdbm_open in -lgdbm... yes
> checking preferred dbm library... gdbm chosen
> checking for gdbm.h... yes
> checking for mod_charset compatibility option... no
> checking for fhttpd module support... no
> checking for IMAP support... yes
> checking for IMSP support... no
> checking for ASPELL support... no
> checking for MCAL support... no
> checking for ftp support... no
> checking whether to include GD support... no
> checking whether to include FreeType support... yes
> configure: warning: No gd support found. Skipping FreeType Configuration
> checking whether to enable t1lib support... no
> checking whether to include GNU gettext support... no
> checking whether to include ImageMagick support... no
> checking for Oracle support... no
> checking for iODBC support... no
> checking for OpenLink ODBC support... no
> checking for Adabas support... no
> checking for Sybase support... no
> checking for Sybase-CT support... no
> checking for MySQL support... yes
> checking for errmsg.h... yes
> checking for mysql.h... yes
> checking for mSQL support... no
> checking for PostgresSQL support... no
> checking for IBM DB2 support... yes
> checking for Solid support... no
> checking for Empress support... no
> checking for LDAP support... yes
> checking for Cybercash MCK support... no
> checking for SNMP support... no
> checking whether to enable UCD SNMP hack... no
> checking for Velocis support... no
> checking for Informix support... checking Informix version... yes
> checking for InterBase support... no
> checking for a custom ODBC support... no
> checking for Hyperwave support... no
> checking for XML support... no
> checking whether to include YP support... yes
> checking whether to include zlib support... yes
> checking for gzgets in -lz... yes
> checking whether to include pdflib support... yes
> checking for libz needed by pdflib 2.0... already zlib support
> checking for libjpeg (needed by pdflib 2.0)... yes
> checking for jpeg_read_header in -ljpeg... yes
> checking for libtiff (needed by pdflib 2.0)... yes
> checking for TIFFOpen in -ltiff... yes
> checking for PDF_new in -lpdf... yes
> checking whether to include cpdflib support... no
> checking whether to include fdftk support... no
> checking whether to include the bundled dbase library... yes
> checking whether to include the bundled filePro support... yes
> checking whether to enable DAV support through mod_dav... no
> checking whether to enable unified ODBC support... yes
> checking whether to use a configuration file... yes
> checking whether to include debugging symbols... no
> checking whether to enable safe mode by default... yes
> checking for safe mode exec dir... /usr/bin
> checking whether to enable track_vars variables by default... yes
> checking whether to enable magic quotes by default... yes
> checking whether to enable remote debugger support... yes
> checking whether to enable bc style precision math functions... yes
> checking whether to enable a memory limit... no
> checking whether to enable short tags by default... yes
> checking whether to enable the URL-aware fopen wrapper... yes
> checking whether to enable System V semaphore support... no
> checking whether to enable System V shared memory support... no
> checking whether to enable displaying source support... yes
> checking for GDBM support... no
> checking for NDBM support... no
> checking for Berkeley DB2 support... no
> checking for DBM support... no
> checking for CDB support... no
> checking whether to enable DBA interface... no
> checking for mcrypt support... no
> checking for mhash support... no
> checking whether to include PCRE support... yes
> checking for memmove... (cached) yes
> checking whether to include POSIX support... yes
> checking whether to include GNU recode support... no
> checking whether to enable dmalloc support... no
> checking for __dn_skipname in -lbind... no
> updating cache ./config.cache
> creating ./config.status
> creating Makefile
> creating build-defs.h
> creating stamp-h
> creating libphp3.module
> creating extra/gd/bdf2gdfont
> creating regex/Makefile
> creating pcrelib/Makefile
> creating dbase/Makefile
> creating config.h
> [root
happy php-3.0.16]# make
> bison -y -p php -v -d ./language-parser.y -o language-parser.tab.c
> gcc -g -O2 -O2 -m486 -fno-strength-reduce -DLINUX=2 -DTARGET="httpsd"
> -DMOD_SSL=
> 204105 -DEAPI -DEAPI_MM -DUSE_EXPAT -I../lib/expat-lite
> -I/usr/local/Informix/in
> cl/esql -O2 -fpic -DSHARED_MODULE -I. -I.
> -I/usr/include/apache -I
> /usr/local/include -I/usr/local/Informix/incl/esql
> -I/usr/include/imap -I/us
> r/include/mysql -I/home/db2inst1/sqllib/include -c
> language-parser.tab.c -o l
> anguage-parser.tab.o
> flex -Pphp -olanguage-scanner.c -i ./language-scanner.lex
> gcc -g -O2 -O2 -m486 -fno-strength-reduce -DLINUX=2 -DTARGET="httpsd"
> -DMOD_SSL=
> 204105 -DEAPI -DEAPI_MM -DUSE_EXPAT -I../lib/expat-lite
> -I/usr/local/Informix/in
> cl/esql -O2 -fpic -DSHARED_MODULE -I. -I.
> -I/usr/include/apache -I
> /usr/local/include -I/usr/local/Informix/incl/esql
> -I/usr/include/imap -I/us
> r/include/mysql -I/home/db2inst1/sqllib/include -w -DYY_USE_CONST -c
> language
> -scanner.c
> gcc -g -O2 -O2 -m486 -fno-strength-reduce -DLINUX=2 -DTARGET="httpsd"
> -DMOD_SSL=
> 204105 -DEAPI -DEAPI_MM -DUSE_EXPAT -I../lib/expat-lite
> -I/usr/local/Informix/in
> cl/esql -O2 -fpic -DSHARED_MODULE -I. -I.
> -I/usr/include/apache -I
> /usr/local/include -I/usr/local/Informix/incl/esql
> -I/usr/include/imap -I/us
> r/include/mysql -I/home/db2inst1/sqllib/include -c main.c -o main.o
> gcc -g -O2 -O2 -m486 -fno-strength-reduce -DLINUX=2 -DTARGET="httpsd"
> -DMOD_SSL=
> 204105 -DEAPI -DEAPI_MM -DUSE_EXPAT -I../lib/expat-lite
> -I/usr/local/Informix/in
> cl/esql -O2 -fpic -DSHARED_MODULE -I. -I.
> -I/usr/include/apache -I
> /usr/local/include -I/usr/local/Informix/incl/esql
> -I/usr/include/imap -I/us
> r/include/mysql -I/home/db2inst1/sqllib/include -c php3_hash.c -o
> php3_hash.o
> gcc -g -O2 -O2 -m486 -fno-strength-reduce -DLINUX=2 -DTARGET="httpsd"
> -DMOD_SSL=
> 204105 -DEAPI -DEAPI_MM -DUSE_EXPAT -I../lib/expat-lite
> -I/usr/local/Informix/in
> cl/esql -O2 -fpic -DSHARED_MODULE -I. -I.
> -I/usr/include/apache -I
> /usr/local/include -I/usr/local/Informix/incl/esql
> -I/usr/include/imap -I/us
> r/include/mysql -I/home/db2inst1/sqllib/include -c operators.c -o
> operators.o
> gcc -g -O2 -O2 -m486 -fno-strength-reduce -DLINUX=2 -DTARGET="httpsd"
> -DMOD_SSL=
> 204105 -DEAPI -DEAPI_MM -DUSE_EXPAT -I../lib/expat-lite
> -I/usr/local/Informix/in
> cl/esql -O2 -fpic -DSHARED_MODULE -I. -I.
> -I/usr/include/apache -I
> /usr/local/include -I/usr/local/Informix/incl/esql
> -I/usr/include/imap -I/us
> r/include/mysql -I/home/db2inst1/sqllib/include -c variables.c -o
> variables.o
> gcc -g -O2 -O2 -m486 -fno-strength-reduce -DLINUX=2 -DTARGET="httpsd"
> -DMOD_SSL=
> 204105 -DEAPI -DEAPI_MM -DUSE_EXPAT -I../lib/expat-lite
> -I/usr/local/Informix/in
> cl/esql -O2 -fpic -DSHARED_MODULE -I. -I.
> -I/usr/include/apache -I
> /usr/local/include -I/usr/local/Informix/incl/esql
> -I/usr/include/imap -I/us
> r/include/mysql -I/home/db2inst1/sqllib/include -c token_cache.c -o
> token_cac
> he.o
> gcc -g -O2 -O2 -m486 -fno-strength-reduce -DLINUX=2 -DTARGET="httpsd"
> -DMOD_SSL=
> 204105 -DEAPI -DEAPI_MM -DUSE_EXPAT -I../lib/expat-lite
> -I/usr/local/Informix/in
> cl/esql -O2 -fpic -DSHARED_MODULE -I. -I.
> -I/usr/include/apache -I
> /usr/local/include -I/usr/local/Informix/incl/esql
> -I/usr/include/imap -I/us
> r/include/mysql -I/home/db2inst1/sqllib/include -c stack.c -o stack.o
> gcc -g -O2 -O2 -m486 -fno-strength-reduce -DLINUX=2 -DTARGET="httpsd"
> -DMOD_SSL=
> 204105 -DEAPI -DEAPI_MM -DUSE_EXPAT -I../lib/expat-lite
> -I/usr/local/Informix/in
> cl/esql -O2 -fpic -DSHARED_MODULE -I. -I.
> -I/usr/include/apache -I
> /usr/local/include -I/usr/local/Informix/incl/esql
> -I/usr/include/imap -I/us
> r/include/mysql -I/home/db2inst1/sqllib/include -c
> internal_functions.c -o in
> ternal_functions.o
> In file included from /home/db2inst1/sqllib/include/sqlcli1.h:41,
> from functions/php3_unified_odbc.h:218,
> from internal_functions.c:89:
> /home/db2inst1/sqllib/include/sqlcli.h:307: parse error before `7'
> /home/db2inst1/sqllib/include/sqlcli.h:310: parse error before `5'
> /home/db2inst1/sqllib/include/sqlcli.h:333: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli.h:339: parse error before `3'
> /home/db2inst1/sqllib/include/sqlcli.h:473: parse error before `14'
> /home/db2inst1/sqllib/include/sqlcli.h:492: parse error before `14'
> /home/db2inst1/sqllib/include/sqlcli.h:492: warning: no semicolon at end
> of stru
> ct or union
> /home/db2inst1/sqllib/include/sqlcli.h:499: parse error before `}'
> /home/db2inst1/sqllib/include/sqlcli.h:499: warning: data definition has
> no type
> or storage class
> /home/db2inst1/sqllib/include/sqlcli.h:508: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli.h:508: warning: no semicolon at end
> of stru
> ct or union
> /home/db2inst1/sqllib/include/sqlcli.h:510: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli.h:512: warning: data definition has
> no type
> or storage class
> /home/db2inst1/sqllib/include/sqlcli.h:552: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli.h:561: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli.h:574: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli.h:581: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli.h:598: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli.h:613: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli.h:620: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli.h:646: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli.h:669: parse error before `0'
> In file included from /home/db2inst1/sqllib/include/sqlcli.h:709,
> from /home/db2inst1/sqllib/include/sqlcli1.h:41,
> from functions/php3_unified_odbc.h:218,
> from internal_functions.c:89:
> /home/db2inst1/sqllib/include/sqlext.h:1679: parse error before `0'
> /home/db2inst1/sqllib/include/sqlext.h:1789: parse error before `0'
> /home/db2inst1/sqllib/include/sqlext.h:1812: parse error before `0'
> /home/db2inst1/sqllib/include/sqlext.h:1838: parse error before `0'
> /home/db2inst1/sqllib/include/sqlext.h:1856: parse error before `0'
> /home/db2inst1/sqllib/include/sqlext.h:1873: parse error before `0'
> /home/db2inst1/sqllib/include/sqlext.h:1882: parse error before `0'
> /home/db2inst1/sqllib/include/sqlext.h:1893: parse error before `0'
> /home/db2inst1/sqllib/include/sqlext.h:1908: parse error before `0'
> /home/db2inst1/sqllib/include/sqlext.h:1918: parse error before `0'
> In file included from functions/php3_unified_odbc.h:218,
> from internal_functions.c:89:
> /home/db2inst1/sqllib/include/sqlcli1.h:637: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli1.h:648: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli1.h:720: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli1.h:730: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli1.h:740: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli1.h:1073: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli1.h:1083: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli1.h:1099: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli1.h:1124: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli1.h:1166: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli1.h:1178: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli1.h:1189: parse error before `0'
> /home/db2inst1/sqllib/include/sqlcli1.h:1222: parse error before `0'
> make: *** [internal_functions.o] Error 1
>
> --
> PHP Development Mailing List <http://www.php.net/>
> To unsubscribe, e-mail: php-dev-unsubscribe
lists.php.net
> For additional commands, e-mail: php-dev-help
lists.php.net
> To contact the list administrators, e-mail: php-list-admin
lists.php.net
attached mail follows:
At 01:53 AM 4/25/00 +0500, Faisal Nasim wrote: >| Say you have 30 user-built functions in *one* file, 200 lines of code. >| Depending on your code base/version, if those are called 10 times per >page, >| you need to include that code for the parser (file call), and >| then as you go through the page, it substitutes out the function code.... >| plus you've added 20 useless functions of overhead for *every* >| parsed page. (Hence, the speed differences between 3 and 4, and the >| problem with using functions in 3. They *will* bog your execution >| down) > >Its there parsed once sitting in the memory, it doesn't actually >substitute the function contents with the function call and then >process is as if it was embedded in the code itself! Its done >through a smart method. > >| >| Lots and lots of overhead in that. If you can strip excess functions >| out, and speed is your goal, by all means, dump them over the side >| as fast as you can, and explicitly code using PHP's internal >| functions. Try two or three variants on your code, to see if, for >| example, you could get a faster result from a printf or an echo, >| a faster loop by only testing (if/case) under a smaller set of >| circumstances, and, if you can, avoid *ever* using requires or >| includes.... > >Seems like you have mixed C with PHP. PHP functions don't >have overhead like C does (unless they are inline, the overhead >is negligible, but its there!)
PHP function calls have overhead similar to the way C does. The parameters are passed etc. etc..
Andi
--- Andi Gutmans <andizend.com> http://www.zend.com/
attached mail follows:
Greetings,
I'm getting closer to making sybase 11.0.3.3 and php-3.0.16 communicate. apache-1.3.12 is compiled with DSO and php was config'd --with-sybase-ct=/path and --with-apxs=/path.
When trying to start apache I get the following message...
# apachectl start Syntax error on line 215 of /usr/local/etc/apache/httpd.conf: Cannot load /usr/local/libexec/apache/libphp3.so into server: /usr/lib/libcs.so: Undefined symbol "intl_cstrbuild" /usr/local/sbin/apachectl start: httpd could not be started
It looks like the php lib and libcs.so --> /opt/sybase/lib/libcs.so cannot communicate. Does anyone know what I'm missing?
Many TIA!
-- Doug Poland dpolandexecpc.com
attached mail follows:
Hi All,
I am having some trouble getting a sql statement to work. It is a very simple statement. Here is the what I am sending to the query routine:
insert into task ("proj_id","name","description") values (99,"Test task","test-pj: Test test test")
I get the following error message:
Can't perform query: You have an error in your SQL syntax near '"proj_id","name","description") values (99,"Test task","test-pj: Test test test"' at line 1
What do I need to do here, I have tried addslashes, stripslashes, single quotes, double qoutes. Please help
Thanks
Glenn
--Glenn MacGregor
Director of Services Oracom, Inc. http://www.oracom.com
Tel. +1 978.557.5710 Ext. 302 Fax +1 978.557.5716
attached mail follows:
Take out the "" in the first set...
insert into task (proj_id, name, description) values (99,"Test task","test-pj: Test test test");
Good luck!
-----Original Message-----
From: gtm
oracom.com [mailto:gtm
oracom.com]
Sent: Monday, April 24, 2000 5:22 PM
To: php
Subject: [PHP3] sql query
Hi All,
I am having some trouble getting a sql statement to work. It is a very simple statement. Here is the what I am sending to the query routine:
insert into task ("proj_id","name","description") values (99,"Test task","test-pj: Test test test")
I get the following error message:
Can't perform query: You have an error in your SQL syntax near '"proj_id","name","description") values (99,"Test task","test-pj: Test test test"' at line 1
What do I need to do here, I have tried addslashes, stripslashes, single quotes, double qoutes. Please help
Thanks
Glenn
--Glenn MacGregor
Director of Services Oracom, Inc. http://www.oracom.com
Tel. +1 978.557.5710 Ext. 302 Fax +1 978.557.5716
-- PHP 3 Mailing List <http://www.php.net/> To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
attached mail follows:
At 05:22 PM 4/24/00 -0500, Glenn MacGregor wrote: >Hi All, > > I am having some trouble getting a sql statement to work. It is a > very simple >statement. Here is the what I am sending to the query routine: > > insert into task ("proj_id","name","description") values (99,"Test >task","test-pj: Test test test")
[snip]
Hi Glenn,
Try removing the quotes from around your field names.
HTH,
Zak
attached mail follows:
In addition to the existing ODBC functions, PHP also has native MS SQL Server support. Are these functions utilizing OLE DB? ODBC? or something else?
The reason I'm asking is because if PHP uses a native connectivity approach, that's awesome! ASP utilized ODBC connections for almost everything - even there MS SQL Server...
Jonathan Griffin MasterMind Internet Services
attached mail follows:
TEST TEST TEST!
HAVING PROBLEMS!
attached mail follows:
Could someone be so kind as to point me to the addslashes() C course in the PHP3 (or 4) source tree? I've looked and looked (no doubt right past it) and haven't been able to locate it.
Thanks!!
- Mitch
attached mail follows:
Not sure about PHP3.x, but in 4b3, it's in
(your PHP source dir)/ext/standard/string.c
Doug
Mitch Vincent was heard at 05:42 PM 4/24/00 -0400 to say: >Could someone be so kind as to point me to the addslashes() C course in the >PHP3 (or 4) source tree? I've looked and looked (no doubt right past it) and >haven't been able to locate it. > >Thanks!! > >- Mitch >
attached mail follows:
On Mon, 24 Apr 2000, Mitch Vincent wrote:
> Could someone be so kind as to point me to the addslashes() C course in the > PHP3 (or 4) source tree? I've looked and looked (no doubt right past it) and > haven't been able to locate it.
The native implementation can be found at php-3.0.14/functions/string.c:1325.
david
-- David L Rubin rubinredconnect.net http://63.71.143.54:8080/~rubin gpg key fingerprint: 07D9 BB21 433F 0178 383B 1982 C972 284F E353 FBA9
attached mail follows:
On Tue, 25 Apr 2000, SANIsoft wrote: > OK! looks like .htaccess itself is not working for my server :-(
Is there a good tutorial for htaccess and php4 I wish to protect a directory and all the files in it
Kevin
attached mail follows:
Here's a couple .htaccess sites I personally use for reference. If .htaccess isn't working on your Apache server, you might need to edit Apache's httpd.conf so that it allows them. Hopefully you have access to that file. :-)
Tutorial --> http://www.he.net/info/htaccess/demo.html Directives --> http://apache.org/docs/mod/directives.html
- Dev -----------------
Kevin Waterson wrote: > > On Tue, 25 Apr 2000, SANIsoft wrote: > > OK! looks like .htaccess itself is not working for my server :-( > > Is there a good tutorial for htaccess and php4 > I wish to protect a directory and all the files in it > > Kevin
attached mail follows:
I have PHP 4RC1 (as an Apache module) on a Yellow Dog Linux (G4 Mac) with Apache 1.3.12. I have the GD lib installed and the image library stuff is working quite nicely. What I don't quite understand (after many hours of research and trial and error) is how to get true type fonts to work with the image library. I've got Freetype installed on the box (from an RPM) but I couldn't locate where/how PHP (utilizing Freetype) locates fonts and is able to use them as part of the image library. Is there a way you have to install fonts using PHP and Freetype? Is there a way to tell if Freetype support is loaded or being utilized by PHP? Do you have to tell PHP where the font is when you make a call to a TTF function?
All and any help is greatly appreciated.
-Josh Hoover
attached mail follows:
I'm no programmer, and relatively new to PHP in general. I've been using it for small things here and there, as I find it pretty resourceful. I've been trying to create a small decimal to binary function, but have run into a serious stump. I can't seem to get the output that I want. The conversion is working, but adds a ton of extra information I really don't need to know. If someone could take a look at this function, and point out what I'm doing wrong, or what I could be doing better/differently I would appreciate it. Thanks.
function DecToBin($decimal) {
$binary = "";
while ($decimal != "0") { $bit = $decimal % "2";
if ($bit == "0") { $binary == 0 + $binary; } else { $binary == 1 + $binary; } $decimal = $decimal/2; echo $bit; } }
-- Robert Hough (rchqserve.net) Qserve Internet, Inc. http://www.qserve.net/ Ph: (317)802-3036
attached mail follows:
At 05:01 PM 4/24/00 -0500, you wrote: >I'm no programmer, and relatively new to PHP in general. I've been using >it for small things here and there, as I find it pretty resourceful. I've >been trying to create a small decimal to binary function, but have run >into a serious stump.
Before anyone mentions it, yes, I'm aware of decbin(), which is not exactly what I'm trying to accomplish. The problem itself is more about the way I'm doing things, more than the actualy conversion itself. That make sense? :)
-- Robert Hough (rchqserve.net) Qserve Internet, Inc. http://www.qserve.net/ Ph: (317)802-3036
attached mail follows:
Hi Robert and List,
Your code looks very close - there a just a few little points that you need to clear up.
At 05:01 PM 4/24/00 -0500, Robert Hough wrote: >function DecToBin($decimal) { > >$binary = ""; > >while ($decimal != "0") > { > $bit = $decimal % "2";
You don't need to put numbers inside of quotes. It doesn't actually hurt anything in this case ( or in most cases for that matter - PHP is quite forgiving )
> if ($bit == "0")
Again, drop the quotes.
> { > $binary == 0 + $binary;
== is a test for equality between the left and right sides of the equation. You want to use a single equals sign instead.
You will also want to use the string concatenation (.) operator instead of the addition (+) operator. The reason for this is that you will end up with a decimal number that is the sum of all of the bits in the number, instead of a sequential listing of all the bits.
> } > else > { > $binary == 1 + $binary; > } > $decimal = $decimal/2; > echo $bit; > } >}
Thats about it. :)
Here is a some modified code that includes the changes.
function DecToBin($decimal) { while ($decimal != "0") { $bit = $decimal % 2;
if ($bit == "0") $binary = 0 . $binary; else $binary = 1 . $binary;
$decimal = $decimal/2; }
return $binary; }
print DecToBin(21);
HTH,
Zak
attached mail follows:
Gee, I'd do it more like this:
function DecToBin($decimal) { while ($decimal > 0) {
Robert Hough was heard at 05:01 PM 4/24/00 -0500 to say:
>I'm no programmer, and relatively new to PHP in general. I've been using it
>for small things here and there, as I find it pretty resourceful. I've been
>trying to create a small decimal to binary function, but have run into a
>serious stump. I can't seem to get the output that I want. The conversion
>is working, but adds a ton of extra information I really don't need to
>know. If someone could take a look at this function, and point out what I'm
>doing wrong, or what I could be doing better/differently I would appreciate
>it. Thanks.
>
>function DecToBin($decimal) {
>
>$binary = "";
>
>while ($decimal != "0")
> {
> $bit = $decimal % "2";
>
> if ($bit == "0")
> {
> $binary == 0 + $binary;
> }
> else
> {
> $binary == 1 + $binary;
> }
> $decimal = $decimal/2;
> echo $bit;
> }
>}
>
>--
>Robert Hough (rch
qserve.net) Qserve Internet, Inc.
>http://www.qserve.net/ Ph: (317)802-3036
>
>
>--
>PHP 3 Mailing List <http://www.php.net/>
>To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net
>To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
>
>
attached mail follows:
Ok...that one got away from me when I did a typo...here's the original message I was trying to type:
function DecToBin($decimal) { $binary = ""; while ((int) $decimal > 0) { $bit = $decimal % 2; $binary .= $bit; $decimal /= 2; } echo strrev($binary); }
or, if I'm feeling mighty desparate:
printf ("%b", $decimal);
Doug
Robert Hough was heard at 05:01 PM 4/24/00 -0500 to say:
>I'm no programmer, and relatively new to PHP in general. I've been using it
>for small things here and there, as I find it pretty resourceful. I've been
>trying to create a small decimal to binary function, but have run into a
>serious stump. I can't seem to get the output that I want. The conversion
>is working, but adds a ton of extra information I really don't need to
>know. If someone could take a look at this function, and point out what I'm
>doing wrong, or what I could be doing better/differently I would appreciate
>it. Thanks.
>
>function DecToBin($decimal) {
>
>$binary = "";
>
>while ($decimal != "0")
> {
> $bit = $decimal % "2";
>
> if ($bit == "0")
> {
> $binary == 0 + $binary;
> }
> else
> {
> $binary == 1 + $binary;
> }
> $decimal = $decimal/2;
> echo $bit;
> }
>}
>
>--
>Robert Hough (rch
qserve.net) Qserve Internet, Inc.
>http://www.qserve.net/ Ph: (317)802-3036
attached mail follows:
Hey all, I've been messin with this off and on for almost a week now with no luck. Has anyone had any luck with an Authorization script through Apache on Win32? The scriptlet I have is as follows:
<? if (!isset($PHP_AUTH_USER)) { header('HTTP/1.0 401 Unauthorized'); header('WWW-Authenticate: Basic realm="My Private Stuff"'); echo 'Authorization Required.'; exit; } else { print" Authentication Successfull!"; } ?>
I've read on PHP.net about swapping the headers for WWW-Authenticate and HTTP/1.0 401 if you're wondering why they seem backward...to no avail. All I get in my browser is a 500 error, and my error log shows this:
[Mon Apr 24 19:01:21 2000] [error] [client 142.177.195.125] malformed header from script. Bad header=HTTP/1.0 401 Unauthorized: c:/usr/bin/php3/php.exe
I've tried using HTTP/1.0 and HTTP/1.1 but neither work. I do know this works on *nix servers, so could it be yet another of the PHP as CGI Win32 woes? Any help would be appreciated.
John/Digit4l
For those interested: Apache is 1.3.12 Win32 and PHP is 3.0.16. If I get this to work, it will authenticate users not from a .htpasswd file, but from a MySQL database. I think I covered all the bases, thanks again.
attached mail follows:
I'm trying to get php and mod_ssl to play nicely with each other in the FreeBSD playground. I had php3 working prior to screwing everything up trying to get ssl. Right now when I run apachectl start I get: Cannot add module via name 'mod_php3.c': not in list of loaded modules
in my apache.conf I have: AddModule mod_php3.c on the offending line.
David
Software Eng. - NetManage
Work email: david.daugherty
netmanage.com
Home email: doc
wcug.wwu.edu
ICQ 21106703
Washington State Resident
attached mail follows:
Is this mean PHP4 got problem on ODBC ?
> -----Original Message-----
> From: Carlos Andre Marques Moreira [SMTP:camoreira
sfiec.org.br]
> Sent: Monday, April 24, 2000 7:47 PM
> To: chchar
> Subject: RES: Need Help On ODBC Connect To Visual Foxpro.
>
> Hi,
> I had experienced problem with ODBC (with ms access) and PHP4. I could
> connect to the database but when i executed the odbc_exec it generated
> about the same error.
> I resolved this changing to php 3.
>
> Carlos Andre Marques Moreira
> Senai/Cetae
> camoreira
sfiec.org.br
>
> "A vida e como uma partida de poker, as vezes voce ganha com um par, em
> outras, perde com um 'full house' ".
> Extraido de "Um tok na cuca"
>
> -----Mensagem original-----
> De: chchar [mailto:chchar
mcms.com]
> Enviada em: Sabado, 22 de Abril de 2000 02:20
> Para: 'PHP Mailing List'
> Assunto: Need Help On ODBC Connect To Visual Foxpro.
>
> Hi Expert,
>
> I need some help on ODBC function on PHP4. I use PHP ODBC function
> to connect to Visual Foxpro database. It worked !
>
> But when I try to insert the data into my table, it prompt me an
> error.
> I guest this is because of the date data type problem in Vfoxpro.
>
> Any suggestions are welcome.
>
> TIA.
>
> Regards,
> Char
>
> Here is my table structure.
> -----------------------------------
>
> field Data type
> ---------- -------------
> name char(10)
> dob date
>
>
> Here is my source code.
> --------------------------------
> <?
> $connect_paysonel = odbc_connect( 'PAYSONEL' , '', '' );
> if ( !$connect_paysonel)
> {echo "error\n";}
>
> $my_date = '1999-10-10';
> $my_name = 'ABC';
>
> $sql_stmt = "INSERT INTO testing values(\"$my_name\",\"$my_date\")";
>
> $query_paysonel = odbc_exec($connect_paysonel, $sql_stmt);
> ?>
>
> Here is an error.
> -------------------------
>
> Warning: SQL error: [Microsoft][ODBC Visual FoxPro Driver]Data type
> mismatch., SQL state 22005 in SQLExecDirect in
> C:\InetPub\www\IT\odbc_foxpro.php on line 11
>
> Warning: SQL error: , SQL state 00000 in SQLExecDirect in
> C:\InetPub\www\IT\odbc_foxpro.php on line 11
>
>
begin 600 winmail.dat
M>)\^(A<``0:0"``$```````!``$``0>0!
`(````Y`0```````#H``$(
`<`
M&````$E032Y-:6-R;W-O9G0
36%I;"Y.;W1E`#$(`0
`!0`$````````````
M`0D`!``"``````````$%
`,`#
```-`'!``8`!$`*P`S``$`8P$!((`#``X`
M``#0!P0`&``2````%0`!`!L!`0F``0`A````-T8V,T4Y-3$Q-S%!1#0Q,3DX
M-D(P,#8P.3<S0S
V1C(`^08!!(`!`#````!&5SH
3F5E9"!(96QP($]N($]$
M0D,
0V]N;F5C="!4;R!6:7-U86P
1F]X<')O+
!>#P$-
`0``
````(``
`!
M`Y`&`"P,```N`````P`[
`
!
``````P````````$8`````4H4``(YJ`0`>
M`#R`""`&``````#`````````1
````!4A0```0````0````Y+C```P`]
`
M!
``````P````````$8``````84````````+`#Z`""`&``````#`````````
M1
`````#A0````````L`/X`((`8``````,````````!&``````Z%````````
M`P!`
`
!
``````P````````$8`````$(4````````#`$&`""`&``````#`
M````````1
`````1A0````````,`0H`((`8``````,````````!&`````!B%
M````````'
!#
`
!
``````P````````$8`````-H4```$````!````````
M`!X`1(`((`8``````,````````!&`````#>%```!`````0`````````>`$6`
M""`&``````#`````````1
`````XA0```0````$``````````
$)$`$```#$
M!
``P`8``,P,``!,6D9U^>-59P,`"
!R8W!G,3(U%C(`^`M
;
X0,#,SV0[&
M9F4/0
'W(`*D`^,)`
!C:`K`<V5T,!X
!Q,"
P!0$59P<G'^,A)9#E`3*A&_
M`I(/<!2_L1($5&%H`W$"
'T*
-D(R"`["6\.,#4"
`J!;'5C`%`+`V,2\
O$
M(-))!"!T:`0`(`>``Y&`4$A0-"!G;P5`11.
;P)
96T
`B`
P$]$0D,
/PJB
M"H2O'U<;X`%`'
%T!9!T$N10,38
+2&"3P409P\+
`=`!=`'D'-A9V4_(8,?
M%B"4(&$+$R"6:2W(,30T`4!L:24C#-!1)2-B($8#83H,
V([`M$3T$,*P`D`
M!"!!;L!D<EPG93D%T`K`%G$*4`0
306P96ER`&$
6U--5%`ZS&-A!&`I$T!S
M)/`%D((N!;!G+F)R71\5/R90!F`",":V*.$G\&%YSBP24!.
`Q$R-"T``=!!
M+=`
-SHT-QU
37DK1U1O+!<5D!62*TAU#&)J(,$L%U)%4SJ#![$)
"!(96QP
M'J`S'I4(4&YN(,$O`2!6100`=2(Q1F]X'
$NCR,O)#H;Z1\42&DL'Q3L22`5
MH#(P931
!G$)\+YC,B$>!
/P'-`>I"
YP]YM!"``T#D`!!`I.N`G\-T=8RX<
MD"^P"&!L,C`%H,TS1'0SL!S092`LT`&1HF$2$"!B=05`=SU0_0.
:3AQ!9`^
M(#(A/4($</AB8U\^PCZ0!4`BL#-0_RE`/Q(!H`A
//$]42*0!X!U.'!R`V!R
M-*4X(`EP<WT&\'8_(QSQ%9$/(`N`9^D]`G!H,H`S-*<?]P\$_C0A8"=Y/6`H
M?1\4*]$+<.0O0Q(
864?%"G?*N/!'QHB02!V:2S0`S#G*#(%H`1
('4`P!WP
M"L#.=$P"`0`=\&]K!)`M`),]T$O
97H'D79O.0#_';``<!6
3(),T4T2+0`>
M4GL^("E`<RT`.*%-H4^%)RYF/%`#(!AP=1(0)R#R(C2E17A0D4P`,[!-H<PB
M51Y
/1!K("(
+[#Y&U!A(A\5#P<4
RV`-+_S)#HE<#,V$D`#,`\$5B'_%K,A
M5B)
`(`BH1YA(>4BWYM7#R3Y."W0)=A$93'
OR],*6`;TSQ0'1`+<&P]$*,I
MP"_30&UC.L`N3)$W(#,\4!)`70KC*X-%;E]+\#A0*5`>4"P74R
A,=\]P%-P
M+:$3T$VA02L0`Q&W3:$MPUC
.C<6)D%0"L!Z82P7)QUQ*&$#$$0"3*D$`'0G
M*T=!!!!U`C`_+R
R#S,?-"];?U=]7&[Z;P/P9"#0:O`P`55-$D#W-Y!B\#B2
M=#>U'Q188'+Q_S
:]!JH4+P0<$]4&KQ'H;_4=`X\$U0'H$>
3NV4D$=8O]T
M?!\4/1$\F6Q;/7<[\3XQUP6P3?!JL"%R/T(^(3Y$^S
4)!Y/0(+
!(0`"`]
M-_M]`3T1;7S!`:`>0"T`0#&]'
%M!3%!P0.10?QG*+%704(<\1SQ8
608782
M;^9F/39]I71Y.*`=]PN`?VQ``A!L[W+R)^!\P&QP9]\BL&C`=2$ZT4<1=VK
M3)'C>?!ZWU1)032F##!H47M),#&"94\
"R!0P'*70_]?DHCG<J<L8FK01Q$<
M\GYU]T&04)`;4'0(<(=V<O(A
_^/3Y`KAY\#,!OB##)N!P$PWW3`")`\8"`S
M)Q%I(&D3T/UR\D2#%G*9D"B.WG*9(B#70<%R\Q62*`]`*7*94W#_)E";)H*R
M'Q]RXXRY0O`(<#].\06
`0".7Y^_E^\
/*L?!5A
)#R57PJP>4+P6VO0`R`]
M/X0\E2AGP4'`65-/3D5,4G`M`.0G)Z5B("D9L'*E!I#/.E!ZL**?FCI<>P60
M&'"[6'$_H&PHH""A0>1<;[!7`!"I5QFP?9$\)'Y
7\^"LZ.P6&*IA#$YK8`E
M$/XPK;$`$*JVJ[F9(Z.PK/8.01[0KAVB%W-Q;%\=:,!M!4"OLJE724Y3R$52
M5+-15$\<P(92[401=
=`*+$HJC"J::\F_[4;-["U+INSM2J:,*IZJUSO**%\
ML*,?/L(HIO\M`+'W]Z7P8F4>\#Z<7XS%?]V?/_N
ORM'5PK``P`/("QB,>"8
M4U%,0>0QX%M-#>!G`V!"\`&`75L>LVQ84/UY440%$$,
*R"5EQT0!`#U`,!T
M%9`N+0#%0FC`
L)[9.`MT#6$$L5!4Q`%D$0O*3!KXH0A)D%#)K!<2=EKT'10
M,,"J,'?,X,PQ_E2J,#^3A&5$<2QB'G*)<OW+TC&2
252B9&)=,1OQ7;_R8HM
MT2WARJ_+O\S/S=_.Z2]RI2M&-R48T0#9L`,`+
``````"P`"``$````>`'``
M`0```"P```!.965D($AE;'`
3VX
3T1"0R!#;VYN96-T(%1O(%9I<W5A;"!&
M;WAP<F\N``(!<0`!````(`````&_K!ICZ5P-OC(8"Q'4D>L`H"3H<8L`<AEV
M8``8ZY0
"P`7#``````#`%U``````$``.0">6L/Q1JZ_`0,`\3\)!```'
`Q
M0`$````O````+T\]34E#4D].+T]5/4--4S`S+T-./4580TA!3D=%(%5315)3
M+T-./4-(0TA!4
```P`:0``````>`#!``0```"\````O3SU-24-23TXO3U4]
M0TU3,#,O0TX]15A#2$%.1T4
55-%4E,O0TX]0TA#2$%2```#`!E```````,`
M_3_D!````P`F```````#`#8```````,`
!#_____`
%'``$````S````8SU5
M4SMA/2`[<#U-:6-R;VX[;#U?0TU3,#-%6$-(,2TP,#`T,C0R,S0S-3%:+3,P
M-3<```(!^3\!````2P````````#<IT#(P$(0&K2Y"``K+^&"`0`````````O
M3SU-24-23TXO3U4]0TU3,#,O0TX]15A#2$%.1T4
55-%4E,O0TX]0TA#2$%2
M```>`/
_`0````<```!C:&-H87(``!X`.$`!````+P```"]//4U)0U)/3B]/
M53U#35,P,R]#3CU%6$-(04Y'12!54T524R]#3CU#2$-(05(```(!^S\!````
M2P````````#<IT#(P$(0&K2Y"``K+^&"`0`````````O3SU-24-23TXO3U4]
M0TU3,#,O0TX]15A#2$%.1T4
55-%4E,O0TX]0TA#2$%2```>`/H_`0````<`
M``!C:&-H87(``!X`.4`!````+P```"]//4U)0U)/3B]/53U#35,P,R]#3CU%
M6$-(04Y'12!54T524R]#3CU#2$-(05(``$``!S!2,3!X1JZ_`4``"#!,H<D_
M2:Z_`1X`/0`!````!0```$97.B``````'
`=#
$````L````3F5E9"!(96QP
M($]N($]$0D,
0V]N;F5C="!4;R!6:7-U86P
1F]X<')O+
`+`"D```````L`
M(P```````P`&$"7[7,`#``<0#
8```,`$!```````P`1$`(````>``
0`0``
M`&4```!)4U1(25--14%.4$A0-$=/5%!23T),14U/3D]$0D,_+2TM+2U/4DE'
M24Y!3$U%4U-!1T4M+2TM+4923TTZ0T%23$]304Y$4D5-05)1545334]214E2
505--5%`Z0T%-3U)%25)!``````!H
`
end
attached mail follows:
I have a background in ASP, but, I am new to PHP. I have seen from reading through this mailing list that sessions can be managed through the use of text files or temporary storage in a database.
I would like to know if anyone has come up with a way to assign a session variable to memory, and find the memory address from another script. I know there used to be a process similar to this when running a C program on (at least some flavors of) Unix. You would basically reserve a chunk of memory, and add a keyword to it. Then calling this key word from another procedure would allow you access to the same variables. Is there anything like this in PHP? I want to know for two reasons:
1)reading/writing to a text file or database is slow. 2)you cannot store arrays or (ASP word) Dictionary objects in a text file very easily.
Thanks for your help. Adam Erickson Software Engineer Class.com
_______________________________________________________ Get 100% FREE Internet Access powered by Excite Visit http://freelane.excite.com/freeisp
attached mail follows:
Use the 'mm' session module to store your sessions in shared memory:
session_module_name("mm");
This is unfortunately not very well documented yet.
-Rasmus
On Mon, 24 Apr 2000, vader seventy-seven wrote:
> I have a background in ASP, but, I am new to PHP. I have seen from reading
> through this mailing list that sessions can be managed through the use of
> text files or temporary storage in a database.
>
> I would like to know if anyone has come up with a way to assign a session
> variable to memory, and find the memory address from another script. I know
> there used to be a process similar to this when running a C program on (at
> least some flavors of) Unix. You would basically reserve a chunk of memory,
> and add a keyword to it. Then calling this key word from another procedure
> would allow you access to the same variables. Is there anything like this
> in PHP? I want to know for two reasons:
>
> 1)reading/writing to a text file or database is slow.
> 2)you cannot store arrays or (ASP word) Dictionary objects in a text file
> very easily.
>
> Thanks for your help.
> Adam Erickson
> Software Engineer
> Class.com
>
>
>
>
>
> _______________________________________________________
> Get 100% FREE Internet Access powered by Excite
> Visit http://freelane.excite.com/freeisp
>
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
>
>
attached mail follows:
> there used to be a process similar to this when running a C program on (at > least some flavors of) Unix. You would basically reserve a chunk > of memory, > and add a keyword to it. Then calling this key word from another > procedure
It's called shared memory. See http://www.php.net/manual/ref.sem.php
> > 1)reading/writing to a text file or database is slow.
Not necessarily that slow. Reading and writing to a database is often faster than reading and writing to disk (but obviosly not as fast as writing to memory). Also, some operating systems have support for a memory based disk (or something pretty close). For example, /tmp in Solaris is actually allocated in memory/swap and accessing files stored there is VERY fast. That's what we do, store session info in /tmp on Solaris.
> 2)you cannot store arrays or (ASP word) Dictionary objects in a text file > very easily. >
Actaully, this is relatively easy with the serialize function.
See
http://www.php.net/manual/function.serialize.php3
attached mail follows:
Hello,
I am about to start writing a new project in PHP, and before I begin reinventing the wheel (or, rather, the multiple wheels, bells and whistles which this project requires), I wanted to find out if there is an existing project similar to this which I can use for inspiration/borrowing code. I've looked on www.php.net/projects.php3, and some of them are similar, but need multiple adjustments, and I don't feel like gunzip-ing and looking through every one of them. Anyway, here's what the project is supposed to do, briefly:
1. Admin:Manage group/user time allocations on a large computing network. An administrator should be able to add/delete CPU time allocated to every group, copy "left-over" time from previous sessions, change passwords, add users etc.
2. Group manager should be able to view how much time his group has, add/update/delete users "attached" to his group (mostly address information), *maybe* change user's passwords.
3. Support interface: should something go wrong, telephone support people should be able to log in and change a particular user's info/password.
Obviously, this would require an authentication mechanism which would identify a user as belogning to one of the three categories and give him the appropriate privileges. The database is Oracle 8. I've got PHP 3.0.11 and PHPLIB installed on my Solaris box with Apache as Web server.
Thanks for you suggestions !
Mikhail
attached mail follows:
Folks,
Having read Rasmus' piece on PHP Builder <http://www.phpbuilder.com/columns/rasmus19990407.php3> regarding the ForceType directive in Apache, I need a little help with something. This is more of an Apache question than a PHP question, but I'm not on the Apache mailing list... :)
I want an entire domain to be affected by ForceType, which is cool if I wrap it in Location tags. But then other files (ie, images) are treated as PHP. What I really want is to be able to 'invent' directories off of the root, and have those handled by PHP. But real ones should be left alone.
So /images/ and /about/ need to just be cool and be fed out normally. But if I enter http://web.domain.tld/look/at/all/of/my/directories, I want the server to create that.
I see 3 options:
1. Make a 404 page that takes care of 'creating' the dynamic directory structure. 2. Put the dynamic directories under a master directory (aside from /), such as /dynamic/. 3. Keep all images and other pages under subdomains. Instead of web.domain.tld/images, use images.domain.tld.
What do y'all think? Am I missing something obvious?
Thanks!
Best, Waldo
attached mail follows:
Hello,
I need to execute scripts contained in several different files, and need to pass arguments to each of these scripts.
Say I have a script called something.php3, as it is displayed on a browser, it should call 5 other scripts sending each one parameters, but I don't want anything to be displayed about the execution of these scripts...how can I do this ?
I looked up exec(), system(), etc. on php.net but couldn't find how...
Thanks,
Thomas.
attached mail follows:
i would like to parse a page of HTML. here is the snippet that's relevant. spaces (indents) etc are exactly as they should be. how would you go about parsing this? would it be easiest to use preg_match_all or explode the line and use eregi? for the OPTIONS below, i would like to get the VALUE and the name of each option. Note that the first option is after the select tag which has the selected tag included.
---cut <select name=cid size=5><option VALUE="1367" selected>Zinc (Wholesale) <option VALUE="11419">Zinc Oxide (Manufacturers) <option VALUE="11454">Zinc Oxide-Manufacturers <option VALUE="12425">Zipper Machinery (Manufacturers) <option VALUE="946">Zippers (Wholesale) <option VALUE="13115">Zippers-Manufacturers <option VALUE="16141">Zippers-Repairing <option VALUE="11891">Zirconium (Manufacturers) <option VALUE="17936">Zoning Consultants <option VALUE="2052">Zoos </select> ---end cut---
attached mail follows:
Hi. Does anyone know where I can download the PHPMySQL package? It's a set of web pages that allows you to manage a MySQL database through a web interface. From what I understand, it's all done in PHP. I've searched the MySQL site, the PHP site, and the list archives. I found something that looked similar by a guy named Klaus, but I don't really think that's it because it mentioned Perl Scripts and I'm pretty sure this is just a bunch of HTML Text documents with PHP script in them to manipulate the database.
Anybody know where I can download that?
Thanks in advance for your time and assistance.
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Diana "Will work for chocolate"
diana
vivaladata.com (and it's worth every byte)
http://www.vivaladata.com
attached mail follows:
On Mon, 24 Apr 2000, Diana Cassady wrote:
> Hi. Does anyone know where I can download the PHPMySQL package?
Hi Diana--
http://phpwizard.net/phpMyAdmin/
michael
attached mail follows:
It's www.mysql.com itself.........Check the download section. -- K
----- Original Message -----
From: Diana Cassady <diana
vivaladata.com>
To: <php3
lists.php.net>
Sent: Tuesday, April 25, 2000 7:06 AM
Subject: [PHP3] Where is PHPMySQL Admin?
> Hi. Does anyone know where I can download the PHPMySQL package? It's
> a set of web pages that allows you to manage a MySQL database through
> a web interface. From what I understand, it's all done in PHP. I've
> searched the MySQL site, the PHP site, and the list archives. I found
> something that looked similar by a guy named Klaus, but I don't
> really think that's it because it mentioned Perl Scripts and I'm
> pretty sure this is just a bunch of HTML Text documents with PHP
> script in them to manipulate the database.
>
> Anybody know where I can download that?
>
> Thanks in advance for your time and assistance.
> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
> Diana "Will work for chocolate"
> diana
vivaladata.com (and it's worth every byte)
> http://www.vivaladata.com
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
>
attached mail follows:
Dear everyone, does anyone know how to pop out 'SAVE AS'dialog when user clicks the "save"button and save into textfile to his own hard-drive? Probably use header? any documentation,please guide
Thanks in advance
Hendry Sumilo
IT department
Telp:04-6302622
MCMS Penang
hendry
mcms.com
attached mail follows:
Hi,
I am trying to build a shopping cart that is able to add and remove multiple products before checking out and send an E-mail to the seller.
Problems : 1. How do I add rows into a table depending on the number of items placed into the cart? Lets say 3 items placed into cart will create 3 rows, and 9 items placed into cart will create 9 rows automatically?
2. Is there a function to remove only a particular variable and replace with another value? Say item[1], item[2], item[3]... I want to remove item[2]. After clicking remove, item[2] will be removed and item[3] will become item[2].
Please advice thanks.
-------------------------------------------------------------- The Oikoses [Your Web Resources]
10, Anson Road #18-18, International Plaza, Singapore 079903
Fax: (65) 565-5320 http://www.theoikoses.com --------------------------------------------------------------
attached mail follows:
How do you include a file from another domain? I want to put my db connection info in an include file and place it on a secure server which has a different domain name so know one can access the logon info. I want to keep some credit card info in a table. Is this how you secure your db info from people logging onto the server thru FTP, or is there a better way.
I would appreciate any help and thank you in advance. Clint
attached mail follows:
I think you want to look at http://www.php.net/manual/features.remote-files.php and http://www.php.net/manual/function.include.php for info on how you want to protect your include files.
But no, that's not how it is usually done. Usually, one would configure the web server to not show files that end in .inc (or whatever you want your include files to end with). I know that with Apache, you would just put something like this in httpd.conf (for server-wide configuration) or .htaccess (for directory-by-directory configuration):
<FILES ~ "\.inc$"> Order allow,deny Allow from 127.0.0.1 Deny from all </FILES> <FILES ~ "\~$"> Order allow,deny Allow from 127.0.0.1 Deny from all </FILES>
The first directive disallows any files to be shown by Apache that end in .inc. The second disallows any files to be shown by Apache that end with a tilde (squiggle), as some editors make backup copies of files that end with a tilde when you edit them.
Doug
At 07:15 PM 4/24/00 -0700, Clint Skidmore wrote: >How do you include a file from another domain? >I want to put my db connection info in an include file and place it on a >secure server which has a different domain name so know one can access >the logon info. I want to keep some credit card info in a table. >Is this how you secure your db info from people logging onto the server >thru FTP, or is there a better way. > >I would appreciate any help and thank you in advance. >Clint >
attached mail follows:
I am getting the following error while playing with fsockopen()
Warning: Wrong parameter count for fsockopen()
I am using the exact same code from the online manual. The code is below.
$fp = fsockopen("www.php.net", 80, &$errno, &$errstr, 30); if(!$fp) { echo "$errstr ($errno)<br>\n"; } else { fputs($fp,"GET / HTTP/1.0\n\n"); while(!feof($fp)) { echo fgets($fp,128); } fclose($fp); }
Thanks
CDitty
attached mail follows:
Hi,
What version of PHP are you using? 3.0.X ?
I think some of those extra args were added later on in the piece.
Matta
CDitty wrote:
>
> I am getting the following error while playing with fsockopen()
>
> Warning: Wrong parameter count for fsockopen()
>
> I am using the exact same code from the online manual. The code is below.
>
> $fp = fsockopen("www.php.net", 80, &$errno, &$errstr, 30);
> if(!$fp) { echo "$errstr ($errno)<br>\n";
> } else {
> fputs($fp,"GET / HTTP/1.0\n\n");
> while(!feof($fp)) { echo fgets($fp,128);
> }
> fclose($fp);
> }
>
> Thanks
>
> CDitty
>
> --
> PHP 3 Mailing List <http://www.php.net/>
> To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net
> To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
-- Matt Allen Linux/PHP eCommerce Solutions Linux Worx Linux Networking www.linuxworx.com.au Consulting mattlinuxworx.com.au 0413 777 771
attached mail follows:
3.0.7. The first comment says that it worked with that version. Strange.
CDitty
At 10:06 PM 4/24/00 , Matt Allen wrote:
>Hi,
>
>What version of PHP are you using? 3.0.X ?
>
>I think some of those extra args were added later on in the piece.
>
>Matta
>
>CDitty wrote:
> >
> > I am getting the following error while playing with fsockopen()
> >
> > Warning: Wrong parameter count for fsockopen()
> >
> > I am using the exact same code from the online manual. The code is below.
> >
> > $fp = fsockopen("www.php.net", 80, &$errno, &$errstr, 30);
> > if(!$fp) { echo "$errstr ($errno)<br>\n";
> > } else {
> > fputs($fp,"GET / HTTP/1.0\n\n");
> > while(!feof($fp)) { echo fgets($fp,128);
> > }
> > fclose($fp);
> > }
> >
> > Thanks
> >
> > CDitty
> >
> > --
> > PHP 3 Mailing List <http://www.php.net/>
> > To unsubscribe, send an empty message to php3-unsubscribe
lists.php.net
> > To subscribe to the digest, e-mail: php3-digest-subscribe
lists.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-admin
lists.php.net
>
>--
>Matt Allen Linux/PHP eCommerce
>Solutions
>Linux Worx Linux Networking
>www.linuxworx.com.au Consulting
>matt
linuxworx.com.au
>0413 777 771
attached mail follows:
I am attempting to write a PHP script that takes an array of filenames, runs them through a zip filter, and returns the result to the client as if it were an existing zip file (in short, I'm looking for a way to allow my customers to download multiple files at once). I'm using the most recent version of PHP 3.x, running under Red Hat Linux. How would one go about doing this?
- Next message: php3-digest-help
lists.php.net: "php3 Digest 25 Apr 2000 23:54:04 -0000 Issue 1629"
- Previous message: php3-digest-help
lists.php.net: "php3 Digest 24 Apr 2000 16:57:44 -0000 Issue 1627"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]