php-general Digest 25 Sep 2004 11:12:35 -0000 Issue 3016

2004-09-25 Thread php-general-digest-help
php-general Digest 25 Sep 2004 11:12:35 - Issue 3016 Topics (messages 197802 through 197815): php upload script problems 197802 by: AMC 197813 by: Marek Kilimajer 197815 by: Pablo M. Rivas Re: A few questions about system requirements 197803 by: Steven Re:

php-general Digest 25 Sep 2004 23:12:54 -0000 Issue 3017

2004-09-25 Thread php-general-digest-help
php-general Digest 25 Sep 2004 23:12:54 - Issue 3017 Topics (messages 197816 through 197845): how to retrieve path to web server files 197816 by: AMC 197817 by: M. Sokolewicz 197832 by: Jasper Howard 197833 by: Jasper Howard Re: interesting behavior of

Re: [PHP] php upload script problems

2004-09-25 Thread Marek Kilimajer
AMC wrote: Hi, I have the following php page. The page just opens up blank and I assume I made an error I cannot see. I'm new to php and any help would be greatly appreciated: What is your register_globals and display_errors setting? -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] Parse Error... can not find cause of error....

2004-09-25 Thread Marek Kilimajer
GH wrote: Greetings... I am getting a parse error (line 45) and I do not know what is causing it... since I have the same code with minor changes nyc_ renamed to fed_ and it works... can someone please assit. code is also available at http://www.phpaste.com/536 File:

Re: [PHP] php upload script problems

2004-09-25 Thread Pablo M. Rivas
Hello: When you want to know where is your error, set: error_reporting(E_ALL); http://www.php.net/manual/en/function.error-reporting.php the error is here: case upload: echohtmlheadtitleFile Upload/title/headbodyform method=POST action=$PHP_SELF?action=doupload enctype=multipart/form-data

[PHP] how to retrieve path to web server files

2004-09-25 Thread AMC
Hi, How can I get the string that is the path to the directories on my web server? I need to upload some files, but don't know what to supply for the destination path. In asp I used server.mappath, but I'm new to php. Thanks, -- PHP General Mailing List (http://www.php.net/) To unsubscribe,

[PHP] Re: how to retrieve path to web server files

2004-09-25 Thread M. Sokolewicz
$path = getcwd(); Amc wrote: Hi, How can I get the string that is the path to the directories on my web server? I need to upload some files, but don't know what to supply for the destination path. In asp I used server.mappath, but I'm new to php. Thanks, -- PHP General Mailing List

[PHP] Re: interesting behavior of ob_end_flush() in __destruct()

2004-09-25 Thread Daniel Schierbeck
Arzed wrote: it seems that php first ends output buffering and then calls then destrcuts the objects. so the output buffering is still ended when the destructor is calles. one has to unset the object to reverse that order manually. I've encountered the same problem. It would be nice if there

Re: [PHP] mailing to hotmail

2004-09-25 Thread -{ Rene Brehmer }-
At 19:05 24-09-2004, you wrote: Diana Castillo wrote: for some reasons my mails I send to hotmail are never arriving, (using mail($email,$subject_line,$msg,$headers);) anyone ever heard of this? Does the box that you're running php on have a dynamic address? Do you have reverse DNS? You can

Re: [PHP] mailing to hotmail

2004-09-25 Thread -{ Rene Brehmer }-
At 18:23 24-09-2004, Diana Castillo wrote: for some reasons my mails I send to hotmail are never arriving, (using mail($email,$subject_line,$msg,$headers);) anyone ever heard of this? Usually if mail is not accepted by hotmail you'll get a very long and polite error message about it after some

Re: [PHP] interesting behavior of ob_end_flush() in __destruct()

2004-09-25 Thread aRZed
Chris Dowell wrote: I haven't searched through the archives to refresh my memory, but it's something to bear in mind. I wonder whether error messages are also not passed to the browser. I have pointed out some more aspects of this issue: Error messages and normal output are passed to the browser

[PHP] New PHP tutorial - suggestions welcome

2004-09-25 Thread Paul Hudson
Hi there, I've written a short PHP tutorial and am looking for input - does it cover enough ground? Is it hard to use as a reference? Does it get too technical? Anyway, if you have any ideas as to how it can be improved, I'd be happy to hear from you. The URL is http://www.hudzilla.org/php

[PHP] Re: New PHP tutorial - suggestions welcome

2004-09-25 Thread Daniel Schierbeck
Paul Hudson wrote: I've written a short PHP tutorial and am looking for input - does it cover enough ground? Is it hard to use as a reference? Does it get too technical? Anyway, if you have any ideas as to how it can be improved, I'd be happy to hear from you. The URL is

Re: [PHP] php upload script problems

2004-09-25 Thread Jim Grill
Hi, I have the following php page. The page just opens up blank and I assume I made an error I cannot see. I'm new to php and any help would be greatly appreciated: ?php $extlimit = yes; //Do you want to limit the extensions of files uploaded $limitedext = array(.pdf); //Extensions you

[PHP] redirecting to another page

2004-09-25 Thread AMC
Hi, What code do I use to redirect a user to a different page in php? Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: New PHP tutorial - suggestions welcome

2004-09-25 Thread Chris Shiflett
--- Paul Hudson [EMAIL PROTECTED] wrote: I've written a short PHP tutorial and am looking for input - does it cover enough ground? Is it hard to use as a reference? Does it get too technical? Anyway, if you have any ideas as to how it can be improved, I'd be happy to hear from you. Well

Re: [PHP] redirecting to another page

2004-09-25 Thread Jason Davidson
eh hem,,, that is a great question to consult the manual... but as for a hint, search for header() Jason AMC [EMAIL PROTECTED] wrote: Hi, What code do I use to redirect a user to a different page in php? Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe,

Re: [PHP] redirecting to another page

2004-09-25 Thread Chris Shiflett
--- AMC [EMAIL PROTECTED] wrote: What code do I use to redirect a user to a different page in php? There are several methods, but my favorite is to use a Location header which also changes the response status code. This method is transparent to the history mechanism, so users can still click the

[PHP] Re: simple templateing

2004-09-25 Thread Matthew Weier O'Phinney
* Mag [EMAIL PROTECTED]: I am searching for a REAL simple templateing class/package I have googled for this and basically SMARTY and PAT is too bulky, the people who will be using this script will be pretty dumb and all I can trust them to do would be something like this: header category

[PHP] Problems installing smarty on a shared host

2004-09-25 Thread Pablo Gosse
Hi folks. I've recently moved my site to a shared host, and this is the first time I've had to set up my site in a really restrictive environment, and I'm running into problems getting smarty installed. Using the basic example set up from the Smarty docs, when I run the file I get the following

Re: [PHP] Problems installing smarty on a shared host

2004-09-25 Thread Marek Kilimajer
Pablo Gosse wrote: Hi folks. I've recently moved my site to a shared host, and this is the first time I've had to set up my site in a really restrictive environment, and I'm running into problems getting smarty installed. Using the basic example set up from the Smarty docs, when I run the file I

Re: [PHP] Re: how to retrieve path to web server files

2004-09-25 Thread Jasper Howard
On Sat, 25 Sep 2004 14:29:27 +0200, M. Sokolewicz [EMAIL PROTECTED] wrote: $path = getcwd(); Amc wrote: Hi, How can I get the string that is the path to the directories on my web server? I need to upload some files, but don't know what to supply for the destination path. In asp I

Re: [PHP] Re: how to retrieve path to web server files

2004-09-25 Thread Jasper Howard
$base_dir = $_SERVER['document_root'] On Sat, 25 Sep 2004 14:17:16 -0700, Jasper Howard [EMAIL PROTECTED] wrote: On Sat, 25 Sep 2004 14:29:27 +0200, M. Sokolewicz [EMAIL PROTECTED] wrote: $path = getcwd(); Amc wrote: Hi, How can I get the string that is the path to the

RE: [PHP] Problems installing smarty on a shared host

2004-09-25 Thread Pablo Gosse
I tried that and got the same error. I'm trying to place the smarty directories outside my webroot to minimize security risks, however given my experiences thus far, I don't really see that being possible. Would a viable solution perhaps to be to include the smarty directories in the webroot

[PHP] ftp_put Problems

2004-09-25 Thread Julian
Hello, I need to use FTP to upload a local file to a server. The uploads must be done through FTP and not HTTP. Unfortunately, the example in the manual is not working for me. If someone has any suggestions I would really appreciate it. Thanks, Julian -- PHP General Mailing List

Re: [PHP] Problems installing smarty on a shared host

2004-09-25 Thread Marek Kilimajer
Pablo Gosse wrote: I tried that and got the same error. I'm trying to place the smarty directories outside my webroot to minimize security risks, however given my experiences thus far, I don't really see that being possible. It should not matter, unless open_basedir is in effect, but that would

Re: [PHP] ftp_put Problems

2004-09-25 Thread Marek Kilimajer
Julian wrote: Hello, I need to use FTP to upload a local file to a server. The uploads must be done through FTP and not HTTP. Unfortunately, the example in the manual is not working for me. If someone has any suggestions I would really appreciate it. Not much information. There is not error

Re: [PHP] ftp_put Problems

2004-09-25 Thread Julian
Maybe I should be more specific about what I am trying to do. I may be way off base in my approach. I want to upload using ftp a file from my local c drive (c:\somefile.text) to my server. I have been trying the ftp_put function example in the manual and it is failing. It reports There was a

RE: [PHP] Problems installing smarty on a shared host

2004-09-25 Thread Pablo Gosse
[snip] I'm trying to place the smarty directories outside my webroot to minimize security risks, however given my experiences thus far, I don't really see that being possible. It should not matter, unless open_basedir is in effect, but that would be another error. I would check if the

Re: [PHP] ftp_put Problems

2004-09-25 Thread Jason Wong
On Sunday 26 September 2004 06:38, Julian wrote: Maybe I should be more specific about what I am trying to do. I may be way off base in my approach. I want to upload using ftp a file from my local c drive (c:\somefile.text) to my server. I have been trying the ftp_put function example in the

RE: [PHP] Problems installing smarty on a shared host

2004-09-25 Thread Pablo Gosse
[snip] It should not matter, unless open_basedir is in effect, but that would be another error. I would check if the directories are right, you can start by using relative path. [/snip] Just the relative path from smarty.php, ../../../home/pablogosse/smarty/Smarty.class.php And I get a

Re: [PHP] ftp_put Problems

2004-09-25 Thread Julian
i am trying to get a file from my local c drive to my server using something other than a form. thanks, julian Jason Wong [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Sunday 26 September 2004 06:38, Julian wrote: Maybe I should be more specific about what I am trying to do. I

Re: [PHP] Problems installing smarty on a shared host

2004-09-25 Thread Marek Kilimajer
Pablo Gosse wrote: [snip] It should not matter, unless open_basedir is in effect, but that would be another error. I would check if the directories are right, you can start by using relative path. [/snip] Just the relative path from smarty.php, ../../../home/pablogosse/smarty/Smarty.class.php

Re: [PHP] ftp_put Problems

2004-09-25 Thread Marek Kilimajer
Julian wrote: i am trying to get a file from my local c drive to my server using something other than a form. Hmm, you can run an ftp server on your local machine and use php script on the server to retrieve the files. http server will work just as well. Is this what you want? thanks, julian

Re: [PHP] ftp_put Problems

2004-09-25 Thread Julian
well, i suspect i am at a dead end. here is the layout of things. we want to put up an internet kiosk at certain thoroughbred auctions to allow people to send ecards as well as contact associates. we have a web cam on the kiosk and a partner came up with the idea of letting them send photos of

Re: [PHP] Problems installing smarty on a shared host

2004-09-25 Thread Curt Zirzow
* Thus wrote Pablo Gosse: Hi folks. I've recently moved my site to a shared host, and this is the first time I've had to set up my site in a really restrictive environment, and I'm running into problems getting smarty installed. Using the basic example set up from the Smarty docs, when I

Re: [PHP] ftp_put Problems

2004-09-25 Thread Marek Kilimajer
Julian wrote: well, i suspect i am at a dead end. here is the layout of things. we want to put up an internet kiosk at certain thoroughbred auctions to allow people to send ecards as well as contact associates. we have a web cam on the kiosk and a partner came up with the idea of letting them

RE: [PHP] Problems installing smarty on a shared host

2004-09-25 Thread Pablo Gosse
[snip] You'll probably notice that the permissions for /home/pablogosse are like: drwxr-x--- with user:group pablogosse:pablogosse If you have permissions to, i would set up a directory like: /home/virtual/site357/fst/var/include/smarty/ And then set the include_path appropriatly. [/snip]

Re: [PHP] ftp_put Problems

2004-09-25 Thread raditha dissanayake
Julian wrote: i am trying to get a file from my local c drive to my server using something other than a form. This is pretty much an impossible task for server side scripting. You can perhaps use an applet to upload either via FTP or HTTP. but marek's last mail is probably the best solution.

Re: [PHP] is that possible with Objects in php 4 or php5 ?

2004-09-25 Thread raditha dissanayake
Alawi Albaity wrote: I have object A and object B that extended from object A and have it Own abilities and object C that extended from object A and have it Own abilities I want to use the abilities of object B on object C and abilities of object C on object B , but the problem that what found out

[PHP] Conceptual ?: using 'multi-purpose' form for validation

2004-09-25 Thread Whil Hentzen
I can get a single form to call itself again if there's nothing fancy going on. This code will prompt the user for their mail if it doesn't already exist, and if the email does exist, provides some data out of database. ?php if ( !isset($_POST['email']) ): ? !-- No email, so prompt the user

[PHP] php security on shared hosts

2004-09-25 Thread Pablo Gosse
Hi folks. I recently set up hosting for my site and have noticed something which is making me nervous. I can't seem to include files outside of my webroot, so I wrote a script to test permissions using passthru to output the results of a bunch of ls -la commands to see what I did and did not have

Re: [PHP] php security on shared hosts

2004-09-25 Thread Tim Traver
Pablo, As a shared hosting company myself (http://www.simplenet.com/), I can guarantee that is not the way it is supposed to be. We make sure that can't happen by running in Safe mode, using the open_basedir directive, and making sure the directory tree has the correct permissions so the

[PHP] Server's IP Adress

2004-09-25 Thread Kevin Javia
Greetings, How can I get Server's IP address? I know $_SERVER[SERVER_ADDRSS] but this do not work all the time. Is there any other method? Thanks a ton in advance. Kevin. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Server's IP Adress

2004-09-25 Thread Pahlevanzadeh Mohsen
You can use getbyhostname() func. --- Kevin Javia [EMAIL PROTECTED] wrote: Greetings, How can I get Server's IP address? I know $_SERVER[SERVER_ADDRSS] but this do not work all the time. Is there any other method? Thanks a ton in advance. Kevin. -- PHP General Mailing List

[PHP] Re: New PHP tutorial - suggestions welcome

2004-09-25 Thread John Taylor-Johnston
Consistently crashes my Netscape 4.8 (circa 2003). yeah, I still use it, because I prefer its news reader. Very few attacks on this mature mail program. That said, you're forcing me to use IE6 :-| -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] Re: New PHP tutorial - suggestions welcome

2004-09-25 Thread Jack Gates
On Sunday 26 September 2004 12:32 am, John Taylor-Johnston wrote: Consistently crashes my Netscape 4.8 (circa 2003). yeah, I still use it, because I prefer its news reader. Very few attacks on this mature mail program. That said, you're forcing me to use IE6 :-| No one is forcing you to use

Re: [PHP] php security on shared hosts

2004-09-25 Thread Chris Shiflett
--- Pablo Gosse [EMAIL PROTECTED] wrote: Hi folks. I recently set up hosting for my site and have noticed something which is making me nervous. I can't seem to include files outside of my webroot, so I wrote a script to test permissions using passthru to output the results of a bunch of ls

Re: [PHP] php security on shared hosts

2004-09-25 Thread Chris Shiflett
--- Tim Traver [EMAIL PROTECTED] wrote: I can guarantee that is not the way it is supposed to be. We make sure that can't happen by running in Safe mode, using the open_basedir directive, and making sure the directory tree has the correct permissions so the situation you described cannot