php-general Digest 20 May 2005 11:03:11 -0000 Issue 3465

2005-05-20 Thread php-general-digest-help
php-general Digest 20 May 2005 11:03:11 - Issue 3465 Topics (messages 215623 through 215638): Empty string problem 215623 by: Kristen G. Thorson 215633 by: Rasmus Lerdorf Re: Looking for a developer's weblog/cms system? 215624 by: Philip Hallstrom Re: System Call

RE: [PHP] Problem With System Call

2005-05-20 Thread Kim Madsen
-Original Message- From: Michael Stearne [mailto:[EMAIL PROTECTED] Sent: Thursday, May 19, 2005 4:17 PM No. It's RedHat Fedora Core 3. And? (/etc/selinux/ ;-) It´s a thing that troubles a lot in Feodora3 installations -- Med venlig hilsen / best regards ComX Networks A/S Kim

[PHP] Japanese Fonts in php

2005-05-20 Thread Mark Sargent
Hi All, how would one get them to display in php pages..? Is it like ASP where you have to set a codepage number..? I've set this at the top of my pages, html lang=Shift_JIS and this for the font font type=\Shift_JIS\$product_data_output/font I don't claim to know much about HTML either. I'm just

Re: [PHP] Empty string problem

2005-05-20 Thread Rasmus Lerdorf
Kristen G. Thorson wrote: Following is a snippet of code that I am trying to debug. Most of the time, the variable $sn (set on the last line), correctly contains the variable $this_customer_num. On some occasions, however, it does not contain $this_customer_num. I cannot figure out what may

[PHP] mysql with php

2005-05-20 Thread Rittwick Banerjee
Hi friends, I am Rittwick Banerjee and i have made a mysql based user name and password program but I found that what ever I entered in the user name and password feild the php file dose not working. I set this code for user name and password $sql = SELECT `User_name` AND `User_pass` FROM

RE: [PHP] OT - Table help needed~ PLEASE

2005-05-20 Thread Mark Rees
Something along these lines should get you started Tclothes (holds all the possible variations of size, colour and style) Id PK Styleid FK to Tstyle Sizeid FK to Tsize Colourid FK to Tcolour Tstyle Styleid PK StyleDescription VARCHAR Tsize Sizeid PK SizeDescription VARCHAR Tcolour Colourid PK

[PHP] How to confirm subscriptions by e-mail on a PHP site ?

2005-05-20 Thread Mário Gamito
Hi, I'm making this middle-range site (i. e., not so little, bit not so big, either), and i want users that subscribe to my site to have their confirmation made by email. Does anyone sugests a simple, yet effective way to do this ? Please, don't misunderstand me. The PHP part i know. The

Re: [PHP] Excellent language PHP5 is!

2005-05-20 Thread Jochem Maas
Robert Meyer wrote: Hello All, Just a comment on PHP5. I never used PHP until just over two weeks ago, though I have been a software engineer since 1975. What one can do with PHP5 is awesome. What a great recommendation! It was very nice to read how someone who obviously has buckets of IT

[PHP] How to confirm subscriptions by e-mail on a PHP site ?

2005-05-20 Thread Mário Gamito
Hi, I'm making this middle-range site (i. e., not so little, bit not so big, either), and i want users that subscribe to my site to have their confirmation made by email. Does anyone sugests a simple, yet effective way to do this ? Please, don't misunderstand me. The PHP part i know. The

Re: [PHP] mysql with php

2005-05-20 Thread eoghan
$sql = select User_name, User_pass from user where User_name = '$_POST[user_id]' and User_pass = '$_POST[user_pass]'; assuming user_id isnt an int Rittwick Banerjee wrote: Hi friends, I am Rittwick Banerjee and i have made a mysql based user name and password program but I found that what ever

[PHP] Bar codes

2005-05-20 Thread Emil
Hello! Sorry if this is off topic. I'm making a php site where one can order a kit and now I would like to mark the kits with bar codes generated by the php script. I would also need some kind of bar code hardware reader and some way for a computer to read the result from the bar code reader,

Re: [PHP] How to confirm subscriptions by e-mail on a PHP site ?

2005-05-20 Thread Mário Gamito
Hi George, Thank you for your answer. The future users of the site i'm doing can register freely. No need for aproval. I just want to ensure that there are no fake subscriptions or fake e-mails. I was thinking more in something like an email sent back after the form fill, with an URL back to

Re: [PHP] How to confirm subscriptions by e-mail on a PHP site ?

2005-05-20 Thread Duncan Hill
On Friday 20 May 2005 09:21, Mário Gamito typed: Hi, I'm making this middle-range site (i. e., not so little, bit not so big, either), and i want users that subscribe to my site to have their confirmation made by email. Does anyone sugests a simple, yet effective way to do this ? When the

RE: [PHP] mysql with php

2005-05-20 Thread Jim Moseby
-Original Message- From: Rittwick Banerjee [mailto:[EMAIL PROTECTED] Sent: Friday, May 20, 2005 3:59 AM To: php-general@lists.php.net Subject: [PHP] mysql with php Hi friends, I am Rittwick Banerjee and i have made a mysql based user name and password program but I found

Re: [PHP] How to confirm subscriptions by e-mail on a PHP site ?

2005-05-20 Thread Rory Browne
You can either email them an URL containing an activation code, which would have them activate in their browser. If you don't understand the terms .forwared, or MTA, you should probably either learn more about them or skip to the third paragraph. If you want them to activate using their email

RE: [PHP] mysql with php

2005-05-20 Thread George Pitcher
Noticed that there was still something missing in this: $sql = select User_name, User_pass from user where User_name = '$_POST['user_id']' and User_pass = '$_POST['user_pass']'; Quotes around the POST Args. George -Original Message- From: eoghan [mailto:[EMAIL PROTECTED] Sent: 20

RE: [PHP] How to confirm subscriptions by e-mail on a PHP site ?

2005-05-20 Thread Jim Moseby
What I do is generate a random key, save it in the database, send them an email with a link that they must click to validate their email: http://www.mysite.com/[EMAIL PROTECTED][EMAIL PROTECTED] 9j(*(hn3983n*(j Its not foolproof, I know, but it is simple and effective, as you say. Heres a quick

Re: [PHP] How to confirm subscriptions by e-mail on a PHP site ?

2005-05-20 Thread Marcus Joyce
The way i did it was, put a 25char hash inside the registered column, then sent an email to the user containing something like domain.com?user=id_numberhash=hash then i did select userID where userID = $_GET['user'] registered = $_GET['hash'] (not exactly the sql phrase, but i dont feel like

Re: [PHP] mysql with php

2005-05-20 Thread [EMAIL PROTECTED]
try this: $sql = SELECT User_name, User_pass FROM `user` WHERE User_name= '$_POST[user_id]' AND User_pass = '$_POST[user_pass]' ; -afan Rittwick Banerjee wrote: Hi friends, I am Rittwick Banerjee and i have made a mysql based user name and password program but I

RE: [PHP] Bar codes

2005-05-20 Thread Jim Moseby
Hello! Sorry if this is off topic. I'm making a php site where one can order a kit and now I would like to mark the kits with bar codes generated by the php script. I would also need some kind of bar code hardware reader and some way for a computer to read the result from the bar

[PHP] ftp_fput() limit is 10 characters

2005-05-20 Thread mayo
I'm trying to ftp a file. I looked in the php manual and I don't see a character limit for ftp_fput(). I'm getting the following error ftp_fput(): Specified object name too long, limit is 10 characters: CF-20050520. in /home/www/cf/test.php on line 45 There was a problem while uploading CF

Re: [PHP] Bar codes

2005-05-20 Thread Leif Gregory
Hello Emil, Friday, May 20, 2005, 4:45:49 AM, you wrote: E I've never done anything like this before, do you know of any good E starting points? I don't know anything about bar codes. http://www.phpclasses.org and search for barcode -- Leif (TB lists moderator and fellow end user). Using The

Re: [PHP] Bar codes

2005-05-20 Thread James E Hicks III
Emil wrote: Hello! Sorry if this is off topic. I'm making a php site where one can order a kit and now I would like to mark the kits with bar codes generated by the php script. I would also need some kind of bar code hardware reader and some way for a computer to read the result from the bar

Re: [PHP] Image Verification - Problems in Safari, Mac OS X

2005-05-20 Thread Rahul S. Johari
Ave, On 5/19/05 6:08 PM, Rory Browne [EMAIL PROTECTED] wrote: if you have an image generated by http://www.example.com/createimage.php , you could always refer to it as http://www.example.com/createimage.php/{no_of_seconds_since_unix_epoch}.png It's sounding logical, but could you explain a

[PHP] ZEND Certification

2005-05-20 Thread Martin Zvarik
Hi, anyone has taken ZEND PHP Certification Exam??? Please can you give me some information about it? Thank you, Martin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Getting parameters from the URL

2005-05-20 Thread Mário Gamito
Hi, Following the previous discussion regarding confirmation of subscriptions (to all the people who replied, my thanks), i now generate an URL something like this: http://www.bar.com/[EMAIL PROTECTED]code=vu782 Then in file confirma_registo_action.php, i do: $email= $_GET['email'];

Re: [PHP] Image Verification - Problems in Safari, Mac OS X

2005-05-20 Thread Rahul S. Johari
Ave, On 5/19/05 5:41 PM, Marek Kilimajer [EMAIL PROTECTED] wrote: If more then one user is accesing the page, you might overwrite the first one's verify.png image. Simple and sufficient solution is to append a random string to the filename: $image_filename= 'verify_' . md5(rand()) .

[PHP] Getting parameters from a URL coming from outside the site

2005-05-20 Thread Mário Gamito
Hi, Following the previous discussion regarding confirmation of subscriptions (to all the people who replied, my thanks), i now generate an URL something like this: http://www.bar.com/[EMAIL PROTECTED]code=vu782 This hit will come from someone's mail client. Then, in file

Re: [PHP] Getting parameters from the URL

2005-05-20 Thread Richard Davey
Hello Mário, Friday, May 20, 2005, 4:48:07 PM, you wrote: MG http://www.bar.com/[EMAIL PROTECTED]code=vu782 MG for testing, but it does print nothing. So, i'm not getting the MG parameters from the URL. I have register_globals=Off in php.ini MG Why is this wrong and how to make it right ? Try

[PHP] PHP5 binaries

2005-05-20 Thread Marcus Bointon
It seems that none of the current major Linux distros provide PHP5 binary installation packages. By major I mean, RedHat, Fedora (it will be in F4 when released), Mandriva, Debian, Ubuntu, possibly others. Seriously, none have standard PHP5 packages, even optional ones. Does no-one use

Re: [PHP] ZEND Certification

2005-05-20 Thread Greg Donald
On 5/20/05, Martin Zvarik [EMAIL PROTECTED] wrote: anyone has taken ZEND PHP Certification Exam??? http://zend.com/store/education/certification/yellow-pages.php Please can you give me some information about it? http://zend.com/store/education/certification/zend-php-certification.php --

Re: [PHP] Japanese Fonts in php

2005-05-20 Thread Marek Kilimajer
Mark Sargent wrote: Hi All, how would one get them to display in php pages..? Is it like ASP where you have to set a codepage number..? I've set this at the top of my pages, html lang=Shift_JIS and this for the font font type=\Shift_JIS\$product_data_output/font I don't claim to know much about

Re: [PHP] ZEND Certification

2005-05-20 Thread Rory Browne
On 5/20/05, Martin Zvarik [EMAIL PROTECTED] wrote: Hi, anyone has taken ZEND PHP Certification Exam??? Yes. Loads of people here have taken it. Loads of other people here set the questions. Please can you give me some information about it? I'm sure you'll get lots of useful and encourageing

Re: [PHP] PHP5 binaries

2005-05-20 Thread Duncan Hill
On Friday 20 May 2005 17:58, Marcus Bointon wrote: It seems that none of the current major Linux distros provide PHP5   binary installation packages. By major I mean, RedHat, Fedora (it   will be in F4 when released), Mandriva, Debian, Ubuntu, possibly   others. Seriously, none have standard

[PHP] Can I prevent Server variables from being spoofed ?

2005-05-20 Thread Graham Anderson
Can the server variable 'user agent' be modified/spoofed by the user? I have a bunch movies that I want to only open if the user agent contains Quicktime Player... In my case, if the user agent string contains Quicktime Player, a movie url is written for Quicktime to open If the user

[PHP] Cache Problems

2005-05-20 Thread Rahul S. Johari
Ave, My whole Auto-Image verification application and has come to get stuck at the Cache in IE. It¹s working fine in Safari on Mac, but IE is picking up the image from the Cache no matter what. I¹ve tried the following: header(Expires: Mon, 26 Jul 1997 05:00:00 GMT); header(Last-Modified: .

[PHP] __get() not reentrant?

2005-05-20 Thread Christopher J. Bottaro
Maybe I'm using reentrant incorrectly, but here is what I mean... class Test { function __get($nm) { if ($nm == 'x') return $this-func(); elseif ($nm == 'y') return 'y'; elseif ($nm == 'xx') return 'x'; } function func() { return

Re: [PHP] Getting parameters from a URL coming from outside the site

2005-05-20 Thread Brian V Bonini
On Fri, 2005-05-20 at 12:51, Mário Gamito wrote: Why is this wrong and how to make it right ? I did this and sent myself a link to it via email, clicked it from within my email client (Evolution) which launched a browser and called the script successfully writing the vars to test.txt. Of course

Re: [PHP] Can I prevent Server variables from being spoofed ?

2005-05-20 Thread Rasmus Lerdorf
Graham Anderson wrote: Can the server variable 'user agent' be modified/spoofed by the user? I have a bunch movies that I want to only open if the user agent contains Quicktime Player... In my case, if the user agent string contains Quicktime Player, a movie url is written for Quicktime

Re: [PHP] Can I prevent Server variables from being spoofed ?

2005-05-20 Thread Rory Browne
Not only can the user agent string be easly spoofed, but as a result of its abuse by certain webmasters(mostly Banks) Browsers such as Opera, and I believe Konqueror, have a setting that allows you to change the user agent string as a configuration option. The UserAgent is a hint. It is most

Re: [PHP] Can I prevent Server variables from being spoofed ?

2005-05-20 Thread Graham Anderson
are there any php methods that can accurately determine who the client is ? mine is pretty basic...if I am a browser, then deny access g On May 20, 2005, at 1:15 PM, Chris Shiflett wrote: Graham Anderson wrote: Can the server variable 'user agent' be modified/spoofed by the user? Yes, this

Re: [PHP] Getting parameters from the URL

2005-05-20 Thread Mário Gamito
Hi Richard, It still doesn't works. Maybe it's because it's being launched from outside the site (i. e., the referrer is not from the site ?). Maybe something's in php.ini ? Any ideas ? Warm Regards, Mário Gamito Richard Davey wrote: Hello Mário, Friday, May 20, 2005, 4:48:07 PM, you

Re: [PHP] Can I prevent Server variables from being spoofed ?

2005-05-20 Thread Chris Shiflett
Graham Anderson wrote: Can the server variable 'user agent' be modified/spoofed by the user? Yes, this value is being sent by the client. Chris -- Chris Shiflett Brain Bulb, The PHP Consultancy http://brainbulb.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] Can I prevent Server variables from being spoofed ?

2005-05-20 Thread Graham Anderson
is there another way to get reasonably accurate environment variables ? In my case,if movies are being opened in a browser...deny access g On May 20, 2005, at 12:35 PM, James E Hicks III wrote: Graham Anderson wrote: Can the server variable 'user agent' be modified/spoofed by the user?

Re: [PHP] Can I prevent Server variables from being spoofed ?

2005-05-20 Thread Leif Gregory
Hello Graham, Friday, May 20, 2005, 12:46:28 PM, you wrote: G Can the server variable 'user agent' be modified/spoofed by the G user? Oh yeah Firefox and Opera are easy to change. -- Leif (TB lists moderator and fellow end user). Using The Bat! 3.5 Return RC9 under Windows XP 5.1 Build

[PHP] Should this not return true?!?!

2005-05-20 Thread Dustin Krysak
Hi there (newbie here) - I have the following snippet of code.. $sexId = $_POST['sex']; $fName = $_POST['fName']; $lName = $_POST['lName']; if ($status = $db-query(INSERT INTO names (nameId, sexId, fName, lName) VALUES ('', $sexId, '$fName', '$lName'))) { print Your data was added to

Re: [PHP] Can I prevent Server variables from being spoofed ?

2005-05-20 Thread Brent Baisley
Think about it. The server can only tell what the user agent is by what the user reports. For all you know it could just be a perl script or just a terminal session reporting as being Quicktime. So yes, a script kiddie could spoof the user agent. Heck, some browsers even allow you to specify

[PHP] Code to bypass a certain php.ini directive

2005-05-20 Thread Mário Gamito
Hi, I have this server with display_errors=Off in php.ini Now that i'm developing a new site. is there some code i can insert in the begining of a .php file to set only for this file (not sitewide) display_errors=On ? Thanking you in advance. Warm regards, Mário Gamito -- PHP General Mailing

Re: [PHP] Should this not return true?!?!

2005-05-20 Thread Philip Hallstrom
Hi there (newbie here) - I have the following snippet of code.. $sexId = $_POST['sex']; $fName = $_POST['fName']; $lName = $_POST['lName']; if ($status = $db-query(INSERT INTO names (nameId, sexId, fName, lName) VALUES ('', $sexId, '$fName', '$lName'))) { print Your data was added to the

[PHP] multiple queries, one transaction

2005-05-20 Thread mayo
I have a site where I need to do multiple queries in sequence. I see there is a way to do consider all querys and to fail the entire procedure if one query fails. It's a BEGIN and COMMIT statement. mysql_query(BEGIN); // starts the transaction mysql_query(COMMIT); // ends the

Re: [PHP] Can I prevent Server variables from being spoofed ?

2005-05-20 Thread Rasmus Lerdorf
Graham Anderson wrote: thanks... I'l start exploring other options g On May 20, 2005, at 2:35 PM, Marek Kilimajer wrote: Graham Anderson wrote: is there another way to get reasonably accurate environment variables ? In my case,if movies are being opened in a browser...deny access

Re: [PHP] Code to bypass a certain php.ini directive

2005-05-20 Thread Richard Lynch
On Fri, May 20, 2005 3:06 pm, Mário Gamito said: I have this server with display_errors=Off in php.ini Now that i'm developing a new site. is there some code i can insert in the begining of a .php file to set only for this file (not sitewide) display_errors=On ? Search http://apache.org for

Re: [PHP] multiple queries, one transaction

2005-05-20 Thread Richard Lynch
On Fri, May 20, 2005 2:02 pm, mayo said: I have a site where I need to do multiple queries in sequence. In sequence, or as one single atomic un-interruptable action? Cuz, like, just doing them in sequence is real straight forward: $query = select ... ; $meaningful_variable_names_are_good =

Re: [PHP] Getting parameters from the URL

2005-05-20 Thread Richard Lynch
On Fri, May 20, 2005 1:21 pm, Mário Gamito said: It still doesn't works. Maybe it's because it's being launched from outside the site (i. e., the referrer is not from the site ?). That's not it, almost for sure. The entire Internet www would crumble if that were a common cause of the problem

Re: [PHP] Should this not return true?!?!

2005-05-20 Thread Richard Lynch
On Fri, May 20, 2005 1:53 pm, Dustin Krysak said: Hi there (newbie here) - I have the following snippet of code.. $sexId = $_POST['sex']; $fName = $_POST['fName']; $lName = $_POST['lName']; if ($status = $db-query(INSERT INTO names (nameId, sexId, fName, lName) VALUES ('', $sexId,

Re: [PHP] Cache Problems

2005-05-20 Thread Richard Lynch
On Fri, May 20, 2005 12:11 pm, Rahul S. Johari said: My whole Auto-Image verification application and has come to get stuck at the Cache in IE. It¹s working fine in Safari on Mac, but IE is picking up the image from the Cache no matter what. I¹ve tried the following: Are you clearing out the

Re: [PHP] Code to bypass a certain php.ini directive

2005-05-20 Thread M Saleh EG
Sure you can! ini_set(display_errors, On); HTH. On 5/21/05, Mário Gamito [EMAIL PROTECTED] wrote: Hi, I have this server with display_errors=Off in php.ini Now that i'm developing a new site. is there some code i can insert in the begining of a .php file to set only for this file

Re: [PHP] ftp_fput() limit is 10 characters

2005-05-20 Thread Richard Lynch
On Fri, May 20, 2005 7:31 am, mayo said: I'm trying to ftp a file. I looked in the php manual and I don't see a character limit for ftp_fput(). I'm getting the following error ftp_fput(): Specified object name too long, limit is 10 characters: CF-20050520. in /home/www/cf/test.php on line 45

Re: [PHP] Image Verification - Problems in Safari, Mac OS X

2005-05-20 Thread Richard Lynch
On Thu, May 19, 2005 6:05 am, Rahul S. Johari said: I did actually remove the Header which declared it as a Image/PNG and everything seemed to work in both the browsers. Great. Now it works in 2 browsers, and breaks in 237. You MUST separate the two. Period. Here's my situation though... I

[PHP] update blues

2005-05-20 Thread Jim Sara Feldman
Hi: I have a partially finished app using PHP and MySQL that runs on Mac G4 running System 10.3.9. Undoubtedly, I upgraded too many things all at the same time. Something broke. PHP and MySQL are both running. I can use the latest phpMyADMIN and everything is there in the database, so that