Re: [PHP] Grabbing ALL $_POST var at once.

2002-05-06 Thread Miguel Cruz
On Mon, 6 May 2002, David J Jackson wrote: > Thanks for your reply, but let me rephase the question. > Let say I have a form with 50 fields on it do I have to: > > echo $_POST['one'] > > . > . > echo $POST['fifty'] > > > Or should I, could I use extract()? You can use extract if y

Re: [PHP] Grabbing ALL $_POST var at once.

2002-05-06 Thread Kevin Stone
Do you simply need to view all of the values passed through the form? In that case try something like.. foreach ($_POST as $name => $value) { echo $name." : ".$value.""; } -Kevin - Original Message - From: "David J Jackson" <[EMAIL PROTECTED]> To: "1LT John W. Holmes" <[EMAIL PROTE

Re: [PHP] Grabbing ALL $_POST var at once.

2002-05-06 Thread 1LT John W. Holmes
extract() wouldn't do you any good here, you'd still have to use echo $one, echo $two, etc...so what are you gaining? If you just want the values displayed, use the foreach() method someone already posted. You can use implode() to combine the whole array in to a single string...if you need someth

[PHP] Sorting, sort of

2002-05-06 Thread Jason Soza
I have a 'name' field in a MySQL table that contains people's first and last names, i.e. "John Smith" - but some people may choose not to include their last name, so they're just "John" in the table, or they may choose to include themselves and someone else, but not the last name, "John and Ja

Re: [PHP] Sorting, sort of

2002-05-06 Thread Analysis & Solutions
On Mon, May 06, 2002 at 11:25:03AM -0800, Jason Soza wrote: > I have a 'name' field in a MySQL table that contains people's first and > last names, > ... snip ... > I'm thinking the easiest way to sort by last name, which is what I want > to do, is to just go into MySQL and make 'first_name' and

[PHP] Re: Sorting, sort of

2002-05-06 Thread Austin Marshall
Jason Soza wrote: > I have a 'name' field in a MySQL table that contains people's first and > last names, i.e. "John Smith" - but some people may choose not to > include their last name, so they're just "John" in the table, or they > may choose to include themselves and someone else, but not th

Re: [PHP] Sorting, sort of

2002-05-06 Thread 1LT John W. Holmes
You _definetly_ want to do this in your database, not with PHP and arrays. Databases are made to do this kind of sorting for you. I would modify your table first, adding in another column for first_name, then modify your form so that all data going in from now on is correct. The hard part will be

Re: [PHP] Sorting, sort of

2002-05-06 Thread Tyler Longren
Hi Jason, I'd just get it over with and make first_name and last_name fields in your table. It will be so much easier to sort by last name that way. I do it this way everytime. It won't take much time to implement either. Good luck, Tyler Longren Captain Jack Communications [EMAIL PROTECTED]

Re: [PHP] Grabbing ALL $_POST var at once.

2002-05-06 Thread Philip Olson
As you know, $_POST exists. You can also assign groups of names to an array through your HTML form like so: ... And then play with them, for example: extract($_POST['bar']); print "I say $name and $doh"; extract($_POST['bar'], EXTR_PREFIX_ALL, 'bar'); print "I say $bar_name a

Re: [PHP] Sorting, sort of

2002-05-06 Thread Jason Soza
It's actually not that large of a table, but it'll still be a PITA to get all of the data reinserted. I have about 50 records with the following fields: 'gen', 'year', 'color', 'name', 'email', 'location', 'misc', 'pic1', 'pi c2', 'pic3', 'pic4' So basically, I guess I want to rename 'name' to

Re: [PHP] Sorting, sort of

2002-05-06 Thread 1LT John W. Holmes
Yeah, just dump it, edit it, and import it back into a table. 50 records shouldn't take you to long. You'll thank yourself later.. :) ---John Holmes... - Original Message - From: "Jason Soza" <[EMAIL PROTECTED]> To: "1LT John W. Holmes" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: M

[PHP] question with sockets and XML

2002-05-06 Thread Michael Geier
Hi all, I have to do the following: open a socket to an external server authenticate on that server begin retrieving articles and write to local files I am able to connect the server via Net/Sockets.php and authenticate. Now the tricky part...the data is fed via an XML f

[PHP] escaping quotes in forms and redisplaying variables in form fields

2002-05-06 Thread John Hughes
I'm stumbling over how to allow people to put single or double quotes in a form text field. I am passing the form to itself ($PHP_SELF) and on the second time through previewing what the form data will look like and also re-creating the form with the data already filled in. Here's an example of

Re: [PHP] escaping quotes in forms and redisplaying variables in form fields

2002-05-06 Thread Robert Cummings
See: http://www.php.net/manual/en/function.htmlspecialchars.php John Hughes wrote: > > I'm stumbling over how to allow people to put single or double quotes > in a form text field. > > I am passing the form to itself ($PHP_SELF) and on the second time > through previewing what the form data wil

Re: [PHP] escaping quotes in forms and redisplaying variables in form fields

2002-05-06 Thread 1LT John W. Holmes
Yeah, you have to convert the single and double quotes to html entities so they are not mistaken for the end of the string. If you look at your source code, you'll see why it's happening. value = 'O'Bryan' value = "Joe "Bruiser" Smith" You can see how the 'O' is taken as the string, and the res

Re: [PHP] Re: Very Large MySQL Query String

2002-05-06 Thread David Bouw
Dear Kirk (and Julio) Thanks for the response.. I don't want to use a link to the images because backing up my data and porting it to another machine is much easier. (Replicating is also very easy.) When storing the file separately this gets more complex, especially when you want to get this dat

Re: [PHP] Re: Very Large MySQL Query String

2002-05-06 Thread Javier
Hi, I think if you encode the file with base64 and store it in the database the size of the document will be more than 1MB sure. David Bouw wrote: > Dear Kirk (and Julio) > > Thanks for the response.. > > I don't want to use a link to the images because backing up my data and > porting it to an

[PHP] LDAP

2002-05-06 Thread J. Anderson Scarbrough
Is it possible to modify the password attribute in LDAP? I am the netscape directory server for authentication, but would like to allow the user to change their own password. When I search for a user and get the attibutes for that user password is not available. Am I missing something here?

[PHP] Alternate To Making Form Variables Global

2002-05-06 Thread Dr. Shim
Is there another way then to register form variables global? I just downloaded, and instlaled the newest version of PHP, and now my form script doesn't work anymore. I had to register the form variables global in the script. I'm asking, is there a better way of doing this? I've herd it can lead t

[PHP] Alternate To Making Form Variables Global (Clerified)

2002-05-06 Thread Dr. Shim
Sorry, I'll have to clerify myself a bit. I'm rather tired. :) I have a script that verifys and inserts (into and Access databse) form values. I had to make the form variables "global", in order to use them in my functions. Since the new PHP is out, the script doesn't work anymore. I think its pr

[PHP] Re: Alternate To Making Form Variables Global (Clerified)

2002-05-06 Thread Julio Nobrega Trabalhando
This is not the global that is meant on the update. Not the global $var that you put inside your functions. That's scope, btw. You are making a variable available inside a different scope (the function), by making it "global". The global you are searching for is, like when you submit a for

RE: [PHP] LDAP

2002-05-06 Thread Jon Wahl
Sounds like desired behavior to me. I would think that you may be able to change the password, but aren't allowed to retrieve its value. Cheers > -Original Message- > From: J. Anderson Scarbrough [mailto:[EMAIL PROTECTED]] > Sent: Monday, May 06, 2002 3:03 PM > To: [EMAIL PROTECTED] > S

[PHP] Re: Alternate To Making Form Variables Global (Clerified)

2002-05-06 Thread Austin Marshall
Dr. Shim wrote: > Sorry, I'll have to clerify myself a bit. I'm rather tired. :) > > I have a script that verifys and inserts (into and Access databse) form > values. I had to make the form variables "global", in order to use them in > my functions. Since the new PHP is out, the script doesn't wo

[PHP] Linux and permissions

2002-05-06 Thread Todd Cary
My PHP scripts are in a directory, "php". The owner of the directory is "root" and the group is "apache". Other has no rights. Group has rx rights. All works well *except* the surfer can view the directory of the php directory *and* copy the files. What have I missed?? Todd -- Todd Cary Ari

RE: [PHP] Linux and permissions

2002-05-06 Thread Craig Vincent
> My PHP scripts are in a directory, "php". The owner of the > directory is "root" > and the group is "apache". Other has no rights. > > Group has rx rights. All works well *except* the surfer can view > the directory > of the php directory *and* copy the files. It means that DirectoryIndexing

Re: [PHP] Linux and permissions

2002-05-06 Thread Todd Cary
Craig - Thank you for the quick response. I do not see an entry in httpd.conf for DirectoryIndexing. Am I missing something? Todd -- Todd Cary Ariste Software 2200 D Street Extension Petaluma, CA 94952 707-773-4523 [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To uns

[PHP] Re: Alternate To Making Form Variables Global (Clerified)

2002-05-06 Thread Dr. Shim
Thank you so much Austin, and Julio! Your replies are an amazing help to me. Thanks! Maybe I'll even get this project I'm working on done this week. =) Anyhoo, Julio, you mean that option in the PHP.INI, is it "register_globals"? Well, anyhow, I'm going to "convert" my script, as you put it. Aga

RE: [PHP] Formatting Information in header? Gridlines in Excel

2002-05-06 Thread David Freeman
> -Original Message- > Can someone tell me where to find the various options for > the Header function as it relates to M$ Excel? > -Original Message- As far as I know, you can't. Headers are for html/http information not for any particular "helper application". If you wan

[PHP] file_exists

2002-05-06 Thread Craig Westerman
What am I doing wrong? I get parse error between first echo statement and else. Thanks Craig ><> [EMAIL PROTECTED] "; else echo ""; } ?> -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] Sorting, sort of

2002-05-06 Thread David Freeman
> -Original Message- > I have about 50 records with the following fields: > 'gen', 'year', 'color', 'name', 'email', 'location', 'misc', > 'pic1', 'pi c2', 'pic3', 'pic4' > -Original Message- If you're going to be changing your database, you might also consider what to do w

RE: [PHP] File upload problem

2002-05-06 Thread David Freeman
> -Original Message- > D'oh! You're right, I went back and checked php.ini and > found upload_max_filesize but it's already set to 200M, I'm > assuming that means 200 MegaBytes. So I don't think that's > the problem. I don't have the hidden tag set in the page > code so that

RE: [PHP] Redirect after submit

2002-05-06 Thread David Freeman
> -Original Message- > I have a page that contains multi If ElseIf statements. I > want to redirect right after a user submits gets a message > (echo "Entry Added to Database. \n"; ) would you like to > add another. then prompts for an alert. Would you like > another ??? and

RE: [PHP] --enabel-pnctl / php sockets

2002-05-06 Thread Barry Smoke
After further research, (reading the redhat php spec file completely) I discovered how they were making it, so that php binaries, and apache php module was working at the same time... The rpm builds the cgi root, and installs it, and the builds the apache root, and installs that over the cgi inst

[PHP] Is the browser still open? if not then I want to kill the script

2002-05-06 Thread Jarrad Kabral
Hi all I have a script that does a lot of harddrive access and runs for a while, at the moment if the user closes his/her browser half way through, the script continues and the harddrive keeps going crazy.is there a way like in ASP to check that the browser is still open and connected?? Reg

Re: [PHP] Linux and permissions

2002-05-06 Thread Paras Mukadam
search for "DirectoryIndex" and delete DirectoryIndex entry given below it. "Todd Cary" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Craig - > > Thank you for the quick response. I do not see an entry in httpd.conf for > DirectoryIndexing. Am I missing som

[PHP] Re: file_exists

2002-05-06 Thread Austin Marshall
Craig Westerman wrote: > What am I doing wrong? I get parse error between first echo statement and > else. > > Thanks > > Craig ><> > [EMAIL PROTECTED] > > > $fn = "image.gif"; > if (!file_exists($fn)) { > echo ""; > else > echo ""; > } > ?> > You've got your semicolons in the wrong spots.

RE: [PHP] file_exists

2002-05-06 Thread Craig Westerman
I found my problem. >From manual: "file_exists() will not work on remote files; the file to be examined must be accessible via the server's filesystem. " File is on another server. Is there a way to check if file exists on another server? Craig ><> [EMAIL PROTECTED] -Original Message-

Re: [PHP] file_exists

2002-05-06 Thread Austin Marshall
Craig Westerman wrote: > I found my problem. Try fopen() if it fails it will return false, otherwise it will return an integer file pointer. You get use it to fetch files via http://, https://, ftp://, and more. > > From manual: > "file_exists() will not work on remote files; the file to be e

RE: [PHP] Is the browser still open? if not then I want to kill the script

2002-05-06 Thread John Holmes
Yep... http://www.php.net/manual/en/features.connection-handling.php ---John Holmes... > -Original Message- > From: Jarrad Kabral [mailto:[EMAIL PROTECTED]] > Sent: Monday, May 06, 2002 6:16 PM > To: [EMAIL PROTECTED] > Subject: [PHP] Is the browser still open? if not then I want to kil

RE: [PHP] file_exists

2002-05-06 Thread Jonathan Rosenberg
Does fopen() actually work for https connections? I thought this implementation was not yet released. > -Original Message- > From: Austin Marshall [mailto:[EMAIL PROTECTED]] > Sent: Monday, May 06, 2002 9:40 PM > To: Craig Westerman > Cc: php-general-list > Subject: Re: [PHP] file_exists

Re: [PHP] Formatting Information in header? Gridlines in Excel

2002-05-06 Thread Paul Roberts
strange i just worked this out over the weekend. I'm going to be use it to email data that will be inserted into an excel sheet you just tell it the html file is a xls file in the mime headers and it opens the file up in excel, no problem and no messing with csv files, comas, xml support and a

[PHP] Free Hosting /w PHP/MySQL {!?}

2002-05-06 Thread Liam MacKenzie
Free hosting for PHP Developers. As many MySQL Databases as you need PHP with all the bits http://scripts.operationenigma.net/phpinfo.php FTP Access Subdomain or Your own Domain Tech Support over MSN if needed 98% Uptime 512/512 Connection based in Brisbane, Australia Only catch is that I can't

Re: [PHP] PHP compared to JSP

2002-05-06 Thread Manuel Lemos
Hello, SP wrote: > Thanks dude I'll take a look at it. How do you get around caching only certain >parts of a > page? No problem, just capture all the page output in a variable and feed it to the class. Regards, Manuel Lemos > > -Original Message- > From: Manuel Lemos [mailto:[EMA

Re: [PHP] file_exists

2002-05-06 Thread Miguel Cruz
On Mon, 6 May 2002, Craig Westerman wrote: > What am I doing wrong? I get parse error between first echo statement and > else. > > $fn = "image.gif"; > if (!file_exists($fn)) { > echo ""; > else > echo ""; > } > ?> You open the brace for the positive branch of the if and then leave it open sur

[PHP] Where is the file php_mssql.dll?

2002-05-06 Thread Jim Wentz
I want to add the extension to the PHP server and I realize that I need to modify the php.ini file for that extension. However, I cannot find that file. Also, where should that file be placed?

RE: [PHP] file_exists

2002-05-06 Thread Rasmus Lerdorf
Not until 4.3. On Mon, 6 May 2002, Jonathan Rosenberg wrote: > Does fopen() actually work for https connections? I thought this > implementation was not yet released. > > > -Original Message- > > From: Austin Marshall [mailto:[EMAIL PROTECTED]] > > Sent: Monday, May 06, 2002 9:40 PM > >

Re: [PHP] File upload problem

2002-05-06 Thread Jason Wong
On Tuesday 07 May 2002 09:01, David Freeman wrote: > > -Original Message- > > D'oh! You're right, I went back and checked php.ini and > > found upload_max_filesize but it's already set to 200M, I'm > > assuming that means 200 MegaBytes. So I don't think that's > > the problem. I do

RE: [PHP] Variables from XML Documents

2002-05-06 Thread Sebastian A.
The parsing is not the problem. I am already using the PHP XML parser, but the problem is that it I cannot get the content of elements into variables like I already stated. Does no one know how to do this? -Original Message- From: Analysis & Solutions [mailto:[EMAIL PROTECTED]] Sent: Mond

Re: [PHP] Variables from XML Documents

2002-05-06 Thread Analysis & Solutions
Sebastian: On Tue, May 07, 2002 at 07:06:18AM +0200, Sebastian A. wrote: > The parsing is not the problem. I am already using the PHP XML parser, but > the problem is that it I cannot get the content of elements into variables > like I already stated. Does no one know how to do this? You are do

RE: [PHP] Variables from XML Documents

2002-05-06 Thread Martin Towell
look at xml_set_character_data_handler() it works fine for me xml_parser = xml_parser_create(); xml_set_object($this->xml_parser, $this); xml_set_element_handler($this->xml_parser, "start_element", "end_element"); xml_set_character_data_handler($this->xml_parser, "character_data");

RE: [PHP] File upload problem

2002-05-06 Thread David Freeman
> -Original Message- > I'm curious, I keep seeing people say that that tag is > /necessary/, but I've never had to use it in the upload forms > that I've built and they work just fine in Opera, NN & IE. Good question. To be honest it's been a while since I looked, I built a file

RE: [PHP] file_exists

2002-05-06 Thread Stuart Dallas
On 6 May 2002 at 20:30, Craig Westerman wrote: > File is on another server. Is there a way to check if file exists on > another server? I wrote the following function a while ago to do this. It works with http URLs and should also work with https and ftp, but I have only tested http. I hope it'

php-general Digest 7 May 2002 06:58:51 -0000 Issue 1330

2002-05-06 Thread php-general-digest-help
php-general Digest 7 May 2002 06:58:51 - Issue 1330 Topics (messages 96302 through 96359): Re: Grabbing ALL $_POST var at once. 96302 by: Rasmus Lerdorf 96303 by: Miguel Cruz 96305 by: 1LT John W. Holmes 96306 by: David J Jackson 96307 by: David J Jac

<    1   2