php-general Digest 4 Jun 2009 13:22:19 -0000 Issue 6158

2009-06-04 Thread php-general-digest-help
php-general Digest 4 Jun 2009 13:22:19 - Issue 6158 Topics (messages 293581 through 293597): Re: Best Encryption Algorithm 293581 by: Luke how to manage permissions for file uploader 293582 by: Lamp Lists 293587 by: Al 293588 by: Phpster Re: Query Regarding

[PHP] Timestamps and strftime

2009-06-04 Thread John Comerford
Hi, I am having a problem trying to use a date that I take from a MySQL database. The field is defined as a timestamp in the database. I extract it using PDO and I am trying to use the value with strftime as follows: foreach ($stmt-fetchall(PDO::FETCH_ASSOC) as $row) { echo

RE: [PHP] Timestamps and strftime

2009-06-04 Thread Mayer, Jonathan
Off the top of my head, would strtotime work? ie strftime(%j,strtotime($row['UpdateDate'])) -Original Message- From: John Comerford [mailto:jo...@optionsystems.com.au] Sent: 04 June 2009 07:10 To: php-general@lists.php.net Subject: [PHP] Timestamps and strftime Hi, I am having a

Re: [PHP] Zebra Striped Table Example

2009-06-04 Thread Ashley Sheridan
On Wed, 2009-06-03 at 21:58 -0700, Raymond Irving wrote: Hi Ashley, Thanks for the feedback. See my comments below: Doesn't work in the majority of browsers out there at the moment. I've tested it in IE7, FF3, Safari3 and Opera9. Which Browsers have you tested it in? For

Re: [PHP] Timestamps and strftime

2009-06-04 Thread John Comerford
Thanks Jonathan, Thats exactly what I needed. I appreciate the help, JC Mayer, Jonathan wrote: Off the top of my head, would strtotime work? ie strftime(%j,strtotime($row['UpdateDate'])) -Original Message- From: John Comerford [mailto:jo...@optionsystems.com.au] Sent: 04 June

[PHP] Re: forms problem

2009-06-04 Thread Al
PJ wrote: The code: ...snip div id=loginbox form name=login method=post action=? echo $_SERVER['PHP_SELF'] ? h2accegrave;s client br /input type=text name=title value=? echo $user; ? size=10 /br / mot de passe br /input type=text name=title value=? echo $passwd;

Re: [PHP] forms problem

2009-06-04 Thread PJ
Andrew Ballard wrote: On Wed, Jun 3, 2009 at 7:13 PM, PJ af.gour...@videotron.ca wrote: Tom Chubb wrote: 2009/6/3 PJ af.gour...@videotron.ca: The code: ...snip div id=loginbox     form name=login method=post action=? echo $_SERVER['PHP_SELF'] ?      Â

Re: [PHP] forms problem

2009-06-04 Thread PJ
Shawn McKenzie wrote: PJ wrote: AngeloZanetti wrote: Shawn McKenzie wrote: PJ wrote: PROBLEM 1 solved: errant divs removed; strange that they were inhibiting entry of data into form field? PROBLEM 2 not resolved: but the form was off the page and clipped in

Re: [PHP] how to manage permissions for file uploader

2009-06-04 Thread Lamp Lists
From: Phpster phps...@gmail.com To: Lamp Lists lamp.li...@yahoo.com Cc: php-general@lists.php.net php-general@lists.php.net Sent: Wednesday, June 3, 2009 8:30:05 PM Subject: Re: [PHP] how to manage permissions for file uploader This is fairly simple to do as

Re: [PHP] Not a regular file?

2009-06-04 Thread haliphax
On Thu, Jun 4, 2009 at 9:07 AM, Miller, Terion tmil...@springfi.gannett.com wrote: I've never encountered this error: Warning: ftp_put() [function.ftp-put]: /httpdocs/Announcements/photos/obitsTest/: Not a regular file in /Applications/MAMP/htdocs/HarrisAutomate/ObitsTester.php on line 149

RE: [PHP] Not a regular file?

2009-06-04 Thread kyle.smith
Wrap some debug code in the loop: echo I want to upload $file. Is it a file? . is_file($file) . br/; See what that says. -Original Message- From: haliphax [mailto:halip...@gmail.com] Sent: Thursday, June 04, 2009 10:23 AM To: php-general@lists.php.net Subject: Re: [PHP] Not a regular

Re: [PHP] Not a regular file?

2009-06-04 Thread Miller, Terion
Here is my code for the ftp_put $conn_id = ftp_connect($ftp_server);$login_result = ftp_login($conn_id, $ftp_user_name, $ftp_user_pass);$FilePath = http://localhost:/HarrisAutomate/output/WebImagesHiRes/$ImageName;; $remote_path =

RE: [PHP] Not a regular file?

2009-06-04 Thread kyle.smith
Likewise, do some debug output. echo I'm going to upload $FilePath to $remote_path.; Make sure it looks sane, maybe your variables aren't what you think they are... You can also use is_file() on http:// locations, AFAIK. -Original Message- From: Miller, Terion

Re: [PHP] how to manage permissions for file uploader

2009-06-04 Thread hessiess
But, if I move the directory a level up, not accessable from outside - how can read the image since it's not accessable fro outside? I can't inlcude() the image? You need to do something simmaler to reading files stored in a database, which is described here:

Re: [PHP] Not a regular file?

2009-06-04 Thread Jo�o C�ndido de Souza Neto
I´m not sure, nut I think you cant put a file into a ftp server using http, you must use the $_SERVER[DOCUMENT_ROOT] to get the file you want to put. -- João Cândido de Souza Neto SIENS SOLUÇÕES EM GESTÃO DE NEGÓCIOS Fone: (0XX41) 3033-3636 - JS www.siens.com.br Miller, Terion

Re: [PHP] Re: forms problem

2009-06-04 Thread Michael A. Peters
Al wrote: I also use the HTML Validator extension. Leave it active and as you develop and test your resultant html code, it'll check your pages on the fly. When you see the red circle, with a cross, click the circle and get an error report in detail. Hey wow - that's nifty. I've got

Re: [PHP] Not a regular file? (RESOLVED)

2009-06-04 Thread Miller, Terion
Issue is resolved, all I needed to do was put $ImageName on the remote path too duhlol $remote_path = /httpdocs/Announcements/photos/obitsTest/$ImageName; On 6/4/09 9:35 AM, kyle.smith kyle.sm...@inforonics.com wrote: echo I'm going to upload $FilePath to $remote_path.; -- PHP

Re: [PHP] Re: forms problem

2009-06-04 Thread Al
Michael A. Peters wrote: Al wrote: I also use the HTML Validator extension. Leave it active and as you develop and test your resultant html code, it'll check your pages on the fly. When you see the red circle, with a cross, click the circle and get an error report in detail. Hey wow

Re: [PHP] Re: forms problem

2009-06-04 Thread Michael A. Peters
Al wrote: Michael A. Peters wrote: Al wrote: I also use the HTML Validator extension. Leave it active and as you develop and test your resultant html code, it'll check your pages on the fly. When you see the red circle, with a cross, click the circle and get an error report in detail.

Re: [PHP] html and password management

2009-06-04 Thread Andrew Ballard
On Tue, May 26, 2009 at 4:36 PM, Michael A. Peters mpet...@mac.com wrote: kranthi wrote: seems more of a firefox question than a PHP question... just replace form id=formemail method=post action=UserPrefs with form id=formemail method=post action=UserPrefs autocomplete=off

Re: [PHP] html and password management

2009-06-04 Thread Michael A. Peters
Andrew Ballard wrote: On Tue, May 26, 2009 at 4:36 PM, Michael A. Peters mpet...@mac.com wrote: kranthi wrote: seems more of a firefox question than a PHP question... just replace form id=formemail method=post action=UserPrefs with form id=formemail method=post action=UserPrefs

[PHP] URL injection

2009-06-04 Thread Morris
Hi Can anyone help me handel this URL injection ? https://www.xxx.co.uk/register.php;| grep 123 I want to detect it and header back to my index page. It's quite urgent Thanks for help M.

Re: [PHP] html and password management

2009-06-04 Thread Michael A. Peters
Andrew Ballard wrote: I just thought I'd toss this out there. Do you know that there is an effort to remove browser support this attribute (or at least give the user a browser configuration option to ignore it)? http://article.gmane.org/gmane.org.w3c.whatwg.discuss/3054 This article

Re: [PHP] html and password management

2009-06-04 Thread Andrew Ballard
On Thu, Jun 4, 2009 at 12:33 PM, Michael A. Peters mpet...@mac.com wrote: Andrew Ballard wrote: I just thought I'd toss this out there. Do you know that there is an effort to remove browser support this attribute (or at least give the user a browser configuration option to ignore it)?

[PHP] formatting - design question

2009-06-04 Thread PJ
This may not be strictly php but I think is may be relevant. Were I to use a different css file for every page (that is slightly different), would that affect performance? It seems to me that might be a way of simplifying and certainly speeding up development (design-wise, anyway) when using css.

RE: [PHP] html and password management

2009-06-04 Thread Bob McConnell
From: Andrew Ballard On Thu, Jun 4, 2009 at 12:33 PM, Michael A. Peters mpet...@mac.com wrote: Andrew Ballard wrote: I just thought I'd toss this out there. Do you know that there is an effort to remove browser support this attribute (or at least give the user a browser configuration

Re: [PHP] URL injection

2009-06-04 Thread Stuart
2009/6/4 Morris morris...@gmail.com: Hi Can anyone help me handel this URL injection ? https://www.xxx.co.uk/register.php;| grep 123 I want to detect it and header back to my index page. It's quite urgent What the smeg is register.php doing that makes it execute that?? Show us the code.

Re: [PHP] formatting - design question

2009-06-04 Thread Andrew Ballard
On Thu, Jun 4, 2009 at 12:54 PM, PJ af.gour...@videotron.ca wrote: This may not be strictly php but I think is may be relevant. Were I to use a different css file for every page (that is slightly different), would that affect performance? It seems to me that might be a way of simplifying and

Re: [PHP] html and password management

2009-06-04 Thread Michael A. Peters
Bob McConnell wrote: From my viewpoint, the bigger need is to educate administrators of publicly available computers to disable autocomplete in the browser configuration. If they would do that, when you go to the workstation in the library, you can't see the credentials of the last user, and

Re: [PHP] formatting - design question

2009-06-04 Thread Shawn McKenzie
Andrew Ballard wrote: On Thu, Jun 4, 2009 at 12:54 PM, PJ af.gour...@videotron.ca wrote: This may not be strictly php but I think is may be relevant. Were I to use a different css file for every page (that is slightly different), would that affect performance? It seems to me that might be a

Re: [PHP] formatting - design question

2009-06-04 Thread Nitsan Bin-Nun
From my experience I tend to use a difference ID for the body tag, for instance body id='homepage' and then format it in my CSS using ID reference: #homepage .classname { color: blue; } This way you can use a default format for all the pages and create minor (or major) changes in the theme

Re: [PHP] formatting - design question

2009-06-04 Thread PJ
Nitsan Bin-Nun wrote: From my experience I tend to use a difference ID for the body tag, for instance body id='homepage' and then format it in my CSS using ID reference: #homepage .classname { color: blue; } This way you can use a default format for all the pages and create minor (or

Re: [PHP] Zebra Striped Table Example

2009-06-04 Thread tedd
At 8:10 AM -0700 6/1/09, Raymond Irving wrote: Hello, There are many different ways and techniques that we can use to add alternate colors to table rows. Here's another solution that's very simple and straight forward. For example: $page['table tr:even']-css('background:#eee'); Check

[PHP] webpage has expired remedies

2009-06-04 Thread Ed Bukhman
Hello, Could someone suggest the steps needed to troubleshoot the webpage has expired issue in IE. I have a self-posting php form which queries and writes to a pgsql database. Occasionally, when an input is entered, the form never loads and I get this error instead. I do want to make clear

Re: [PHP] formatting - design question

2009-06-04 Thread tedd
At 2:08 PM -0400 6/4/09, PJ wrote: Nitsan Bin-Nun wrote: From my experience I tend to use a difference ID for the body tag, for instance body id='homepage' and then format it in my CSS using ID reference: #homepage .classname { color: blue; } This way you can use a default format

Re: [PHP] URL injection

2009-06-04 Thread Morris
Hi The register.php has only a form ?php form name=registerUser action=register.php method=post input type=text name=username size=10 / input type=submit value=send / /form ? Does this help ? Thanks for reply 2009/6/4 Stuart stut...@gmail.com 2009/6/4 Morris morris...@gmail.com: Hi

Re: [PHP] URL injection

2009-06-04 Thread Stuart
2009/6/4 Morris morris...@gmail.com: Hi The register.php has only a form ?php form name=registerUser action=register.php method=post input type=text name=username size=10 / input type=submit value=send / /form ? Does this help ? 1) That is not valid PHP code. 2) Even if it were

Re: [PHP] URL injection

2009-06-04 Thread Matty Sarro
Is there more to the register.php file that we're not seeing? It has to have some sort of action... On Thu, Jun 4, 2009 at 3:28 PM, Stuart stut...@gmail.com wrote: 2009/6/4 Morris morris...@gmail.com: Hi The register.php has only a form ?php form name=registerUser

[PHP] PHP Graphing Libraries...?

2009-06-04 Thread li...@mgreg.com
Hi All, I'm currently looking for a quality (preferably open source) PHP graphing library that will allow me to create various graphs and plot points. I've seen several that do some amazing things, but cost a fortune -- others are either limited, lack documentation, or don't allow

Re: [PHP] formatting - design question

2009-06-04 Thread tedd
At 3:58 PM -0400 6/4/09, PJ wrote: tedd wrote: Style sheets are meant simplify things so decide on how you want things to look uniformly throughout your site and then stick with it. There's really no good reason to keep changing things throughout a site. Cheers, tedd Maybe I'm just

Re: [PHP] PHP Graphing Libraries...?

2009-06-04 Thread Gary Smith
li...@mgreg.com wrote: Hi All, I'm currently looking for a quality (preferably open source) PHP graphing library that will allow me to create various graphs and plot points. I've seen several that do some amazing things, but cost a fortune -- others are either limited, lack documentation,

[PHP] https setup

2009-06-04 Thread PJ
Can't find anything on G or web - but I probably didn't try hard enough. I am unable to set my virtual hosts to handle https. I have apache22, mod_ssl, opnenssl and the httpd and httpd-vhosts.conf files are set up correctly but directing a sensitive user information page to an HTTPS page returns

[PHP] Listening on host:port - Windows

2009-06-04 Thread John Fairley
I'm running my test server on Windows XP SP3 and have been successfully running PHP 5 for some time using: php-cgi.exe -b 127.0.0.1:1 My live server is running on PHP 4.4 and that gives an incompatibility risk in problem solving. So I've removed PHP 5 on my test server and have

Re: [PHP] PHP Graphing Libraries...?

2009-06-04 Thread li...@mgreg.com
On Jun 4, 2009, at 4:35 PM, Gary Smith wrote: JpGraph? Gary Thanks Gary. I've actually been looking at both JpGraph (http://www.aditus.nu/jpgraph/ ) and XML/SWF Charts (http://www.maani.us/xml_charts/index.php). However, JpGraphs is one of those that suffers from horrendous

[PHP] Re: PHP Graphing Libraries...?

2009-06-04 Thread pan
li...@mgreg.com wrote in message news:4fcc2030-9483-49d9-962c-1849a0987...@mgreg.com... | Hi All, | | I'm currently looking for a quality (preferably open source) PHP | graphing library that will allow me to create various graphs and plot | points. I've seen several that do some amazing things,

Re: [PHP] webpage has expired remedies

2009-06-04 Thread Eric Butera
On Thu, Jun 4, 2009 at 2:14 PM, Ed Bukhman eb...@yahoo.com wrote: Hello, Could someone suggest the steps needed to troubleshoot the webpage has expired issue in IE. I have a self-posting php form which queries and writes to a pgsql database. Occasionally, when an input is entered, the form

Re: [PHP] webpage has expired remedies

2009-06-04 Thread Ed Bukhman
Thank you, but this would involve the target (get) page having a bunch of stuff in the URL, no? I would like to avoid this if possible, not least because it would allow people to go directly to the get page the next time, and this would be problematic for my application. Is there a different

Re: [PHP] Zebra Striped Table Example

2009-06-04 Thread Raymond Irving
I've just tested it in FireFox 2.0.0.20 and IE6 and it works just fine. I can toggle the stipes by clicking on the Toggle Stripes hyperlink. See the attached snapshots PS. I think I'll just update the example to show the zebra stripes by default as that might be the reason why it appears to

Re: [PHP] PHP Graphing Libraries...?

2009-06-04 Thread Paul M Foster
On Thu, Jun 04, 2009 at 01:50:28PM -0700, Michael A. Peters wrote: li...@mgreg.com wrote: Hi All, I'm currently looking for a quality (preferably open source) PHP graphing library that will allow me to create various graphs and plot points. I've seen several that do some amazing things,

Re: [PHP] PHP Graphing Libraries...?

2009-06-04 Thread Michael A. Peters
Paul M Foster wrote: On Thu, Jun 04, 2009 at 01:50:28PM -0700, Michael A. Peters wrote: li...@mgreg.com wrote: Hi All, I'm currently looking for a quality (preferably open source) PHP graphing library that will allow me to create various graphs and plot points. I've seen several that do