[PHP] Mastercard Securecode

2009-06-19 Thread Ian
Hi,

A search of google has been unsuccessfull so I am posting here in the hope 
someone 
can help.

We have recently been told that we must implement the Mastercard Securecode 
'feature' 
for all our Maesto transactions or face fines of up $25000 per month. Our 
merchant has 
provided a SDK which has APIs in C, COM or Java (specifically the Arcot 
Transfort 
Merchant Software).

We previously moved away from a Java API into our merchant in favour of a pure 
PHP 
implementation using XML and would rather not take a step back again.


Is anyone aware of a pure PHP implementation of the Mastercard Securecode 
'feature'?


I am aware I can link into COM  Java from PHP, and even take the C API and 
make my 
own extension but I would rather not pursue these options unless I really have 
to!

Regards

Ian
-- 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] sessions tutorial

2009-06-19 Thread Arno Kuhl
-Original Message-
From: PJ [mailto:af.gour...@videotron.ca] 
Sent: 18 June 2009 11:28 PM
To: php-general@lists.php.net
Subject: [PHP] sessions tutorial

Top of the list is for real dummies at tizag.com.
So I don't have to search 282,000 entries for php sessions tutorial (doesn't
this say something about the stupidity on the internet - just how many of
those entries could possibly be real and worth looking at?
Since you gurus (I kowtow) have been there, done that, I would appreciate
hearing of a tutorial that will give something more than you can use
sessions in to store information; like what kind of information, just how
is it used e.g. whatis this, where did it come from, what does it mean? --
if (isset($_REQUEST[ReturnToBooksList]))
and  if (!isset($_SESSION[addNewBooks])) - in these examples it come from
inputs. They were not specifically declared or is this a declaration by
itself... how can I find this information so I can understand how to use it?
I really don't want to bother you guys but do you see the futility here?
My little programs are advancing little by little, but boy is it a struggle
to get any information. I eventually dig it out but, frankly, it might be
more productive digging salt mines in the Urals. :-( PJ the bitcher

--
Hervé Kempf: Pour sauver la planète, sortez du capitalisme.
-
Phil Jourdan --- p...@ptahhotep.com
   http://www.ptahhotep.com
   http://www.chiccantine.com/andypantry.php


-- 

Pour sauver la planète, sortez du capitalisme. - pinko liberal ;)

I'm sure someone else has already proposed this, but... Get an entry-level
book on php, it will answer all your current and future questions about
arrays, forms, sessions, etc. Alternatively look at VTC or Lynda.com for
their excellent video tutorials. I'm sure many of the gurus you refer to
on this list started their path to gurudom by going through one or both
these routes. Definitely easier than digging salt mines, and has the added
advantage of enlightening you to new possibilities you hadn't thought of
before. I've done both (but I'm no guru) and I can definitely recommend
both, especially having a book around for a reference when you want to
quickly check something - easier than trying to find the reference in a
video.

Cheers
Arno


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] [PHP-DEV] PHP 5.3.0RC4

2009-06-19 Thread Lukas Kahwe Smith

Hello!

we have packaged PHP 5.3.0RC4, which you can find here:
http://downloads.php.net/johannes/

Windows binaries are available here:
http://windows.php.net/qa/

This this release candidate focused on bug fixes and stability
improvements and we hope to only require minimal changes ahead
of the next release. Many, but not all,  of the new features are
already integrated in the official documentation on php.net.

We aim to release PHP 5.3.0 next week. In case of critical issues we
will continue producing weekly RCs. For most users there will not be a
noticeable change meaning that now is the time to really do the final
testing of PHP 5.3.0 before it gets released with any unnecessary
incompatibilities with your project.

Some additional links to get started:
http://cvs.php.net/viewvc.cgi/php-src/NEWS?view=markuppathrev=PHP_5_3
http://cvs.php.net/viewvc.cgi/php-src/UPGRADING?revision=PHP_5_3

Best Regards,
Lukas and Johannes
PHP 5.3 Release Managers



--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PEAR Spreadsheet_Excel_Writer setLocked method

2009-06-19 Thread Thodoris



Hey all,

Any one use the PEAR Spreadsheet_Excel_Writer package?

I need to know how to implement the setLocked method to lock out a 
cell, but can't figure out how this would be done.


Do you add it as a format? But then how is it applied to a cell. It's 
not documented on the PEAR pages.


Any help as always is greatly appreciated.

Also, what about making a cell span more than one cell below and above 
it? I can't find a way to do this either.


Thanks,
Skip




I've used it for some time but never needed to lock a cell. Here is a 
piece of code that shows how to apply a format to a cell:


?php
// Include the PEAR script
require 'Spreadsheet/Excel/Writer.php';

// Stop displaying the errors so that the warnings don't get in your 
spreadsheet

// ini_set('display_errors',0);

// Instantiate a workbook
$workbook = new Spreadsheet_Excel_Writer();

// Send it directly to the browser
$workbook-send(test.xls);

// Set the version (very useful for compatibility)
$workbook-setVersion(8);

// Create a worksheet in the workbook
$worksheet = $workbook-addWorksheet('Test');

// Set input encoding
$worksheet-setInputEncoding('UTF-8');

// Create a format
$format_bold = $workbook-addFormat();
$format_bold-setBold();
$format_bold-setHAlign('center');
$format_bold-setFgColor('yellow');

// Apply the format to a cell
$worksheet-writeString(0, 0, Test content, $format_bold);

// Close the workbook
$workbook-close();
?

Hope it helps. I think that by doing something like this:

$format_bold-setLocked();

while creating the format could do the trick but it is not tested.

--
Thodoris


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] sessions tutorial

2009-06-19 Thread Thodoris



Top of the list is for real dummies at tizag.com.
So I don't have to search 282,000 entries for php sessions tutorial
(doesn't this say something about the stupidity on the internet - just
how many of those entries could possibly be real and worth looking at?
Since you gurus (I kowtow) have been there, done that, I would
appreciate hearing of a tutorial that will give something more than you
can use sessions in to store information; like what kind of
information, just how is it used e.g. whatis this, where did it come
from, what does it mean? -- if (isset($_REQUEST[ReturnToBooksList]))
and  if (!isset($_SESSION[addNewBooks])) - in these examples it come
from inputs. They were not specifically declared or is this a
declaration by itself... how can I find this information so I can
understand how to use it?
I really don't want to bother you guys but do you see the futility here?
My little programs are advancing little by little, but boy is it a
struggle to get any information. I eventually dig it out but, frankly,
it might be more productive digging salt mines in the Urals. :-(
PJ the bitcher

  


You could always read the manual for starters:

http://www.php.net/manual/en/book.session.php

It gives you a pretty good picture on sessions. Google could also help 
as usual:


http://www.google.gr/search?q=php+how+to+use+sessionsie=utf-8oe=utf-8aq=trls=org.mozilla:el:officialclient=firefox-a

besides the first hit which is tizag there others you could look into 
for info.


I know I've stated the *obvious* but I think you should try it nonetheless.


--
Thodoris



Re: [PHP] Calendar

2009-06-19 Thread Tom Chubb
http://lmgtfy.com/?q=javascript+calendar

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Calendar

2009-06-19 Thread Sudheer Satyanarayana

salmarayan wrote:

Does Any body please have the code of A Java Script Calendar that works with
a PHP Html  Form.. 
if yes can you please send it as i have one but does not work that

Efficiently.

Thanks in advance
  

This might help if you are looking for a date picker

http://techchorus.net/add-cool-date-picker-2-lines-javascript


--

With warm regards,
Sudheer. S
Business: http://binaryvibes.co.in, Tech stuff: http://techchorus.net, 
Personal: http://sudheer.net


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] RE: [PHP-DEV] PHP 5.3.0RC4

2009-06-19 Thread Uwe Schindler
Hallo,

 

I just wanted to compile PHP 5.3.0RC4 on my Solaris 10 box:

 

panga...@pansrv1:~/install/php-5.3.0RC4$ gcc -v

Reading specs from /opt/csw/gcc3/lib/gcc/i386-pc-solaris2.8/3.4.5/specs

Configured with: ../sources/gcc-3.4.5/configure --prefix=/opt/csw/gcc3
--with-local-prefix=/opt/csw --with-gnu-as --with-as=/opt/csw/bin/gas
--without-gnu-ld --with-ld=/usr/ccs/bin/ld --enable-threads=posix
--enable-shared --enable-multilib --enable-nls --with-included-gettext
--with-libiconv-prefix=/opt/csw --with-x --enable-java-awt=xlib
--enable-languages=all

Thread model: posix

gcc version 3.4.5

 

and got a compilation failure:

 

/bin/sh /pangaea/install/php-5.3.0RC4/libtool --silent --preserve-dup-deps
--mode=compile gcc -I/pangaea/install/php-5.3.0RC4/ext -I -Iext/pdo_mysql/
-I/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/ -DPHP_ATOM_INC
-I/pangaea/install/php-5.3.0RC4/include -I/pangaea/install/php-5.3.0RC4/main
-I/pangaea/install/php-5.3.0RC4 -I/pangaea/webserver70/include
-I/pangaea/install/php-5.3.0RC4/ext/date/lib
-I/pangaea/install/php-5.3.0RC4/ext/ereg/regex -I/opt/csw/include/libxml2
-I/opt/csw/include -I/pangaea/install/php-5.3.0RC4/ext/mbstring/oniguruma
-I/pangaea/install/php-5.3.0RC4/ext/mbstring/libmbfl
-I/pangaea/install/php-5.3.0RC4/ext/mbstring/libmbfl/mbfl
-I/opt/csw/mysql5/include/mysql -I/usr/include/libxml2
-I/pangaea/install/php-5.3.0RC4/TSRM -I/pangaea/install/php-5.3.0RC4/Zend
-D_POSIX_PTHREAD_SEMANTICS -D_POSIX_PTHREAD_SEMANTICS -D_REENTRANT
-I/opt/csw/include -g -O2 -DZTS   -c
/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c -o
ext/pdo_mysql/mysql_statement.lo 

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c: In function
`pdo_mysql_stmt_dtor':

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c:52: error:
structure has no member named `stmt'

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c:70: error:
structure has no member named `params'

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c:71: error:
structure has no member named `params'

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c:73: error:
structure has no member named `in_null'

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c:74: error:
structure has no member named `in_null'

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c:76: error:
structure has no member named `in_length'

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c:77: error:
structure has no member named `in_length'

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c: In function
`pdo_mysql_stmt_set_row_count':

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c:127: error:
structure has no member named `stmt'

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c: In function
`pdo_mysql_stmt_execute':

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c:295: error:
structure has no member named `stmt'

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c: In function
`pdo_mysql_stmt_describe':

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c:678: error:
structure has no member named `stmt'

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c: In function
`pdo_mysql_stmt_get_col':

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c:727: error:
structure has no member named `stmt'

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c: In function
`pdo_mysql_stmt_col_meta':

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c:831: error:
structure has no member named `stmt'

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c: In function
`pdo_mysql_stmt_cursor_closer':

/pangaea/install/php-5.3.0RC4/ext/pdo_mysql/mysql_statement.c:898: error:
structure has no member named `stmt'

gmake: *** [ext/pdo_mysql/mysql_statement.lo] Error 1

 

 

Is this a known bug?

 

Uwe

 

-

Uwe Schindler

theta...@php.net - http://www.php.net

NSAPI SAPI developer

Bremen, Germany

 

 

 -Original Message-

 From: Lukas Kahwe Smith [mailto:m...@pooteeweet.org]

 Sent: Friday, June 19, 2009 10:51 AM

 To: intern...@lists.php.net; php-general@lists.php.net

 Subject: [PHP-DEV] PHP 5.3.0RC4

 

 Hello!

 

 we have packaged PHP 5.3.0RC4, which you can find here:

 http://downloads.php.net/johannes/

 

 Windows binaries are available here:

 http://windows.php.net/qa/

 

 This this release candidate focused on bug fixes and stability

 improvements and we hope to only require minimal changes ahead

 of the next release. Many, but not all,  of the new features are

 already integrated in the official documentation on php.net.

 

 We aim to release PHP 5.3.0 next week. In case of critical issues we

 will continue producing weekly RCs. For most users there will not be a

 noticeable change meaning that now is the time to really do the final

 testing of PHP 5.3.0 before it gets released with any unnecessary

 incompatibilities with your 

[PHP] PHP MySQL 500 Internal Error

2009-06-19 Thread Shawn Simmons

Greetings Gurus!


I am attempting to use PHP+MYSQL+APACHE and I have downloaded all the latest 
verions and installed them on a fresh windows XP install.  Got the Apache 
server up and running, got MySQL up and running and installed PHP.  Tested 
PHP with a script containing phpinfo().  Everything works great.


Wrote a small script to connect to the MySql database.  Tried to run the 
script (http://localhost/dbscript.php) and I get a 500 Internal Server 
error.  I have been up and down the web for two days looking for a solution 
and I am completely frustrated.  I HAVE to be missing something.  PLEASE 
PLEASE PLEASE help.  Thanks.


MySql is enabled in php.ini.  Paths are set to the php folder.  I have NOT 
moved or copied any files whatsoever.  Apache version is 2.2.


Thanks. 



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] 500 Internal Error

2009-06-19 Thread Shawn Simmons

Greetings Gurus!


I am attempting to use PHP+MYSQL+APACHE and I have downloaded all the latest 
verions and installed them on a fresh windows XP install.  Got the Apache 
server up and running, got MySQL up and running and installed PHP.  Tested 
PHP with a script containing phpinfo().  Everything works great.


Wrote a small script to connect to the MySql database.  Tried to run the 
script (http://localhost/dbscript.php) and I get a 500 Internal Server 
error.  I have been up and down the web for two days looking for a solution 
and I am completely frustrated.  I HAVE to be missing something.  PLEASE 
PLEASE PLEASE help.  Thanks.


MySql is enabled in php.ini.  Paths are set to the php folder.  I have NOT 
moved or copied any files whatsoever.  Apache version is 2.2.


Thanks. 



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: Help: PHP version not up to date after apt-get install php5-dev

2009-06-19 Thread Thodoris



Why not just compile it yourself?


  


Why not let the ports system compile it for you and then have the choice 
to remove it as package whenever you like...

You get it compiled and packaged the same time...

:-)

I guess BSD is the way to make your life easier...

--
Thodoris


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] 500 Internal Error

2009-06-19 Thread Thodoris



Greetings Gurus!


I am attempting to use PHP+MYSQL+APACHE and I have downloaded all the 
latest verions and installed them on a fresh windows XP install.  Got 
the Apache server up and running, got MySQL up and running and 
installed PHP.  Tested PHP with a script containing phpinfo().  
Everything works great.


Wrote a small script to connect to the MySql database.  Tried to run 
the script (http://localhost/dbscript.php) and I get a 500 Internal 
Server error.  I have been up and down the web for two days looking 
for a solution and I am completely frustrated.  I HAVE to be missing 
something.  PLEASE PLEASE PLEASE help.  Thanks.


MySql is enabled in php.ini.  Paths are set to the php folder.  I have 
NOT moved or copied any files whatsoever.  Apache version is 2.2.


Thanks.



Since you are a windows user and you need to begin coding in PHP etc why 
don't you try WAMP for starters?


http://www.wampserver.com/en/

It gives you all you need in one package.

--
Thodoris


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PHP MySQL 500 Internal Error

2009-06-19 Thread Paul Scott
On Thu, 2009-06-18 at 22:10 -0400, Shawn Simmons wrote:
 Wrote a small script to connect to the MySql database.  Tried to run the 
 script (http://localhost/dbscript.php) and I get a 500 Internal Server 
 error.  I have been up and down the web for two days looking for a solution 
 and I am completely frustrated.  I HAVE to be missing something.  PLEASE 
 PLEASE PLEASE help.  Thanks.
 

Check permissions and ownership on the file. That often happens when the
permissions are set to 0777 as opposed to 755 (in *nix speak), so check
that the webserver user has read and execute access on the file and that
it ownds the directory etc


-- Paul
http://www.paulscott.za.net
http://twitter.com/paulscott56
http://avoir.uwc.ac.za
-- 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] PHP MySQL 500 Internal Error

2009-06-19 Thread Yuri Yarlei

Check the mysql user permissions, then check the root directory permissions, if 
you use some .htacess file, check this to.
This error occurs when you have, permissions errors, server is not working 
well, .htacess errors and other things, try acess your script to with 
http://127.0.0.1

Yuri Yarlei.
Programmer PHP, CSS, Java, PostregreSQL;
Today PHP, tomorrow Java, after the world.
Kyou wa PHP, ashita wa Java, sono ato sekai desu.



 To: php-general@lists.php.net
 From: elcid...@gmail.com
 Date: Thu, 18 Jun 2009 22:10:44 -0400
 Subject: [PHP] PHP MySQL 500 Internal Error
 
 Greetings Gurus!
 
 
 I am attempting to use PHP+MYSQL+APACHE and I have downloaded all the latest 
 verions and installed them on a fresh windows XP install.  Got the Apache 
 server up and running, got MySQL up and running and installed PHP.  Tested 
 PHP with a script containing phpinfo().  Everything works great.
 
 Wrote a small script to connect to the MySql database.  Tried to run the 
 script (http://localhost/dbscript.php) and I get a 500 Internal Server 
 error.  I have been up and down the web for two days looking for a solution 
 and I am completely frustrated.  I HAVE to be missing something.  PLEASE 
 PLEASE PLEASE help.  Thanks.
 
 MySql is enabled in php.ini.  Paths are set to the php folder.  I have NOT 
 moved or copied any files whatsoever.  Apache version is 2.2.
 
 Thanks. 
 
 
 -- 
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php
 

_
Deixe suas conversas mais divertidas. Baixe agora mesmo novos emoticons. É 
grátis!
http://specials.br.msn.com/ilovemessenger/pacotes.aspx

RE: [PHP] isset question

2009-06-19 Thread Ford, Mike
On 18 June 2009 20:25, LAMP advised:

 using !empty() instead isset() will work if you don't care for PHP
 Notice: Undefined variable... If you want to avoid PHP Notice
 you have
 to use both:
 
 $msg.=  (isset($_POST['mort']) and !empty($_POST['mort'])) ? The
 mortgage amount is  $mort\n :  ;

Absolute rubbish -- as it says at http://php.net/empty, empty($var) is
the opposite of (boolean)$var, except that no warning is generated when
the variable is not set. -- so protecting empty() with an isset() is
a total waste of time, space and cpu cycles.

Cheers!

Mike

 --
Mike Ford,  Electronic Information Developer,
C507, Leeds Metropolitan University, Civic Quarter Campus, 
Woodhouse Lane, LEEDS,  LS1 3HE,  United Kingdom
Email: m.f...@leedsmet.ac.uk
Tel: +44 113 812 4730





To view the terms under which this email is distributed, please go to 
http://disclaimer.leedsmet.ac.uk/email.htm

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] 500 Internal Error

2009-06-19 Thread Bastien Koert
Ensure that you have 'show friendly error messages in the Internet
explorer is turned off ( unchecked ).


IE does like to hide errors with this feature.

Bastien


On Thursday, June 18, 2009, Shawn Simmons elcid...@gmail.com wrote:
 Greetings Gurus!


 I am attempting to use PHP+MYSQL+APACHE and I have downloaded all the latest 
 verions and installed them on a fresh windows XP install.  Got the Apache 
 server up and running, got MySQL up and running and installed PHP.  Tested 
 PHP with a script containing phpinfo().  Everything works great.

 Wrote a small script to connect to the MySql database.  Tried to run the 
 script (http://localhost/dbscript.php) and I get a 500 Internal Server error. 
  I have been up and down the web for two days looking for a solution and I am 
 completely frustrated.  I HAVE to be missing something.  PLEASE PLEASE PLEASE 
 help.  Thanks.

 MySql is enabled in php.ini.  Paths are set to the php folder.  I have NOT 
 moved or copied any files whatsoever.  Apache version is 2.2.

 Thanks.

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php



-- 

Bastien

Cat, the other other white meat

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] sessions tutorial

2009-06-19 Thread Michael A. Peters

PJ wrote:

 I would
appreciate hearing of a tutorial that will give something more than you
can use sessions in to store information; like what kind of
information


Information on how to skin a cat.
It's amazing how many ways there are too do it.

I think it is in the neighborhood of 282,000.


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] 500 Internal Error

2009-06-19 Thread Michael A. Peters

Bastien Koert wrote:

Ensure that you have 'show friendly error messages in the Internet
explorer is turned off ( unchecked ).


IE does like to hide errors with this feature.


A 500 internal server error is likely due to apache/php 
mis-configuration, it's doubtful any useful errors would have been given 
to IE to hide.


However, the apache log files might have something - and is always where 
one should look first when the error is server side.


If phpinfo() is working, it might be of value to see the code for the 
script resulting in a 500 internal server error.




Bastien


On Thursday, June 18, 2009, Shawn Simmons elcid...@gmail.com wrote:

Greetings Gurus!


I am attempting to use PHP+MYSQL+APACHE and I have downloaded all the latest 
verions and installed them on a fresh windows XP install.  Got the Apache 
server up and running, got MySQL up and running and installed PHP.  Tested PHP 
with a script containing phpinfo().  Everything works great.

Wrote a small script to connect to the MySql database.  Tried to run the script 
(http://localhost/dbscript.php) and I get a 500 Internal Server error.  I have 
been up and down the web for two days looking for a solution and I am 
completely frustrated.  I HAVE to be missing something.  PLEASE PLEASE PLEASE 
help.  Thanks.

MySql is enabled in php.ini.  Paths are set to the php folder.  I have NOT 
moved or copied any files whatsoever.  Apache version is 2.2.

Thanks.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php







--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] 500 Internal Error

2009-06-19 Thread Daniel Brown
On Thu, Jun 18, 2009 at 22:05, Shawn Simmonselcid...@gmail.com wrote:

 Wrote a small script to connect to the MySql database.  Tried to run the
 script (http://localhost/dbscript.php) and I get a 500 Internal Server
 error.  I have been up and down the web for two days looking for a solution
 and I am completely frustrated.  I HAVE to be missing something.  PLEASE
 PLEASE PLEASE help.  Thanks.

HTTP code 500 is, as the error message suggests, a *server* error.
 Meaning, it has nothing to do with MySQL, and likely is not related
to PHP, but instead is a problem with the Apache configuration and/or
permissions of the file.  Check to make sure the dbinfo.php file is
owned by the appropriate user and has permissions set to allow it to
be read and executed.  Though not as prevalent as on *nix systems,
permissions errors can and do occur on Windows systems.

If nothing seems out of place there, the next step is to check the
log files.  See if there's anything in Apache's error log related to
this message (there should be, and being a local server, it should be
one of the only things).

Finally, if you can't find anything there, the next phase begins
by asking your question in the right place.  Now that you know it's
not a PHP error that's causing it, and since we can also rule-out
MySQL, we know it's an Apache issue.  Best bet in this case is to go
right to the source and ask on the httpd User Support list[1].  It
could be any number of things, from what I mentioned above about
permissions, to improper encoding, to a module not loading correctly,
to gremlin droppings in your upper memory (hey, it's Windows).

In any case, searching the web for two days was indeed the best
place to start, so showing that intelligence gives you a leg up on
many of the folks on the Internet today --- so there's no doubt in my
mind that you'll have the issue resolved frustrating though it may
be right now.  If worse comes to worst, and you just want to move on
with developing, there are several simple options for deploying a WAMP
system.  I would personally recommend XAMPP[1], but there are many
other choices available as well.


Ref:
^1: http://httpd.apache.org/lists.html#http-users
^2: http://www.apachefriends.org/en/xampp-windows.html

-- 
/Daniel P. Brown
daniel.br...@parasane.net || danbr...@php.net
http://www.parasane.net/ || http://www.pilotpig.net/
50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW1

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PHP MySQL 500 Internal Error

2009-06-19 Thread Daniel Brown
On Thu, Jun 18, 2009 at 22:10, Shawn Simmonselcid...@gmail.com wrote:
 Greetings Gurus!

Also, please keep new threads on the list limited to one at a
time, except in extenuating circumstances.  And as a developer, there
certainly are and will be more of those circumstances.  ;-P

-- 
/Daniel P. Brown
daniel.br...@parasane.net || danbr...@php.net
http://www.parasane.net/ || http://www.pilotpig.net/
50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW1

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Mastercard Securecode

2009-06-19 Thread Eddie Drapkin
I've not heard of anything like that, but turning the C API into an
extension would be a huge plus for PHP and I heartily recommend it (as
long as it's not me writing it ^.^)!

On Fri, Jun 19, 2009 at 4:14 AM, Ianphp_l...@fishnet.co.uk wrote:
 Hi,

 A search of google has been unsuccessfull so I am posting here in the hope 
 someone
 can help.

 We have recently been told that we must implement the Mastercard Securecode 
 'feature'
 for all our Maesto transactions or face fines of up $25000 per month. Our 
 merchant has
 provided a SDK which has APIs in C, COM or Java (specifically the Arcot 
 Transfort
 Merchant Software).

 We previously moved away from a Java API into our merchant in favour of a 
 pure PHP
 implementation using XML and would rather not take a step back again.


 Is anyone aware of a pure PHP implementation of the Mastercard Securecode 
 'feature'?


 I am aware I can link into COM  Java from PHP, and even take the C API and 
 make my
 own extension but I would rather not pursue these options unless I really 
 have to!

 Regards

 Ian
 --


 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] sessions tutorial

2009-06-19 Thread Bastien Koert
[snip]
 Information on how to skin a cat.
 It's amazing how many ways there are too do it.

 I think it is in the neighborhood of 282,000.
[/snip]

Still tastes like chicken!



-- 

Bastien

Cat, the other other white meat

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PHP MySQL 500 Internal Error

2009-06-19 Thread Shawn Simmons
Sorry about thatI wasn't sure if it went the first time when I didn't 
see the post sfter a refresh8-)




Daniel Brown danbr...@php.net wrote in message 
news:ab5568160906190558u1a585cedpf73eb5690330d...@mail.gmail.com...

On Thu, Jun 18, 2009 at 22:10, Shawn Simmonselcid...@gmail.com wrote:

Greetings Gurus!


   Also, please keep new threads on the list limited to one at a
time, except in extenuating circumstances.  And as a developer, there
certainly are and will be more of those circumstances.  ;-P

--
/Daniel P. Brown
daniel.br...@parasane.net || danbr...@php.net
http://www.parasane.net/ || http://www.pilotpig.net/
50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW1 



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] How to read excel sheet and display it's contents.

2009-06-19 Thread jadhavpradip

Hi,

There is oleread.inc file in Excel Folder.

Please rename that file to oleread.php it will work.. =)

Regards,
Pradip Jadhav

srihari naidu wrote:
 
 Hi, can any suggest me how to read and display the content in a html page.

   I tried phpexcelreadrer at 
 http://sourceforge.net/projects/phpexcelreader/  but got error 

   Warning: require_once(Spreadsheet/Excel/Reader/OLERead.php)
 [function.require-once]: failed to open stream: No such file or directory
 in D:\phpdocs\reader2\Excel\reader.php on line 31
 
 Fatal error: require_once() [function.require]: Failed opening required
 'Spreadsheet/Excel/Reader/OLERead.php' (include_path='.;C:\php5\pear') in
 D:\phpdocs\reader2\Excel\reader.php on line 31


   can any please suggest me the solution for this error please.

   Thanks in advance

   Regards,
   Sri Hari
 

 -
 Never miss a thing.   Make Yahoo your homepage.
 

-- 
View this message in context: 
http://www.nabble.com/How-to-read-excel-sheet-and-display-it%27s-contents.-tp15422690p24110951.html
Sent from the PHP - General mailing list archive at Nabble.com.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] How to read excel sheet and display it's contents.

2009-06-19 Thread Daniel Brown
On Fri, Jun 19, 2009 at 09:17, jadhavpradipjadhavpradi...@gmail.com wrote:

 Hi,

 There is oleread.inc file in Excel Folder.

 Please rename that file to oleread.php it will work.. =)

Please check the dates before posting on third-party sites to this
list.  That thread is over a year-and-a-half old.

-- 
/Daniel P. Brown
daniel.br...@parasane.net || danbr...@php.net
http://www.parasane.net/ || http://www.pilotpig.net/
50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW1

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] OCSP DER encoding implemenation?

2009-06-19 Thread Greg Beaver
Hi,

Does anyone have a non-GPLed implementation of DER encoding for an
OpenSSL certificate authority OCSP request floating around, or even a
basic DER encoder?

Thanks,
Greg

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: Issue with filter_var and FILTER_VALIDATE_EMAIL

2009-06-19 Thread Bastien Koert
Correct, I send the @


Bastien

On Friday, June 19, 2009, Jonathan Tapicer tapi...@gmail.com wrote:
 Works for me:

          var_dump(filter_var('bastien_k(a)hotmail.com http://hotmail.com',
 FILTER_VALIDATE_EMAIL) !== false); //replace (a) with @

 Gives:

          bool(true)

 You are sending an @ instead of  at , right?

 Jonathan


 On Fri, Jun 19, 2009 at 11:49 AM, Bastien Koertphps...@gmail.com wrote:
 Hey guys,

 Running the new version of PHPMailer and my hotmail address fails the
 validation.

 Email address is bastien_k at hotmail dot com

 Any ideas?

 --

 Bastien

 Cat, the other other white meat

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php




-- 

Bastien

Cat, the other other white meat

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: Issue with filter_var and FILTER_VALIDATE_EMAIL

2009-06-19 Thread Jonathan Tapicer
Did you execute the code I sent? Does it give you a false?

Jonathan

On Fri, Jun 19, 2009 at 12:17 PM, Bastien Koertphps...@gmail.com wrote:
 Correct, I send the @


 Bastien

 On Friday, June 19, 2009, Jonathan Tapicer tapi...@gmail.com wrote:
 Works for me:

          var_dump(filter_var('bastien_k(a)hotmail.com http://hotmail.com',
 FILTER_VALIDATE_EMAIL) !== false); //replace (a) with @

 Gives:

          bool(true)

 You are sending an @ instead of  at , right?

 Jonathan


 On Fri, Jun 19, 2009 at 11:49 AM, Bastien Koertphps...@gmail.com wrote:
 Hey guys,

 Running the new version of PHPMailer and my hotmail address fails the
 validation.

 Email address is bastien_k at hotmail dot com

 Any ideas?

 --

 Bastien

 Cat, the other other white meat

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php




 --

 Bastien

 Cat, the other other white meat


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: accessing level above $_SERVER['DOCUMENT_ROOT']

2009-06-19 Thread Peter Ford
LAMP wrote:
 hi,
 
 I have this structure:
 /home/lamp/mydomain/html
 /home/lamp/mydomain/logs
 /home/lamp/mydomain/config
 etc.
 
 html directory is the only one accessible from outside.
 
 to access config file I can use this:
 required_once('/home/lamp/mydomain/config');
 
 but this is the structure on my local/development machine. once the site
 is done it will be moved to production server and the structure will be
 /srv/www/mydomain/html
 /srv/www/mydomain/logs
 /srv/www/mydomain/config
 etc.
 
 to automate the document_root I define on the begining of the page
 
 define('HTML_PATH', $_SERVER{DOCUMENT_ROOT']);
 define('CONFIG_PATH', $_SERVER{DOCUMENT_ROOT'].'/../config');
 define('LOGS_PATH', $_SERVER{DOCUMENT_ROOT'].'/../logs');
 
 it works but I think it's not good solution. or at least - it's not nice
 solution :-)
 
 suggestions?
 
 afan
 
 

Outside of a define, you could have used dirname($_SERVER[DOCUMENT_ROOT]), but
in a define, that's not going to work.
I think you're stuck with your inelegance...

-- 
Peter Ford  phone: 01580 89
Developer   fax:   01580 893399
Justcroft International Ltd., Staplehurst, Kent

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: Issue with filter_var and FILTER_VALIDATE_EMAIL

2009-06-19 Thread Bastien Koert
On Fri, Jun 19, 2009 at 11:20 AM, Jonathan Tapicertapi...@gmail.com wrote:
 Did you execute the code I sent? Does it give you a false?

 Jonathan

 On Fri, Jun 19, 2009 at 12:17 PM, Bastien Koertphps...@gmail.com wrote:
 Correct, I send the @


 Bastien

 On Friday, June 19, 2009, Jonathan Tapicer tapi...@gmail.com wrote:
 Works for me:

          var_dump(filter_var('bastien_k(a)hotmail.com http://hotmail.com',
 FILTER_VALIDATE_EMAIL) !== false); //replace (a) with @

 Gives:

          bool(true)

 You are sending an @ instead of  at , right?

 Jonathan


 On Fri, Jun 19, 2009 at 11:49 AM, Bastien Koertphps...@gmail.com wrote:
 Hey guys,

 Running the new version of PHPMailer and my hotmail address fails the
 validation.

 Email address is bastien_k at hotmail dot com

 Any ideas?

 --

 Bastien

 Cat, the other other white meat

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php




 --

 Bastien

 Cat, the other other white meat



this is the relevant function from phpmailer
  public static function ValidateAddress($address) {
if (function_exists('filter_var')) { //Introduced in PHP 5.2
  if(filter_var($address, FILTER_VALIDATE_EMAIL) === FALSE) {
return false;
  } else {
   return true;
  }
} else {
  return 
preg_match('/^(?:[\w\!\#\$\%\\'\*\+\-\/\=\?\^\`\{\|\}\~]+\.)*[\w\!\#\$\%\\'\*\+\-\/\=\?\^\`\{\|\}\~]+@(?:(?:(?:[a-zA-Z0-9_](?:[a-zA-Z0-9_\-](?!\.)){0,61}[a-zA-Z0-9_-]?\.)+[a-zA-Z0-9_](?:[a-zA-Z0-9_\-](?!$)){0,61}[a-zA-Z0-9_]?)|(?:\[(?:(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\.){3}(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\]))$/',
$address);
}

  }



-- 

Bastien

Cat, the other other white meat

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Issue with filter_var and FILTER_VALIDATE_EMAIL

2009-06-19 Thread Jonathan Tapicer
Works for me:

 var_dump(filter_var('bastien_k(a)hotmail.com',
FILTER_VALIDATE_EMAIL) !== false); //replace (a) with @

Gives:

 bool(true)

You are sending an @ instead of  at , right?

Jonathan


On Fri, Jun 19, 2009 at 11:49 AM, Bastien Koertphps...@gmail.com wrote:
 Hey guys,

 Running the new version of PHPMailer and my hotmail address fails the
 validation.

 Email address is bastien_k at hotmail dot com

 Any ideas?

 --

 Bastien

 Cat, the other other white meat

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: Issue with filter_var and FILTER_VALIDATE_EMAIL

2009-06-19 Thread Shawn McKenzie
Bastien Koert wrote:
 On Fri, Jun 19, 2009 at 11:20 AM, Jonathan Tapicertapi...@gmail.com wrote:
 Did you execute the code I sent? Does it give you a false?

 Jonathan

 On Fri, Jun 19, 2009 at 12:17 PM, Bastien Koertphps...@gmail.com wrote:
 Correct, I send the @


 Bastien

 On Friday, June 19, 2009, Jonathan Tapicer tapi...@gmail.com wrote:
 Works for me:

  var_dump(filter_var('bastien_k(a)hotmail.com 
 http://hotmail.com',
 FILTER_VALIDATE_EMAIL) !== false); //replace (a) with @

 Gives:

  bool(true)

 You are sending an @ instead of  at , right?

 Jonathan


 On Fri, Jun 19, 2009 at 11:49 AM, Bastien Koertphps...@gmail.com wrote:
 Hey guys,

 Running the new version of PHPMailer and my hotmail address fails the
 validation.

 Email address is bastien_k at hotmail dot com

 Any ideas?

 --

 Bastien

 Cat, the other other white meat

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php


 --

 Bastien

 Cat, the other other white meat

 
 this is the relevant function from phpmailer
   public static function ValidateAddress($address) {
 if (function_exists('filter_var')) { //Introduced in PHP 5.2
   if(filter_var($address, FILTER_VALIDATE_EMAIL) === FALSE) {
 return false;
   } else {
return true;
   }
 } else {
   return 
 preg_match('/^(?:[\w\!\#\$\%\\'\*\+\-\/\=\?\^\`\{\|\}\~]+\.)*[\w\!\#\$\%\\'\*\+\-\/\=\?\^\`\{\|\}\~]+@(?:(?:(?:[a-zA-Z0-9_](?:[a-zA-Z0-9_\-](?!\.)){0,61}[a-zA-Z0-9_-]?\.)+[a-zA-Z0-9_](?:[a-zA-Z0-9_\-](?!$)){0,61}[a-zA-Z0-9_]?)|(?:\[(?:(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\.){3}(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\]))$/',
 $address);
 }
 
   }
 
 
 

Is your PHP version = 5.2?  If not then the regex will return 1, so in
your code don't check for === true.  Try == true if that's what you're
doing.

-- 
Thanks!
-Shawn
http://www.spidean.com

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: accessing level above $_SERVER['DOCUMENT_ROOT']

2009-06-19 Thread Shawn McKenzie
Peter Ford wrote:
 LAMP wrote:
 hi,

 I have this structure:
 /home/lamp/mydomain/html
 /home/lamp/mydomain/logs
 /home/lamp/mydomain/config
 etc.

 html directory is the only one accessible from outside.

 to access config file I can use this:
 required_once('/home/lamp/mydomain/config');

 but this is the structure on my local/development machine. once the site
 is done it will be moved to production server and the structure will be
 /srv/www/mydomain/html
 /srv/www/mydomain/logs
 /srv/www/mydomain/config
 etc.

 to automate the document_root I define on the begining of the page

 define('HTML_PATH', $_SERVER{DOCUMENT_ROOT']);
 define('CONFIG_PATH', $_SERVER{DOCUMENT_ROOT'].'/../config');
 define('LOGS_PATH', $_SERVER{DOCUMENT_ROOT'].'/../logs');

 it works but I think it's not good solution. or at least - it's not nice
 solution :-)

 suggestions?

 afan


 
 Outside of a define, you could have used dirname($_SERVER[DOCUMENT_ROOT]), 
 but
 in a define, that's not going to work.
 I think you're stuck with your inelegance...
 

Why won't that work in a define()?  Have you tried it?  I would if I
were you.

-- 
Thanks!
-Shawn
http://www.spidean.com

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: Issue with filter_var and FILTER_VALIDATE_EMAIL

2009-06-19 Thread Bastien Koert
On Fri, Jun 19, 2009 at 11:46 AM, Shawn McKenzienos...@mckenzies.net wrote:
 Bastien Koert wrote:
 On Fri, Jun 19, 2009 at 11:20 AM, Jonathan Tapicertapi...@gmail.com wrote:
 Did you execute the code I sent? Does it give you a false?

 Jonathan

 On Fri, Jun 19, 2009 at 12:17 PM, Bastien Koertphps...@gmail.com wrote:
 Correct, I send the @


 Bastien

 On Friday, June 19, 2009, Jonathan Tapicer tapi...@gmail.com wrote:
 Works for me:

          var_dump(filter_var('bastien_k(a)hotmail.com 
 http://hotmail.com',
 FILTER_VALIDATE_EMAIL) !== false); //replace (a) with @

 Gives:

          bool(true)

 You are sending an @ instead of  at , right?

 Jonathan


 On Fri, Jun 19, 2009 at 11:49 AM, Bastien Koertphps...@gmail.com wrote:
 Hey guys,

 Running the new version of PHPMailer and my hotmail address fails the
 validation.

 Email address is bastien_k at hotmail dot com

 Any ideas?

 --

 Bastien

 Cat, the other other white meat

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php


 --

 Bastien

 Cat, the other other white meat


 this is the relevant function from phpmailer
   public static function ValidateAddress($address) {
     if (function_exists('filter_var')) { //Introduced in PHP 5.2
       if(filter_var($address, FILTER_VALIDATE_EMAIL) === FALSE) {
         return false;
       } else {
        return true;
       }
     } else {
       return 
 preg_match('/^(?:[\w\!\#\$\%\\'\*\+\-\/\=\?\^\`\{\|\}\~]+\.)*[\w\!\#\$\%\\'\*\+\-\/\=\?\^\`\{\|\}\~]+@(?:(?:(?:[a-zA-Z0-9_](?:[a-zA-Z0-9_\-](?!\.)){0,61}[a-zA-Z0-9_-]?\.)+[a-zA-Z0-9_](?:[a-zA-Z0-9_\-](?!$)){0,61}[a-zA-Z0-9_]?)|(?:\[(?:(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\.){3}(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\]))$/',
 $address);
     }

   }




 Is your PHP version = 5.2?  If not then the regex will return 1, so in
 your code don't check for === true.  Try == true if that's what you're
 doing.

 --
 Thanks!
 -Shawn
 http://www.spidean.com

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php




its 5.2.4
-- 

Bastien

Cat, the other other white meat

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: Issue with filter_var and FILTER_VALIDATE_EMAIL

2009-06-19 Thread Jonathan Tapicer
Can you check if the code is using true or false branch of the first if?


On Fri, Jun 19, 2009 at 12:56 PM, Bastien Koertphps...@gmail.com wrote:
 On Fri, Jun 19, 2009 at 11:46 AM, Shawn McKenzienos...@mckenzies.net wrote:
 Bastien Koert wrote:
 On Fri, Jun 19, 2009 at 11:20 AM, Jonathan Tapicertapi...@gmail.com wrote:
 Did you execute the code I sent? Does it give you a false?

 Jonathan

 On Fri, Jun 19, 2009 at 12:17 PM, Bastien Koertphps...@gmail.com wrote:
 Correct, I send the @


 Bastien

 On Friday, June 19, 2009, Jonathan Tapicer tapi...@gmail.com wrote:
 Works for me:

          var_dump(filter_var('bastien_k(a)hotmail.com 
 http://hotmail.com',
 FILTER_VALIDATE_EMAIL) !== false); //replace (a) with @

 Gives:

          bool(true)

 You are sending an @ instead of  at , right?

 Jonathan


 On Fri, Jun 19, 2009 at 11:49 AM, Bastien Koertphps...@gmail.com wrote:
 Hey guys,

 Running the new version of PHPMailer and my hotmail address fails the
 validation.

 Email address is bastien_k at hotmail dot com

 Any ideas?

 --

 Bastien

 Cat, the other other white meat

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php


 --

 Bastien

 Cat, the other other white meat


 this is the relevant function from phpmailer
   public static function ValidateAddress($address) {
     if (function_exists('filter_var')) { //Introduced in PHP 5.2
       if(filter_var($address, FILTER_VALIDATE_EMAIL) === FALSE) {
         return false;
       } else {
        return true;
       }
     } else {
       return 
 preg_match('/^(?:[\w\!\#\$\%\\'\*\+\-\/\=\?\^\`\{\|\}\~]+\.)*[\w\!\#\$\%\\'\*\+\-\/\=\?\^\`\{\|\}\~]+@(?:(?:(?:[a-zA-Z0-9_](?:[a-zA-Z0-9_\-](?!\.)){0,61}[a-zA-Z0-9_-]?\.)+[a-zA-Z0-9_](?:[a-zA-Z0-9_\-](?!$)){0,61}[a-zA-Z0-9_]?)|(?:\[(?:(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\.){3}(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\]))$/',
 $address);
     }

   }




 Is your PHP version = 5.2?  If not then the regex will return 1, so in
 your code don't check for === true.  Try == true if that's what you're
 doing.

 --
 Thanks!
 -Shawn
 http://www.spidean.com

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php




 its 5.2.4
 --

 Bastien

 Cat, the other other white meat

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] 500 Internal Error

2009-06-19 Thread Carlos Medina

Hi,
can you get a test echo with: echo test;exit when you call your
dbscript.php?
If not so. Your Problem is a install problem and need more info about
where, what and permissions (Permissions are allways a problem for this
strange cases)

If you get a test then you problem can be the MySQL Functions you are
doing. Here we need more Information/examples what you are doing.

Regards

Carlos

Thodoris schrieb:



Greetings Gurus!


I am attempting to use PHP+MYSQL+APACHE and I have downloaded all the 
latest verions and installed them on a fresh windows XP install.  Got 
the Apache server up and running, got MySQL up and running and 
installed PHP.  Tested PHP with a script containing phpinfo().  
Everything works great.


Wrote a small script to connect to the MySql database.  Tried to run 
the script (http://localhost/dbscript.php) and I get a 500 Internal 
Server error.  I have been up and down the web for two days looking 
for a solution and I am completely frustrated.  I HAVE to be missing 
something.  PLEASE PLEASE PLEASE help.  Thanks.


MySql is enabled in php.ini.  Paths are set to the php folder.  I have 
NOT moved or copied any files whatsoever.  Apache version is 2.2.


Thanks.



Since you are a windows user and you need to begin coding in PHP etc why 
don't you try WAMP for starters?


http://www.wampserver.com/en/

It gives you all you need in one package.




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] isset question

2009-06-19 Thread Ashley Sheridan
On Fri, 2009-06-19 at 12:36 +0100, Ford, Mike wrote:
 On 18 June 2009 20:25, LAMP advised:
 
  using !empty() instead isset() will work if you don't care for PHP
  Notice: Undefined variable... If you want to avoid PHP Notice
  you have
  to use both:
  
  $msg.=  (isset($_POST['mort']) and !empty($_POST['mort'])) ? The
  mortgage amount is  $mort\n :  ;
 
 Absolute rubbish -- as it says at http://php.net/empty, empty($var) is
 the opposite of (boolean)$var, except that no warning is generated when
 the variable is not set. -- so protecting empty() with an isset() is
 a total waste of time, space and cpu cycles.
 
 Cheers!
 
 Mike
 
  --
 Mike Ford,  Electronic Information Developer,
 C507, Leeds Metropolitan University, Civic Quarter Campus, 
 Woodhouse Lane, LEEDS,  LS1 3HE,  United Kingdom
 Email: m.f...@leedsmet.ac.uk
 Tel: +44 113 812 4730
 
 
 
 
 
 To view the terms under which this email is distributed, please go to 
 http://disclaimer.leedsmet.ac.uk/email.htm
 
To be honest, you're still opening yourself up to attack that way. What
I'd do is first assign the variable to a forced int, and then use that
result if it is 0:

$mortgage = (isset($_REQUEST['mort'])?intval($_REQUEST['mort']):0;

$msg .= ($mortgage  0)?The mortgage amount is $mortgage:;

Thanks
Ash
www.ashleysheridan.co.uk


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] This Friday's OT Thread

2009-06-19 Thread Daniel Brown
Hey, folks;

It's been a while since we've launched a Friday OT thread, so here
ya' go.  Feel free to post nonsense, babble, share links, blow off
some steam, bitch and complain about a colleague, whatever.  Just
remember that you're live to the world and are being archived and
preserved for future generations.  ;-P

To start off, something that's affecting us all, as a world
community, with more frequency.  Safe for work.

http://fart.ly/xos5z9

Here's hoping everyone has a great weekend!

-- 
/Daniel P. Brown
daniel.br...@parasane.net || danbr...@php.net
http://www.parasane.net/ || http://www.pilotpig.net/
50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW1

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Calendar

2009-06-19 Thread Ashley Sheridan
On Fri, 2009-06-19 at 15:30 +0530, Sudheer Satyanarayana wrote:
 salmarayan wrote:
  Does Any body please have the code of A Java Script Calendar that works with
  a PHP Html  Form.. 
  if yes can you please send it as i have one but does not work that
  Efficiently.
 
  Thanks in advance

 This might help if you are looking for a date picker
 
 http://techchorus.net/add-cool-date-picker-2-lines-javascript
 
 
 -- 
 
 With warm regards,
 Sudheer. S
 Business: http://binaryvibes.co.in, Tech stuff: http://techchorus.net, 
 Personal: http://sudheer.net
 
 
I've always used Tigra calendar, and it's been very flexible for me for
a lot of sites. Don't know whether or not it is still maintained, as I
keep using the same source I picked up a couple of years back! If you
have trouble finding it, give me a shout.

Thanks
Ash
www.ashleysheridan.co.uk


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] This Friday's OT Thread

2009-06-19 Thread Jason Pruim

Wow dan, must be nice to have the time to read all that :P

I could rant about how hard it is to find a job when you don't have  
much verifiable experience But instead I put together a website  
which has links to everywhere that I'm watching. So if anyone is in  
central Florida and looking for a job point your shiny rectangle here: HTTP://www.jasonpruim.com/jobsearch


And yes I know the site doesn't validate :P

If anyone knows of other sites/businesses let me know and I'll add them.

Happy Friday to All you crazy employed programmers!


Jason Pruim

On Jun 19, 2009, at 2:42 PM, Daniel Brown danbr...@php.net wrote:


   Hey, folks;

   It's been a while since we've launched a Friday OT thread, so here
ya' go.  Feel free to post nonsense, babble, share links, blow off
some steam, bitch and complain about a colleague, whatever.  Just
remember that you're live to the world and are being archived and
preserved for future generations.  ;-P

   To start off, something that's affecting us all, as a world
community, with more frequency.  Safe for work.

   http://fart.ly/xos5z9

   Here's hoping everyone has a great weekend!

--
/Daniel P. Brown
daniel.br...@parasane.net || danbr...@php.net
http://www.parasane.net/ || http://www.pilotpig.net/
50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW1

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] This Friday's OT Thread

2009-06-19 Thread Robert Cummings

Jason Pruim wrote:

Wow dan, must be nice to have the time to read all that :P

I could rant about how hard it is to find a job when you don't have  
much verifiable experience But instead I put together a website  
which has links to everywhere that I'm watching. So if anyone is in  
central Florida and looking for a job point your shiny rectangle here: HTTP://www.jasonpruim.com/jobsearch


And yes I know the site doesn't validate :P

If anyone knows of other sites/businesses let me know and I'll add them.

Happy Friday to All you crazy employed programmers!


I'm self-employed. I don't plan on ever laying myself off.

Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] This Friday's OT Thread

2009-06-19 Thread Daniel Brown
On Fri, Jun 19, 2009 at 15:05, Robert Cummingsrob...@interjinn.com wrote:

 I'm self-employed. I don't plan on ever laying myself off.

Mind out of the gutter, Rob.  Words like self, laying, and
off will get you flagged.

-- 
/Daniel P. Brown
daniel.br...@parasane.net || danbr...@php.net
http://www.parasane.net/ || http://www.pilotpig.net/
50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW1

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] This Friday's OT Thread

2009-06-19 Thread Bastien Koert
On Fri, Jun 19, 2009 at 3:07 PM, Daniel Browndanbr...@php.net wrote:
 On Fri, Jun 19, 2009 at 15:05, Robert Cummingsrob...@interjinn.com wrote:

 I'm self-employed. I don't plan on ever laying myself off.

    Mind out of the gutter, Rob.  Words like self, laying, and
 off will get you flagged.

 --
 /Daniel P. Brown
 daniel.br...@parasane.net || danbr...@php.net
 http://www.parasane.net/ || http://www.pilotpig.net/
 50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW1

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php



You mean flogged and I think Rob would like that

-- 

Bastien

Cat, the other other white meat

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] This Friday's OT Thread

2009-06-19 Thread Robert Cummings

Daniel Brown wrote:

On Fri, Jun 19, 2009 at 15:05, Robert Cummingsrob...@interjinn.com wrote:

I'm self-employed. I don't plan on ever laying myself off.


Mind out of the gutter, Rob.  Words like self, laying, and
off will get you flagged.


Gutter? It's sounds like your alluding to basic personal maintenance. 
And on that note... I've gotta go shave my palms again.


Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] This Friday's OT Thread

2009-06-19 Thread Daniel Brown
On Fri, Jun 19, 2009 at 15:00, Jason Pruimja...@jasonpruim.com wrote:
 Wow dan, must be nice to have the time to read all that :P

 I could rant about how hard it is to find a job when you don't have much
 verifiable experience But instead I put together a website which has
 links to everywhere that I'm watching. So if anyone is in central Florida
 and looking for a job point your shiny rectangle here:
 HTTP://www.jasonpruim.com/jobsearch

Don't forget the invaluable resource that is CraigsList.  For you,
specifically:

http://orlando.craigslist.org/

There's also Dice (http://www.dice.com/), but that's more for
specifically tech-oriented jobs, and most require a degree in the
field.  Keep your eyes open for technical support positions with
telecommunications carriers --- particularly local or regional phone
companies and ISP's.  It's a relatively-stable job market, and there
are call centers all over the country, some with VOIP setups allowing
one to work from his/her own home.

As for the 911 dispatcher's job, I never did hear from the
Sheriff's office or the County Com-Center about you, so it's an
adequate amount of time just to check in and see if [they] have any
other questions, without being too pushy but don't call 911 to do
it!  ;-P

-- 
/Daniel P. Brown
daniel.br...@parasane.net || danbr...@php.net
http://www.parasane.net/ || http://www.pilotpig.net/
50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW1

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] This Friday's OT Thread

2009-06-19 Thread Jason Pruim



Jason Pruim

On Jun 19, 2009, at 3:14 PM, Daniel Brown danbr...@php.net wrote:

On Fri, Jun 19, 2009 at 15:00, Jason Pruimja...@jasonpruim.com  
wrote:

Wow dan, must be nice to have the time to read all that :P

I could rant about how hard it is to find a job when you don't have  
much
verifiable experience But instead I put together a website  
which has
links to everywhere that I'm watching. So if anyone is in central  
Florida

and looking for a job point your shiny rectangle here:
HTTP://www.jasonpruim.com/jobsearch


   Don't forget the invaluable resource that is CraigsList.  For you,
specifically:

   http://orlando.craigslist.org/

   There's also Dice (http://www.dice.com/), but that's more for
specifically tech-oriented jobs, and most require a degree in the
field.  Keep your eyes open for technical support positions with
telecommunications carriers --- particularly local or regional phone
companies and ISP's.  It's a relatively-stable job market, and there
are call centers all over the country, some with VOIP setups allowing
one to work from his/her own home.

   As for the 911 dispatcher's job, I never did hear from the
Sheriff's office or the County Com-Center about you, so it's an
adequate amount of time just to check in and see if [they] have any
other questions, without being too pushy but don't call 911 to do
it!  ;-P



I just had my interview with them today. They are starting the  
background check right now.


You mean calling 911 isn't a good way to get in touch with them? :P



--
/Daniel P. Brown
daniel.br...@parasane.net || danbr...@php.net
http://www.parasane.net/ || http://www.pilotpig.net/
50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW1

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] This Friday's OT Thread

2009-06-19 Thread Daniel Brown
On Fri, Jun 19, 2009 at 15:22, Jason Pruimja...@jasonpruim.com wrote:

 I just had my interview with them today. They are starting the background
 check right now.

Ahh, fantastic!  Let me know the area code from which they'll be
calling so that, if they do, I'll make it a priority to answer it
rather than letting it go to voicemail.

 You mean calling 911 isn't a good way to get in touch with them? :P

About a dozen years ago, I was considering getting certified as an
emergency services dispatcher, and I remember one of the operators
(with whom I worked on a volunteer first-aid/rescue squad) telling me
a story about how often the centers really do get calls from folks on
911 asking for job applications.  Other requests included directions,
parents drilling their kids (and not informing the operator of this,
but having the police/fire/ambulance crews actually come to the
house), and demands to be driven by emergency vehicles to shopping
centers or other locations (because I pay taxes, that's why!).

Lesson learned: no matter how bad your job sucks on any given day,
not only do I thankfully *have work,* but some poor schmuck is dealing
with worse than I at that very moment!  ;-P

-- 
/Daniel P. Brown
daniel.br...@parasane.net || danbr...@php.net
http://www.parasane.net/ || http://www.pilotpig.net/
50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW1

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] This Friday's OT Thread

2009-06-19 Thread Jay Blanchard
[snip]
...stuff...
[/snip]

NRSFW - but it is just words and a chick flipping you off and some other
really funny stuff (some of it reminds me of our very own PJ);

http://www.27bslash6.com/strata.html



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: accessing level above $_SERVER['DOCUMENT_ROOT']

2009-06-19 Thread LAMP

Peter Ford wrote:

LAMP wrote:
  

hi,

I have this structure:
/home/lamp/mydomain/html
/home/lamp/mydomain/logs
/home/lamp/mydomain/config
etc.

html directory is the only one accessible from outside.

to access config file I can use this:
required_once('/home/lamp/mydomain/config');

but this is the structure on my local/development machine. once the site
is done it will be moved to production server and the structure will be
/srv/www/mydomain/html
/srv/www/mydomain/logs
/srv/www/mydomain/config
etc.

to automate the document_root I define on the begining of the page

define('HTML_PATH', $_SERVER{DOCUMENT_ROOT']);
define('CONFIG_PATH', $_SERVER{DOCUMENT_ROOT'].'/../config');
define('LOGS_PATH', $_SERVER{DOCUMENT_ROOT'].'/../logs');

it works but I think it's not good solution. or at least - it's not nice
solution :-)

suggestions?

afan





Outside of a define, you could have used dirname($_SERVER[DOCUMENT_ROOT]), but
in a define, that's not going to work.
I think you're stuck with your inelegance...
  


actually, it works

define('CONFIG_PATH', dirname($_SERVER{DOCUMENT_ROOT']).'/config');
echo ?: .CONFIG_PATH;   // /home/lamp/mydomain/config

;-)

Thanks.

Afan




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] about locale settings

2009-06-19 Thread Per Jessen
Daniel Brown wrote:

 On Thu, Jun 18, 2009 at 14:52, Per Jessenp...@computer.org wrote:

 Now Dan, I hate to be a pest, but them minutes of yours seem to be
 running a teeny bit slow? :-)
 
 It's the  uhh time difference between Zurich and
 Scranton...?  [*blushes*]
 
 Sorry about that.  Let me finish this one final task and I'll take
 a look at it.  Toss me a message off-list with a way to chat with you
 (Google, MSN, AIM, Skype, whatever) as well, and we can hash it out
 quicker.
 

http://bugs.php.net/bug.php?id=48612


/Per

-- 
Per Jessen, Zürich (13.3°C)


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] about locale settings

2009-06-19 Thread Daniel Brown
On Fri, Jun 19, 2009 at 15:40, Per Jessenp...@computer.org wrote:

 http://bugs.php.net/bug.php?id=48612

See my email to you a moment ago on the impeccability of your
timing, as well.  ;-P

-- 
/Daniel P. Brown
daniel.br...@parasane.net || danbr...@php.net
http://www.parasane.net/ || http://www.pilotpig.net/
50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW1

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PEAR Spreadsheet_Excel_Writer setLocked method

2009-06-19 Thread Skip Evans

Thodoris wrote:
I've used it for some time but never needed to lock a cell. Here is a 
piece of code that shows how to apply a format to a cell:

  Hope it helps. I think that by doing something like this:


$format_bold-setLocked();

while creating the format could do the trick but it is not tested.



No, this didn't do it. I already have some formats I've 
created for dollar amounts, right align, etc, and applying the 
setLocked() method to them had no affect.


Skip

--

Skip Evans
Big Sky Penguin, LLC
503 S Baldwin St, #1
Madison WI 53703
608.250.2720
http://bigskypenguin.com

Those of you who believe in
telekinesis, raise my hand.
 -- Kurt Vonnegut

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] This Friday's OT Thread

2009-06-19 Thread Nitsan Bin-Nun
Collage? you better try highschool ;)

Anyway tomorrow my sis has bat-mitzva ;)

Good night folks!

On Fri, Jun 19, 2009 at 8:42 PM, Daniel Brown danbr...@php.net wrote:

Hey, folks;

It's been a while since we've launched a Friday OT thread, so here
 ya' go.  Feel free to post nonsense, babble, share links, blow off
 some steam, bitch and complain about a colleague, whatever.  Just
 remember that you're live to the world and are being archived and
 preserved for future generations.  ;-P

To start off, something that's affecting us all, as a world
 community, with more frequency.  Safe for work.

http://fart.ly/xos5z9

Here's hoping everyone has a great weekend!

 --
 /Daniel P. Brown
 daniel.br...@parasane.net || danbr...@php.net
 http://www.parasane.net/ || http://www.pilotpig.net/
 50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW1

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] This Friday's OT Thread

2009-06-19 Thread Dotan Cohen
 I'm self-employed. I don't plan on ever laying myself off.


Wow, I really replaced laying with getting in my mental eye and
that sentence made too much sense. Please, don't ever do that to me
again!

-- 
Dotan Cohen

http://what-is-what.com
http://gibberish.co.il

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] This Friday's OT Thread

2009-06-19 Thread Dotan Cohen
 I'm self-employed. I don't plan on ever laying myself off.

    Mind out of the gutter, Rob.  Words like self, laying, and
 off will get you flagged.


How naive I was to think that I might be the only one to make the connection!


-- 
Dotan Cohen

http://what-is-what.com
http://gibberish.co.il

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] This Friday's OT Thread

2009-06-19 Thread Eddie Drapkin
Wait, that's not how everyone else gets ready for a coding marathon?

You guys are doing it wrong!

On Fri, Jun 19, 2009 at 7:03 PM, Dotan Cohendotanco...@gmail.com wrote:
 I'm self-employed. I don't plan on ever laying myself off.

    Mind out of the gutter, Rob.  Words like self, laying, and
 off will get you flagged.


 How naive I was to think that I might be the only one to make the connection!


 --
 Dotan Cohen

 http://what-is-what.com
 http://gibberish.co.il

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] isset question

2009-06-19 Thread Paul M Foster
On Fri, Jun 19, 2009 at 07:52:40PM +0100, Ashley Sheridan wrote:

 On Fri, 2009-06-19 at 12:36 +0100, Ford, Mike wrote:
  On 18 June 2009 20:25, LAMP advised:
 
   using !empty() instead isset() will work if you don't care for PHP
   Notice: Undefined variable... If you want to avoid PHP Notice
   you have
   to use both:
  
   $msg.=  (isset($_POST['mort']) and !empty($_POST['mort'])) ? The
   mortgage amount is  $mort\n :  ;
 
  Absolute rubbish -- as it says at http://php.net/empty, empty($var) is
  the opposite of (boolean)$var, except that no warning is generated when
  the variable is not set. -- so protecting empty() with an isset() is
  a total waste of time, space and cpu cycles.

snip

 
 To be honest, you're still opening yourself up to attack that way. 

Why and how?

Paul

-- 
Paul M. Foster

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php