[PHP] Parse error with simple script

2001-05-16 Thread Mohamed LRHAZI
Hello All, I am sure this is simple, but I really cant figure it out by myself.. at least not tonight :) This simple script gives : Parse error: parse error in /var/www/html/test.php on line 2 # cat /var/www/html/test.php If I comment (//) line 2, it works and the hello shows up. If I replace

[PHP] Netscape problem with $PHP_SELF?do_something

2001-05-16 Thread Jaeggi David
Hello everybody! I have a problem that a script is not working with netscape. The script is shown here: echo "goto add";` //Link if ($argv[0] == "add";//The Link jumps to this point of the script [do something] It's perfectly working with the internet explorer. with netscape (newes

[PHP] Comparative table

2001-05-16 Thread Jreniz
Hello people!!! I'm looking for a comparative table between PHP, ASP y PERL or another script languages. Where can I find one???

Re: [PHP] way to protect .php file

2001-05-16 Thread B. van Ouwerkerk
>and then on another note, why do you have users on a webserver who >aren't developers??? Cause most people aren't.. but they want to create their own apps.. they think it's a computer and it's software so anyone can do it.. right?? Most of us know it's a bit harder then that.. oh well.. let t

Re: [PHP] way to protect .php file

2001-05-16 Thread B. van Ouwerkerk
At 12:08 17-5-01 +0700, Kittiwat Manosuthi wrote: >In a virtual hosting environment, even though a directory permission is >set to 751, but you still need to leave world-readable permission on >individual php file that is to be read from a browser. In a scenario >where there's another user in the

Re: [PHP] way to protect .php file

2001-05-16 Thread MaD dUCK
also sprach Maxim Maletsky (on Thu, 17 May 2001 02:25:47PM +0900): > no no and no. oh sure you can. identify the group that apache runs as, then chown the directories 0750 and files 0640 after chgrp'ing them all to the same apache group, and you're set. i have my apache run as user apache and gro

RE: [PHP] way to protect .php file

2001-05-16 Thread Maxim Maletsky
Just to add, if it is possible for user to "get out his own box" then your whole server is under huge risk. People will start including each-other's files, reading your httpd.conf (a show_source('/usr/local/apache/conf/httpd.conf') is enough, even highlighted! Same to every other file on your ma

RE: [PHP] way to protect .php file

2001-05-16 Thread Maxim Maletsky
no no and no. You can chown the whole directory with it's contents to a specific user using that directory. In this way no cd is possible. This should be done automatically when creating user accounts. There are even softwares to do that - they create you a directory, user, group, add vhost and

RE: [PHP] way to protect .php file

2001-05-16 Thread Jason Murray
> Is there anyway one can protect this? Include the passwords from another file that doesn't need to be web-accessible. Or, find a virtual host that doesn't allow this kind of thing :) Jason -- Jason Murray [EMAIL PROTECTED] Web Developer, Melbourne IT "What'll Scorpy use wormhole technolog

[PHP] way to protect .php file

2001-05-16 Thread Kittiwat Manosuthi
In a virtual hosting environment, even though a directory permission is set to 751, but you still need to leave world-readable permission on individual php file that is to be read from a browser. In a scenario where there's another user in the same server who can guess (or even get, from URL) the

Re: [PHP] Web Host

2001-05-16 Thread Deependra B. Tandukar
Contact [EMAIL PROTECTED] Warm Regards, Deependra B. Tandukar www.coremag.net/cvs/dt.htm Training and Networking Assistant ICOD/ICIMOD www.icimod.org Co-ordinator CORExpress The Only Native Computer Magazine of Nepal www.coremag.net +++ ==

RE: [PHP] Links as a query point instead of form drop down box

2001-05-16 Thread Jason Murray
> how would I add the query criteria to the link? and how would I set up > showdata to take the information from the selected link? Where you would usually have a form such as: Display Value ... to use it as a link, you would use: Display Value Jason -- Jason Murray [EMAIL PROTECTE

[PHP] Links as a query point instead of form drop down box

2001-05-16 Thread Laurie Landry
I understand how to use a dropdown box to make your selection in which that selection is the criteria to display a database content; but I was wondering how I can achieve a query by link. For example, if you went to index.html file where there is a php coding that generates the categories availab

Re: [PHP] Uptime script?

2001-05-16 Thread Steve Werby
"Christopher Heschong" <[EMAIL PROTECTED]> wrote: > If you want to get the current uptime in Linux without a system() call, > you should be able to fopen() the /proc/uptime file. The first number > is the number of seconds the machine has been up, the second is the > number of seconds the machine

[PHP] function ref for experimental fastcgi in 4.05

2001-05-16 Thread Charles Brasted
Hi, The Zend site talks about the 4.05 release having an experimental fastcgi API. I have had absolutely no luck searching the php site(s), google, etc to get info on this. Can anyone help? I've been looking at the 4.05 src, but it isn't really that edifying for what I need (a list of functions

[PHP] Chained Selectors

2001-05-16 Thread Joseph Blythe
Hello, Has anyone used/is using the most excellent chainedSelectors class (by Leon Atkinson) available as a tutorial from zend.com ? I just got this working for use with the states of australia and its postcodes (around 3395 unique pcodes), but have found the result totally unusable due to th

Re: [PHP] Parsing Phone Numbers

2001-05-16 Thread dempsejn
this was just asked yesterday...if you have a phone number and it has 10 digits, then use easily use substr to add slashes at the right points...same for the other number... -jack - Original Message - From: "Jason Caldwell" <[EMAIL PROTECTED]> Date: Wednesday, May 16, 2001 10:58 pm Subje

Re: [PHP] Uptime script?

2001-05-16 Thread Billy Harvey
> also sprach Ron Pitts (on Wed, 16 May 2001 10:18:06PM -0400): > > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > This does not work. This list is like the mafia: Once in, never out. > > That sucks. The list managers are morons. > > will you chill please? of course it works. you are at f

[PHP] --with-imap-ssl

2001-05-16 Thread ilya
Has anyone been able to compile php with imap-2001 cclient with -imap-ssl option? it looks like format of cclient .h changed, and php is not able to find certain fnctions. i was wondering if anyone found a hack around? Looks like --with-imap-ssl is brok

[PHP] Parsing Phone Numbers

2001-05-16 Thread Jason Caldwell
Is there a way I can modify a phone number programmatically -- for example, if I have the following phone number: 1234567890 Now there are no "-" or "." separators... and I would like to automatically add them when the user hits submit... 123-456-7890 Also, I would like to account for optional

Re: [PHP] Uptime script?

2001-05-16 Thread MaD dUCK
also sprach Ron Pitts (on Wed, 16 May 2001 10:18:06PM -0400): > > To unsubscribe, e-mail: [EMAIL PROTECTED] > This does not work. This list is like the mafia: Once in, never out. > That sucks. The list managers are morons. will you chill please? of course it works. you are at fault. do you want

Re: [PHP] Uptime script?

2001-05-16 Thread Christopher Heschong
On Wednesday, May 16, 2001, at 09:47 PM, Ryan Christensen wrote: > No.. as I said in my original post, this is on Linux.. so I was actually > wondering how it would be a risk in Linux.. not win.. If you want to get the current uptime in Linux without a system() call, you should be able to fope

Re: [PHP] Uptime script?

2001-05-16 Thread David VanHorn
At 03:30 PM 5/16/01 -0500, Ben Gollmer wrote: >Uptime.exe is available on the WinNT / Win2k resource kit. You can also >download it here: > >http://www.microsoft.com/ntserver/nts/downloads/management/uptime/default. >asp Does the windows version have the ability to count larger than hours? :) -

Re: [PHP] Uptime script?

2001-05-16 Thread David VanHorn
At 08:18 PM 5/16/01 +0200, Christian Reiniger wrote: >On Wednesday 16 May 2001 15:16, Matthew Schroebel wrote: > > Why would you want to advertise that? Seems like you would be leaking > > information to crackers ... > >It's very difficult to imagine how 'uptime' information could be used to >cau

[PHP] Sending Output Buffer contents to PDFLib

2001-05-16 Thread Nold, Mark
- Disclaimer: The information contained in this email is intended only for the use of the person(s) to whom it is addressed and may be confidential or contain legally privileged information. If you are no

RE: [PHP] getting php run on unix

2001-05-16 Thread Maxim Maletsky
re-read INSTALL file of PHP distribution. You must also do few changes in httpd.conf. Look for AddType.. Sincerely, Maxim Maletsky Founder, Chief Developer PHPBeginner.com (Where PHP Begins) [EMAIL PROTECTED] www.phpbeginner.com -Original Message- From: Andreas Pucko [mailto:[

[PHP] Help! OCIFetchInto does not work at all

2001-05-16 Thread Grishick
I'm tryibg to execute a simple query on Oracle: $cn=OCILogon($DB_USER, $DB_PASSWORD, $DB_NAME); $stmt=OCIParse($cn,"select * from grisha"); OCIExecute($stmt); OCIFetchInto ($stmt, &$row, OCI_ASSOC); But $row is always empty and OCIFetchInto returns nothing. The table is not empty, I can execute t

Re: [PHP] Uptime script?

2001-05-16 Thread MaD dUCK
also sprach Ryan Christensen (on Wed, 16 May 2001 06:47:08PM -0700): > No.. as I said in my original post, this is on Linux.. so I was actually > wondering how it would be a risk in Linux.. not win.. sorry, i haven't really followed the thread. well, *iff* your system is properly configured *and*

[PHP] no connection to mysql

2001-05-16 Thread Tyler Longren
Hello everyone, PHP just stopped being able to connect to mysql. mysqld-nt is running, and is running alright becuase I can connect, select databases, and execute sql queries through the mysql client. However, when I try to establish a connection through PHP, the connection never gets made. Th

Re: [PHP] Uptime script?

2001-05-16 Thread Ryan Christensen
No.. as I said in my original post, this is on Linux.. so I was actually wondering how it would be a risk in Linux.. not win.. Ryan Christensen OlyPen Technical Support [EMAIL PROTECTED] 360.457.3000 800.303.8696 - Original Message - From: MaD dUCK <[EMAIL P

Re: [PHP] Uptime script?

2001-05-16 Thread MaD dUCK
also sprach Ryan Christensen (on Wed, 16 May 2001 06:35:32PM -0700): > Take a machine down, knowing it's uptime? (I.e., it's easier to > hack a box that's been up for 5 months.. as opposed to one that > hasn't been??) um, why? please don't answer if you use windoze for then the answer is obvious

Re: [PHP] Uptime script?

2001-05-16 Thread Ryan Christensen
Take a machine down, knowing it's uptime? (I.e., it's easier to hack a box that's been up for 5 months.. as opposed to one that hasn't been??) Easy to fake.. yes.. however if that were the case, I would be the one doing the faking.. in which case I wouldn't be asking.. :) --

Re: [PHP] Escaping from "<"

2001-05-16 Thread Christopher Heschong
on 5/16/01 9:12 PM, Augusto Cesar Castoldi at [EMAIL PROTECTED] wrote: > I'm tring to print the variable "tmp", but the echo is just printing "abcd", > the rest he can't print. > > Why? > > regards, > > Augusto > > $tmp="abcd echo $tmp.""; > echo ""; > $tmp=addslashes($tmp); > echo $tmp.""; >

Re: [PHP] Is there a better way to do this

2001-05-16 Thread Tiger Quimpo
On Thu, 17 May 2001, Christopher Heschong wrote: > on 5/16/01 5:10 PM, Richard Kurth at [EMAIL PROTECTED] wrote: > > [snip] > > if(file_exists("userdata")) { > > end; > > } elseif(file_exists("userdata1")) { > > copy('userdata1','userdata') ; > > system("rm userdata1"); > > end; > > } else { > >

[PHP] Escaping from "<"

2001-05-16 Thread Augusto Cesar Castoldi
I'm tring to print the variable "tmp", but the echo is just printing "abcd", the rest he can't print. Why? regards, Augusto $tmp="abcd"; echo ""; $tmp=addslashes($tmp); echo $tmp.""; echo ""; $tmp=stripslashes($tmp); echo $tmp.""; -- PHP General Mailing List (http://www.php.net/) To unsubsc

Re: [PHP] Array question

2001-05-16 Thread David Robley
On Thu, 17 May 2001 08:26, Matthias Roggendorf wrote: > Hi, > I wrote some code and I do not understand the result I get: > > while ($data = fgetcsv ($fp, 1000, ",")) $line[$j++] = $data; > > When I ouput $line[0][0] I get Array[0] instead of the real value. > > Why is that? > > Thanks for your he

Re: [PHP] - Hard return in readfile

2001-05-16 Thread Christopher Heschong
on 5/16/01 8:38 PM, Ray Iftikhar at [EMAIL PROTECTED] wrote: > I have many text files stored on my server. I call them use using the > "readfile" function. While that works great, it seems to over-write the hard > returns. This has hurt the format and readability of my information. > > ie. > tex

RE: [PHP] - Hard return in readfile

2001-05-16 Thread Jason Murray
> text file: > This is > a > > test > > output: > This is a test HTML ignores carriage returns. You could wrap it in tags, or tags. Jason -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contac

[PHP] - Hard return in readfile

2001-05-16 Thread Ray Iftikhar
I have many text files stored on my server. I call them use using the "readfile" function. While that works great, it seems to over-write the hard returns. This has hurt the format and readability of my information. ie. text file: This is a test output: This is a test is there someway to get

Re: [PHP] Uptime script?

2001-05-16 Thread Matthew Schroebel
If you were trying to take a machine down, it might be useful to know it. Plus it's easily faked. > It's very difficult to imagine how 'uptime' information could be used to > cause mischief... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For addi

[PHP] getting php run on unix

2001-05-16 Thread Andreas Pucko
Hi there, I am trying to get php running on a unix machine. It does not parse my scripts at all. Has anybody a idea to start looking at? Maybe at apache conf? Cheers andy -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-

Re: [PHP] Netscape 6, What a piece of s$#@ ,anyone else had problems with php and Netscape 6?

2001-05-16 Thread Nicole Lallande
Hi Brandon, I don't know if this is the problem, but if you have a DOCTYPE declaration - I have found the only one that works in N6 with dhtml is: http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd";> this has to do with the modes N6 operates in - strict and quirky. I found this out b

RE: [PHP] Netscape 6, What a piece of s$#@ , anyone else had problems with php and Netscape 6?

2001-05-16 Thread Jason Murray
> I am making a drop down menu script in PHP so it is compatible with non > JavaScript browsers like Netscape 6.0 The problem I am having is that when > I make tables it doesn't always load the background in the tables. I > suspect that maybe this is something with PHP because when I make html >

[PHP] Netscape 6, What a piece of s$#@ ,anyone else had problems with php and Netscape 6?

2001-05-16 Thread Brandon Orther
Hello, I am making a drop down menu script in PHP so it is compatible with non JavaScript browsers like Netscape 6.0 The problem I am having is that when I make tables it doesn't always load the background in the tables. I suspect that maybe this is something with PHP because when I make html t

Re: [PHP] math - somethings wrong

2001-05-16 Thread Nathan Cook
There are some comments below. I hope this will point you in the right direction. /* Yours :: $percentage=(($target_score/($fleet_score+$total_score))*.4)*100; */ /* From looking at the math you do on the calculator you may want to try this instead. */ $percentage=(($target_score/($fleet_score+

[PHP] math - somethings wrong

2001-05-16 Thread Michael Roark
$percentage=(($target_score/($fleet_score+$total_score))*.4)*100; if ($percentage >= 10) { $percentage='10'; $capped=$target_roids*($percentage/100); } else { $capped=$target_roids*($percentage/100); } } I get different results o

Re: [PHP] Get page height?

2001-05-16 Thread Nathan Cook
DRN <[EMAIL PROTECTED]> > Hi, I was wondering if it would be possible to get the page height using php? This solution is sloppy but in theory it works. I would lean towards using an fopen() to read the bytes of the page on the server, then based on bytes have your script decide what to

RE: Re[2]: [PHP] Is there a better way to do this

2001-05-16 Thread scott [gts]
yes, i know what you're doing i'm just curious what it's for and why you're doing it. maybe you dont have to go to all the trouble of moving/deleting/checking for filenames... maybe you can make the overall logic of the program flow better that's why i asked. > -Original Message-

Re: [PHP] Permission Problems

2001-05-16 Thread Tomasz Piłat
John Vanderzwet wrote: > How can I create this file under the owner of 'zeus' so that > they can be deleted? Welcome to the unix permissions world ;-) Is for have root access: try to play with groups (nobody/httpd and zeus in same group) and umask and chgrp. [This is not a solution, this is a hint

Re: [PHP] Get page height?

2001-05-16 Thread Chris Lee
the screen dimensions are not sent to the server, a sniffer is a handy thing, you will be able to see all the headers, and see that one is not in there. plus to compound the fact, javascript might be able to get this data (cant confirm) but javascript will only know what the dimensions are, aft

[PHP] Array question

2001-05-16 Thread Matthias Roggendorf
Hi, I wrote some code and I do not understand the result I get: while ($data = fgetcsv ($fp, 1000, ",")) $line[$j++] = $data; When I ouput $line[0][0] I get Array[0] instead of the real value. Why is that? Thanks for your help, Matthias -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] working on array of different number of indices

2001-05-16 Thread Chris Lee
Im not sure either what you mean. you want to know if a var is an array ? if (is_array($maybe_array)) if your looking for a way to transverse thought the array, use foreach() function work_on_array($value, $index) { if (is_array($index)) foreach($index as $pos => $val) $

[PHP] Get page height?

2001-05-16 Thread DRN
Hi, I was wondering if it would be possible to get the page height using php? The reason I would like to do this is so that I can include a link to the top of the page if the page is long enough, but not to display it for very short pages (where it would not be needed:) Cheers for your help, Don

Re: [PHP] Is there a better way to do this

2001-05-16 Thread Tomasz Piłat
Christopher Heschong wrote: > I'd use unlink("userfile1") rather than system("rm userfile1") just to be pretty. Or to be more secure :))) Poncki -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To cont

Re: [PHP] running a stand-alone PHP program

2001-05-16 Thread Tomasz Piłat
Nathan Cook wrote: > then you can run scripts by: > # /usr/local/bin/php /path/to/script/scriptname Or you can put: #!/usr/local/bin/php as a first line in your script, then % chown u+x yourscript % ./yourscript HTH, Poncki -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-

Re: [PHP] Passing variable with slashes in URL

2001-05-16 Thread Chris Lee
cant say for sure, but I dont play around with rawencode and addslasses for urls, just use urlencode() echo " test "; -- Chris Lee [EMAIL PROTECTED] ""Claudia Smith"" <[EMAIL PROTECTED]> wrote in message 9duqke$9g1$[EMAIL PROTECTED]">news:9duqke$9g1$[EMAIL PROTECTED]... Currently I have

Re: [PHP] running a stand-alone PHP program

2001-05-16 Thread Nathan Cook
Assuming you are running linux... Just remove the "--with-apache", from the ./configure statement... should look something like this # ./configure [DIRECTIVES] [--with-mysql=/usr/local/mysql] # make # make install Should install to: # /usr/local/bin/php then you can run scripts by: # /usr/loca

RE: [PHP] running a stand-alone PHP program

2001-05-16 Thread midget2000x
I suppose I need to be more clear. I already have PHP running, but I want to run actual PHP code that I write as a stand-alone program. Is this what you're doing? On Wed, 16 May 2001, you wrote: > yeah. i run it as a CGI. > > compile it as a binary, then edit the apache config... > > that's

RE: [PHP] deleting a file

2001-05-16 Thread scott [gts]
read the docs you'll find your answer there. php.net/delete ;) > -Original Message- > From: Joseph Bannon [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, May 16, 2001 3:53 PM > To: PHP (E-mail) > Subject: [PHP] deleting a file > > > What is the file function to remove/delete a file

Re: [PHP] Is there a better way to do this

2001-05-16 Thread Christopher Heschong
on 5/16/01 5:10 PM, Richard Kurth at [EMAIL PROTECTED] wrote: > Is there a better way to do thisI want it to look and see if the > userdata file is there and if true the bypass everything else run rest > of code. If is not then check to see if userdat1 is and if it is > change it's name to us

Re[2]: [PHP] Is there a better way to do this

2001-05-16 Thread Richard Kurth
Hello scott, I what it to look and see if the file exists if it does not the look and see if the next file exists if it does change its name and run the rest of the script. If nether exists the quit the program all together Wednesday, May 16, 2001, 2:27:19 PM, you wrote: scott [gts]> what are y

RE: [PHP] running a stand-alone PHP program

2001-05-16 Thread scott [gts]
yeah. i run it as a CGI. compile it as a binary, then edit the apache config... that's it > -Original Message- > From: midget2000x [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, May 16, 2001 4:18 PM > To: [EMAIL PROTECTED] > Subject: [PHP] running a stand-alone PHP program > > > I ap

RE: [PHP] Is there a better way to do this

2001-05-16 Thread scott [gts]
what are you trying to do that for? there's probably a much cleaner way to do what you want, but i dont really know what you want to do, so i cannot suggest anything > -Original Message- > From: Richard Kurth [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, May 16, 2001 5:10 PM > To:

[PHP] running a stand-alone PHP program

2001-05-16 Thread midget2000x
I apologize if this has already been covered...I can't seem to find it in the archives... can PHP be coded and run as a stand-alone program? If so, where can I get more info on that? I am running Linux and would like to pass some data to PHP from a CGI program. Thanks! Rory --- provid

[PHP] Is there a better way to do this

2001-05-16 Thread Richard Kurth
Is there a better way to do thisI want it to look and see if the userdata file is there and if true the bypass everything else run rest of code. If is not then check to see if userdat1 is and if it is change it's name to userdata the run rest of code. If none of the are there then gust shut do

[PHP] Passing variable with slashes in URL

2001-05-16 Thread Claudia Smith
Currently I have a problem with IE. The IE browser will not bring up my encoded url. When clicking on the link I either receive a script error or nothing happens. The issue is with the double quotes. IE does not recognized the encoded character %22 for quotes. IE does seem to process single quo

[PHP] \nhelp

2001-05-16 Thread jtjohnston
Hi, I am parsing the contents of a text file. I have certain lines that start with "&&4;" I would like to attach these lines to the previous line as follows. But I don't know how. I figure I have to search and replace for "\n&&4;" but ... ? BEFORE: Here is an example of before. &&4; here is the

Re: [PHP] Re-directing

2001-05-16 Thread B. van Ouwerkerk
> >If you're hosting on a apache box you could have something like > >DirectoryIndex start.php Forgot to mention: You can add this to .htaccess Bye, B. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTEC

Re: [PHP] References & Object XML-Parser

2001-05-16 Thread Peter Dudley
I am new to PHP's OO (though not to OO or to PHP), but here's a fix and my assessment of why it works: In your tag functions, you need to change the $this reference to instead refer to your $xml_parser object, thus: function tag_open($parser,$tag,$attributes) { global $xml_parser;

Re: [PHP] Uptime script?

2001-05-16 Thread Ben Gollmer
Uptime.exe is available on the WinNT / Win2k resource kit. You can also download it here: http://www.microsoft.com/ntserver/nts/downloads/management/uptime/default. asp On NT, you need at least Service Pack 4 to run it. Ben On Wednesday, May 16, 2001, at 01:55 PM, Ryan Christensen wrote: >

[PHP] [annoucement] Smarty template engine 1.4.1 available

2001-05-16 Thread Monte Ohrt
A minor bug fix release. http://www.phpinsider.com/php/code/Smarty/ Version 1.4.1 - - fix LOCK_EX logic for all windows platforms (Monte) - fixed indexing by section properties with the new syntax. (Andrei) - updated Smarty to use absolute paths when requiring/including S

RE: [PHP] deleting a file

2001-05-16 Thread Johnson, Kirk
http://www.php.net/manual/en/function.unlink.php Kirk > -Original Message- > From: Joseph Bannon [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, May 16, 2001 1:53 PM > To: PHP (E-mail) > Subject: [PHP] deleting a file > > > What is the file function to remove/delete a file from a server?

[PHP] deleting a file

2001-05-16 Thread Joseph Bannon
What is the file function to remove/delete a file from a server? Joseph Say I'm Hot! - Post Your Picture! http://www.sayimhot.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To c

Re: [PHP] "Free" Database Design Program

2001-05-16 Thread Chris Worth
That's a good plan. promote THEFT. maybe somebody will think if they crack your front door they then realize all the stuff in your house is free? On Sun, 13 May 2001 17:18:45 -0300 (EST), Augusto Cesar Castoldi wrote: >The software can be really a freeware (better) or... > >can be cracke

[PHP] Permission Problems

2001-05-16 Thread John Vanderzwet
One of my scripts must create a directory, then a file in it. This part works great, although when another script tries to delete the file (and directory afterwards) it doesn't work because of the permissions. The user on the created file is 'httpd', from apache. The owner of the script is call

Re: [PHP] Passing vars between functions (with POSTs)

2001-05-16 Thread Miguel Ribeiro
Thanks for your reply but for example, my problem is more like the following php3: Login'); echo(''); echo(''); } function vrf_passwd($f1) { printf("Login=%s",$f1); } switch($s) { case 1: vrf_passwd($login); break; default: login(); break; } ?> "Rasmus Lerdorf" <[EMAIL PROTECTE

RE: [PHP] still not friends with RegExps..

2001-05-16 Thread scott [gts]
yes... i agree. if you know pregs, you have the added benefit of knowing how to write regexps for PHP *and* perl (should you ever have to program in perl) i personally prefer pregs becuase i think that the syntax is cleaner and more concise... > -Original Message- > From: Christian Rein

RE: [PHP] php as CGI

2001-05-16 Thread scott [gts]
you need to: ./configure [whatever options] make make test make install (as root) then you need to edit Apache httpd.conf appropriately and restart the daemon. then, it should work > -Original Message- > From: Beech Rintoul [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, May 16, 2001

RE: [PHP] Uptime script?

2001-05-16 Thread Ryan Christensen
That's what I was wondering.. hehe.. I just want to be able to show users that the server is stable.. (this is for a server-status page.. shows general information.. only for members of the site anyways.) Ryan > -Original Message- > From: Christian Reiniger [mailto:[EMAIL PROTECTED]]

[PHP] php as CGI

2001-05-16 Thread Beech Rintoul
Hi, I'm new to pgp and I'm trying to configure it as an Apache cgi. What do I need to put into the httpd.conf to enable it? I tried the example from the manual, but it doesn't work. Also will php3 scripts work in php4? I'm using php4 and apache-1.3.19 with mysql. Any assistance would be appreci

Re: [PHP] Passing vars between functions (with POSTs)

2001-05-16 Thread Rasmus Lerdorf
> I've tried other ways but my problem still continues... I can not pass > $login var out of the function. > > I don't have this problem in the two previous functions because I pass this > variable as function argument, but this last function that doesn't have > arguments I can't see the $login (e

Re: [PHP] Passing vars between functions (with POSTs)

2001-05-16 Thread Miguel Ribeiro
Thanks for your reply. I've tried other ways but my problem still continues... I can not pass $login var out of the function. I don't have this problem in the two previous functions because I pass this variable as function argument, but this last function that doesn't have arguments I can't see

Re: [PHP] Re-directing

2001-05-16 Thread B. van Ouwerkerk
>I use a little bit of javascript ... > > > location = "newURL.php"; > > >inside the tags. ouch. Say I've got javescript disabled.. what happens.. exactly.. nothing. I hate clientside cause I can't control it. If you're hosting on a apache box you could have somethin

Re: [PHP] Uptime script?

2001-05-16 Thread Christian Reiniger
On Wednesday 16 May 2001 15:16, Matthew Schroebel wrote: > Why would you want to advertise that? Seems like you would be leaking > information to crackers ... It's very difficult to imagine how 'uptime' information could be used to cause mischief... chris@server:~$ uptime 8:55pm up 45 days,

Re: [PHP] zlib or gzip compression?

2001-05-16 Thread Jakob Kruse
As I understood it: performance. zlib.output_compression should be a lot more effective than using output_handlers. I don't really have a basis for comparing them, but I have been using zlib.output_compression since the day 4.0.5 was released and it works beautifully and very, very fast. Regards

[PHP] PrimalScript Users

2001-05-16 Thread Phillip Bow
For anyone using PrimalScript as their IDE I have put together an updated php.sense file with mostly all(theoretically) the PHP functions available as of PHP 4.04pl1(the sense files are what allow the autocompletion of functions, and shows the param list). I have seen a lot of complaints about pr

Re: [PHP] Continue Script after readfile()

2001-05-16 Thread Joseph Koenig
OK, I think I failed to see what was realling happening. The script is continuing after the readfile(), however, I want the page to reload after the file is done. The link that lets the user download the file is really a link to $PHP_SELF with some variables set. Everything in the script will cont

RE: [PHP] RE: Processing time in PHP. better to use php tags inline or pri nt("");

2001-05-16 Thread Merio, Quinn
Thank you for your help, gentlemen, sorry about the re-post. In case you were wondering about the results on that, the pages both processed at almost identical times: 0.0023289918899536 - 1st hit 0.0022320411682129 - refresh 2 0.0017479658126831 -refresh 3 Cheers, q. Quinn Merio www.vir2lall

RE: [PHP] EREGI -- Help

2001-05-16 Thread Johnson, Kirk
Give this a try: if(!ereg("^([0-9]{5}([-]{1}[0-9]{4})?)$",$data)) { Kirk > -Original Message- > From: Jason Caldwell [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, May 15, 2001 8:16 PM > To: [EMAIL PROTECTED] > Subject: [PHP] EREGI -- Help > > > I'm just trying to create a eregi expressi

Re: [PHP] RE: Processing time in PHP. better to use php tags inline or pri nt("");

2001-05-16 Thread Ethan Schroeder
Sorry, I think that code got chopped off, try this: t_start = microtime(); } function stop(){ $this->t_stop= microtime(); } function elapsed() { if ($this->t_elapsed) { return $this->t_elapsed; } el

[PHP] RE: Sending attachments via mail()

2001-05-16 Thread Daniel BI
Yep, it was *very* much discussed last time :) first need to prepare your image to meet the base 64 and chunked standards: $content = chunk_split ( base64_encode ( $your_image ) ); then you need something like this in the additional header info of the php mail function: $boundary = 'NEXT_PART'

Re: [PHP] RE: Processing time in PHP. better to use php tags inline or pri nt("");

2001-05-16 Thread Ethan Schroeder
The following code is not mine, so I take no credit for it. It seems to work fine for me, though: t_start = microtime(); } function stop(){ $this->t_stop= microtime(); } function elapsed() { if ($this->t_elapsed) { r

RE: [PHP] Inserting and Selecting an IMAGE from the DB

2001-05-16 Thread scott [gts]
use a BLOB field type read the docs for mysql, or whatever DB you happen to be using. > -Original Message- > From: Felipe Moreno [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, May 16, 2001 11:02 AM > To: [EMAIL PROTECTED] > Subject: [PHP] Inserting and Selecting an IMAGE from the DB > Imp

Re: [PHP] Continue Script after readfile()

2001-05-16 Thread Rasmus Lerdorf
> is it possible for a script to continue running after calling > readfile()? I have a function that uses readfile(), after the file has > been read, I need to update a database. Any reason my script would just > stop executing? At first I thouht it may be a time limit, issue, but I > set time lim

RE: [PHP] need help

2001-05-16 Thread scott [gts]
wow, that's quite a mouthfull ;) use dirname > > $path=substr(__FILE__, 0, strlen(__FILE__) - strlen(basename(__FILE__)) - > 1); > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the li

RE: [PHP] need help

2001-05-16 Thread Johnson, Kirk
__FILE__ is a constant predefined by PHP. See http://www.php.net/manual/en/language.constants.php For help on the basename() function, see http://www.php.net/manual/en/function.basename.php Kirk > -Original Message- > From: Fai [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, May 16, 2001

Re: [PHP] need help

2001-05-16 Thread Rasmus Lerdorf
> Can anybody tell me what does the following mean? > > $path=substr(__FILE__, 0, strlen(__FILE__) - strlen(basename(__FILE__)) - > 1); It's silly code written by someone who doesn't realize that the dirname() function exists. dirname(__FILE__) would do exactly the same thing. See php.net/dirna

[PHP] need help

2001-05-16 Thread Fai
Can anybody tell me what does the following mean? $path=substr(__FILE__, 0, strlen(__FILE__) - strlen(basename(__FILE__)) - 1); Thanks! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact th

Re: [PHP] Sessions question.

2001-05-16 Thread Rasmus Lerdorf
> Is there a way to get the name of each variable in a session? Just walk through $HTTP_SESSION_VARS -Rasmus -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mai

Re: [PHP] changing pixelsize of a picture via php

2001-05-16 Thread Rasmus Lerdorf
> I am trying to change the size of picture (.jpg or.gif) on the server via > php. In order to get a smaller file size for a thumb. > > Has anybody a idea how to do that?? The best way, albeit somewhat slow, is to use the new ImageCopyResampled() function provided by GD2. See http://php.net/imag

  1   2   >