Re: [PHP] retrieve POST body?

2007-04-24 Thread Justin Frim
Myron Turner wrote: I'm not sure I follow here, because the Perl script would be saving the posted file to disk. It would then send back a redirect with the name of the file in the query string of the url, which would point to a php script that would then read the file from the disk. So the

RE: [PHP] Find MAC Address in PHP

2007-04-24 Thread Daevid Vincent
This may help you (find .tgz file at the page bottom): http://daevid.com/examples/dhcp/ This is a little web tool I use to see who is on my LAN D.Vin -Original Message- From: Nathaniel Hall [mailto:[EMAIL PROTECTED] Sent: Friday, April 20, 2007 1:00 PM To:

RE: [PHP] Standard Address Book?

2007-04-24 Thread Daevid Vincent
You might look into vCards -- most mail clients load/import them. http://en.wikipedia.org/wiki/VCard -Original Message- From: Jim Lucas [mailto:[EMAIL PROTECTED] Sent: Monday, April 23, 2007 8:48 AM To: [EMAIL PROTECTED] Cc: php-general@lists.php.net Subject: Re: [PHP] Standard

Re: [PHP] filetype() and exec() issues

2007-04-24 Thread Tijnema !
On 4/24/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: This question is a two parter a) anyone else noticing filetype() failing on ISO image files? Warning: filetype(): Lstat failed for /var/lib/samba/some/file.iso Nope, didn't fail for me. But what exactly do you want to know about the

Re: [PHP] What determines the relative directory, and can I control it?

2007-04-24 Thread Tijnema !
On 4/24/07, Dave M G [EMAIL PROTECTED] wrote: PHP Users, I am developing a content management system, and one of the goals is to separate out the design entirely from the PHP scripting and content. All the PHP scripts which contain the logic that drives the site are all in the web site's root

RE: [PHP] What determines the relative directory, and can I control it?

2007-04-24 Thread Buesching, Logan J
[snip] Can I somehow manipulate any of the PHP scripts involved so that the HTML within layout.php will look first in it's own directory for inclusion of files, such as CSS and javascript and anything else? [/snip] If a user accesses http://site.com/index.php, then the HTML that is spit back

RE: [PHP] filetype() and exec() issues

2007-04-24 Thread Buesching, Logan J
You may also want to check and make sure that your ISO isn't more than 4GB. IIRC, I had some troubles with extremely large files and using filetype() on them. But then again, it may have just been something on my own end. -Logan -Original Message- From: Tijnema ! [mailto:[EMAIL

Re: [PHP] help needed to write an installation script for my php application

2007-04-24 Thread Tijnema !
On 4/23/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Hi There, Could you please help me to write an installation script to install a php based application in Windows. 1. I have WAMP5.0 running my my IBM T43 laptop. 2. I have created a php application. 3. I would like to know how to create

Re: [PHP] What determines the relative directory, and can I control it?

2007-04-24 Thread Sancar Saran
Greetings. On Tuesday 24 April 2007 09:22, Tijnema ! wrote: Right now, if the designer of the site wants to make a call to an external CSS style sheet within layout.php, the designer has to write in the whole path, relative to the index.php file. For example: style type=text/css @import

[PHP] Re: advice for blob tables?

2007-04-24 Thread Kevin Waterson
This one time, at band camp, [EMAIL PROTECTED] wrote: I've been using this one: http://www.dreamwerx.net/phpforum/?id=1 I developed it in 2001 and it's had implementations into the hundreds of gb's so far. I have a ftp interface to it that runs at wire speed (100FDX). I initially did

[PHP] performance down

2007-04-24 Thread [EMAIL PROTECTED]
Hello everyone, recently we tested upgrading our systems from: apache 2.0.55 php 5.1.6 eacclerator 0.9.5 to: apache 2.2.3 php 5.2.0 eaccelerator 0.9.5 but we always get worse performance than before. So maybe it is the newer apache version which

Re: [PHP] performance down

2007-04-24 Thread Tijnema !
On 4/24/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Hello everyone, recently we tested upgrading our systems from: apache 2.0.55 php 5.1.6 eacclerator 0.9.5 to: apache 2.2.3 php 5.2.0 eaccelerator 0.9.5 but we always get worse performance than

[PHP] voucher manipulation

2007-04-24 Thread Steven Macintyre
Alo, I have a client looking to do the following; There is a standard voucher design, in the format of JPG ... now ... they wish to create a voucher system where if you reach so many points etc you can claim a voucher (using the design) with a expiry date ... current + 30days and a unique

Re: [PHP] voucher manipulation

2007-04-24 Thread Tijnema !
On 4/24/07, Steven Macintyre [EMAIL PROTECTED] wrote: Alo, I have a client looking to do the following; There is a standard voucher design, in the format of JPG ... now ... they wish to create a voucher system where if you reach so many points etc you can claim a voucher (using the design)

RE: [PHP] voucher manipulation

2007-04-24 Thread Jim Moseby
Alo, I have a client looking to do the following; There is a standard voucher design, in the format of JPG ... now ... they wish to create a voucher system where if you reach so many points etc you can claim a voucher (using the design) with a expiry date ... current + 30days and

Re: [PHP] Problems installing php with pdflib

2007-04-24 Thread Tijnema !
On 4/17/07, Richard Lynch [EMAIL PROTECTED] wrote: On Sat, April 14, 2007 3:55 am, Merlin wrote: I am moving to a new box and want to install php with pdflib again. After configure I get an error saying: pdflib.h not found! Check the path passed to --with-pdflib The path is just fine:

Re: [PHP] performance down

2007-04-24 Thread Jochem Maas
Tijnema ! wrote: On 4/24/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Hello everyone, recently we tested upgrading our systems from: apache 2.0.55 php 5.1.6 eacclerator 0.9.5 to: apache 2.2.3 php 5.2.0 eaccelerator 0.9.5 but we always get

Re: [PHP] Find MAC Address in PHP

2007-04-24 Thread Tijnema !
On 4/23/07, Davi [EMAIL PROTECTED] wrote: Em Domingo 22 Abril 2007 03:12, Richard Lynch escreveu: On Fri, April 20, 2007 3:00 pm, Nathaniel Hall wrote: ?php $MAC = system(arp 192.168.200.254); echo $MAC; ? does not give me any output. I have copied arp to a place that the apache user can

Re: [PHP] posting variables to parent frame

2007-04-24 Thread Tijnema !
On 4/17/07, Hans [EMAIL PROTECTED] wrote: Hi there, I'm trying to post variables to a parent frame, I'm working from a page that is in an iFrame. However, I don't know how to accomplish this. I tried target='top' to include in the form tag (form action=?=$formurl? target=top) but this

Re: [PHP] Find MAC Address in PHP

2007-04-24 Thread Davi
Em Terça 24 Abril 2007 10:07, Tijnema ! escreveu: On 4/23/07, Davi [EMAIL PROTECTED] wrote: Em Domingo 22 Abril 2007 03:12, Richard Lynch escreveu: On Fri, April 20, 2007 3:00 pm, Nathaniel Hall wrote: ?php $MAC = system(arp 192.168.200.254); echo $MAC; ? does not give me any

[PHP] Shell used by system()

2007-04-24 Thread Marco Michelino
Hi *, is it possible to change the shell used by system() , exec() and similar PHP funtions? I'm running mod_php in apache on Linux. Apache shell is set to /sbin/nologin but PHP insists to call /bin/sh... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

[PHP] Re: posting variables to parent frame

2007-04-24 Thread Al
iFrames are obsolete and only IE handles them. I don't even know if IE7 does. Use css div tags instead. Hans wrote: Hi there, I'm trying to post variables to a parent frame, I'm working from a page that is in an iFrame. However, I don't know how to accomplish this. I tried target='top' to

[PHP] Re: performance down

2007-04-24 Thread Colin Guthrie
Jochem Maas wrote: sorry OP I can't comment on the degradation your seeing, but I'm interested if anyone can - in the mean time you might consider downgrading apache and measuring the difference and subsequently upgrading apache whilst downgrading php and measuring the difference also - it

Re: [PHP] Find MAC Address in PHP

2007-04-24 Thread Tijnema !
On 4/24/07, Davi [EMAIL PROTECTED] wrote: Em Terça 24 Abril 2007 10:07, Tijnema ! escreveu: On 4/23/07, Davi [EMAIL PROTECTED] wrote: Em Domingo 22 Abril 2007 03:12, Richard Lynch escreveu: On Fri, April 20, 2007 3:00 pm, Nathaniel Hall wrote: ?php $MAC = system(arp 192.168.200.254);

Re: [PHP] Shell used by system()

2007-04-24 Thread Tijnema !
On 4/24/07, Marco Michelino [EMAIL PROTECTED] wrote: Hi *, is it possible to change the shell used by system() , exec() and similar PHP funtions? I'm running mod_php in apache on Linux. Apache shell is set to /sbin/nologin but PHP insists to call /bin/sh... First, I guess this isn't the

Re: [PHP] Find MAC Address in PHP

2007-04-24 Thread Davi
Em Terça 24 Abril 2007 10:49, Tijnema ! escreveu: On 4/24/07, Davi [EMAIL PROTECTED] wrote: How you'll type your root pwd? =P Something with the proc_* functions as you need bi-directional streams (input/output). Something like this: (not tested, partly copied form example 1926) ?php

[PHP] transparent gifs with matte?

2007-04-24 Thread Ross
Hi, I am looking to create a transparent text gif that allows me to set a colour for the matte. I have it working as a PNG but this is no good in IE. Does anyone have an exampe of this? This is my code so far. ?php header(Content-type: image/gif); $im = imagecreate (800, 30); $black =

Re: [PHP] Find MAC Address in PHP

2007-04-24 Thread chris smith
On 4/24/07, Tijnema ! [EMAIL PROTECTED] wrote: On 4/24/07, Davi [EMAIL PROTECTED] wrote: Em Terça 24 Abril 2007 10:07, Tijnema ! escreveu: On 4/23/07, Davi [EMAIL PROTECTED] wrote: Em Domingo 22 Abril 2007 03:12, Richard Lynch escreveu: On Fri, April 20, 2007 3:00 pm, Nathaniel Hall

[PHP] Re: Re: Suggestions for Web based FileServer/Mailaccess

2007-04-24 Thread Michelle Konzack
Am 2007-04-19 16:55:10, schrieb Richard Lynch: Where do the Files come from in the first place? Attachments? External source? External. If they were attachments, maybe you'd be better off just leaving them in the Maildir... Right! I suppose you could build a parallel File System to your

[PHP] Re: Re: auto page generation

2007-04-24 Thread Michelle Konzack
Am 2007-04-20 10:26:29, schrieb Chris: Michelle Konzack wrote: Do you know an equivalent book for php5 and PostgreSQL 8.1/8.2? Beginning PHP and PostgreSQL 8: From Novice to Professional (Paperback) might have something you need. (I would send an amazon link but it's about 200

[PHP] Re: Re: auto page generation

2007-04-24 Thread Michelle Konzack
Am 2007-04-20 08:51:43, schrieb Roman Neuhauser: # [EMAIL PROTECTED] / 2007-04-20 10:26:29 +1000: Michelle Konzack wrote: Do you know an equivalent book for php5 and PostgreSQL 8.1/8.2? Beginning PHP and PostgreSQL 8: From Novice to Professional (Paperback) might have something you need.

[PHP] secure alternative to HTTP_REFERER

2007-04-24 Thread AraDaen
Im looking for info about a secure alternative to the use of $_server['http_refere'] to check in a script from where are arriving $_post vars. any suggestion? Thans a lot. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: posting variables to parent frame

2007-04-24 Thread Stut
Al wrote: iFrames are obsolete and only IE handles them. I don't even know if IE7 does. Well that's just a complete load of rubbish. The iframe tag is not obsolete, and I don't know where you got the idea that they are. Several legitimate uses for iframes exist, and they're unlikely to go

Re: [PHP] Find MAC Address in PHP

2007-04-24 Thread Nathaniel Hall
Richard Lynch wrote: On Fri, April 20, 2007 3:00 pm, Nathaniel Hall wrote: I am attempting to find the MAC address of systems visiting my page from the local LAN. I have tried several things, but it appears it will not let me run system commands. For example, running ?php $MAC = system(arp

[PHP] Re: PHP Text Messaging

2007-04-24 Thread Michelle Konzack
Am 2007-04-19 09:27:56, schrieb Philip Thompson: Hi. I have attempted to look at the archives for this, but keep getting redirected back to the main PHP site when I click on the archive link. With that said, does anyone know of any good resources for sending text messages using PHP? I

[PHP] Re: PHP Text Messaging

2007-04-24 Thread Michelle Konzack
Am 2007-04-20 17:58:20, schrieb Stut: Daniel Brown wrote: The option that you're discussing is what I've been using for the last several years. All of the ones you sent look correct, from memory, but I'd have to check my scripts to see for sure. When I'm sending a message, I just send it

[PHP] Re: PHP Text Messaging

2007-04-24 Thread Michelle Konzack
Am 2007-04-20 13:05:16, schrieb Daniel Brown: I don't really like to, because I run the risk of getting my IP or even netblock blacklisted, but I can't think of any other way to do it if the user doesn't know what carrier the number belongs to. Any ideas on this subject, I'm absolutely

[PHP] Re: PHP Text Messaging

2007-04-24 Thread Michelle Konzack
Am 2007-04-20 12:36:47, schrieb Edward Vermillion: How does Yahoo do it? You can send text messages through YMessenger and all you need is the number. You can probably do that with others but that's the only one I've ever used. Sending SMS international is expensive... e.g.: France -

Re: [PHP] secure alternative to HTTP_REFERER

2007-04-24 Thread Stut
AraDaen wrote: Im looking for info about a secure alternative to the use of $_server['http_refere'] to check in a script from where are arriving $_post vars. You could put a hash value into a hidden field on the form, and also store it in the session. When the form is submitted only accept

Re: [PHP] secure alternative to HTTP_REFERER

2007-04-24 Thread Chris Shiflett
Stut wrote: You could put a hash value into a hidden field on the form, and also store it in the session. When the form is submitted only accept it if the hashes match. However, this is very easy to get around, so I suggest you consider why you think you need this level of checking.

Re: [PHP] Re: posting variables to parent frame

2007-04-24 Thread Al
Provide an example of an iFrame that will work on all modern browsers and that can't be done with DIVs or OBJECTS Stut wrote: Al wrote: iFrames are obsolete and only IE handles them. I don't even know if IE7 does. Well that's just a complete load of rubbish. The iframe tag is not

Re: [PHP] Find MAC Address in PHP

2007-04-24 Thread Nathaniel Hall
Davi wrote: Em Domingo 22 Abril 2007 03:12, Richard Lynch escreveu: On Fri, April 20, 2007 3:00 pm, Nathaniel Hall wrote: ?php $MAC = system(arp 192.168.200.254); echo $MAC; ? does not give me any output. I have copied arp to a place that the apache user can execute from and ensured

Re: [PHP] Re: posting variables to parent frame

2007-04-24 Thread Stut
Al wrote: Provide an example of an iFrame that will work on all modern browsers and that can't be done with DIVs or OBJECTS I didn't say it couldn't be done, I said it was different. Take Google Ads for example. These are currently served in an iframe. To do it in a div is possible but leads

Re: [PHP] Re: posting variables to parent frame

2007-04-24 Thread Robert Cummings
On Tue, 2007-04-24 at 11:12 -0400, Al wrote: Provide an example of an iFrame that will work on all modern browsers and that can't be done with DIVs or OBJECTS That doesn't imply obsoletion, rather it implies lack of implementation or improper implementation. Cheers, Rob. --

Re: [PHP] Re: posting variables to parent frame

2007-04-24 Thread Zoltán Németh
check out FCKeditor for example. http://www.fckeditor.net/demo I included it in various CMS systems and I find it a great tool. And it uses iframe greets Zoltán Németh 2007. 04. 24, kedd keltezéssel 11.12-kor Al ezt írta: Provide an example of an iFrame that will work on all modern browsers

Re: [PHP] Re: posting variables to parent frame

2007-04-24 Thread Stut
FYI: Every time I reply to you I get a bounce back saying your email address ([EMAIL PROTECTED]) does not exist. It's starting to get annoying. -Stut Stut wrote: Al wrote: Provide an example of an iFrame that will work on all modern browsers and that can't be done with DIVs or OBJECTS I

Re: [PHP] Re: posting variables to parent frame

2007-04-24 Thread Zoltán Németh
2007. 04. 24, kedd keltezéssel 16.25-kor Stut ezt írta: FYI: Every time I reply to you I get a bounce back saying your email address ([EMAIL PROTECTED]) does not exist. It's starting to get annoying. Al, that also happens for me. I just didn't mention it yet, because I thought if it happens

Re: [PHP] Find MAC Address in PHP

2007-04-24 Thread Puskás Zsolt ( Errotan )
Hi. Sorry for my bad english. :( Maybe you could write a simple deamon program in C or even in PHP to be run as root. The function of this deamon program is to listen to a port (eg. 1) and you could fsockopen it and send the IP address of the client computer and the deamon returns the MAC

[PHP] Re: advice for blob tables?

2007-04-24 Thread colbey
Ok.. you need to re-read the article, this is not a 1:1, if I store a file such as a 700MB ISO image in that format it results in: - 1 row in metadata table - approximately 11,200 rows in the data table (700MB / 64k) That's far from 1:1. Sure there's issues with with NFS - security number 1 -

[PHP] List

2007-04-24 Thread Beauford
Does anyone else have this problem with the list. It seems that every time I check my email there is one or more messages from the list that royally screws up Outlook. I usually have to delete all list messages from the actual server and reboot. It only happens with emails from [EMAIL PROTECTED]

RE: [PHP] make a gif

2007-04-24 Thread WeberSites LTD
Try searching for image gd text at http://www.php-code-search.com/ There are lots of examples -Original Message- From: John Taylor-Johnston [mailto:[EMAIL PROTECTED] Sent: Monday, April 23, 2007 7:02 PM To: PHP-General Subject: [PHP] make a gif I want to print [EMAIL PROTECTED] into a

Re: [PHP] List

2007-04-24 Thread Jim Lucas
Beauford wrote: Does anyone else have this problem with the list. It seems that every time I check my email there is one or more messages from the list that royally screws up Outlook. I usually have to delete all list messages from the actual server and reboot. It only happens with emails from

[PHP] Re: List

2007-04-24 Thread Colin Guthrie
Beauford wrote: Does anyone else have this problem with the list. It seems that every time I check my email there is one or more messages from the list that royally screws up Outlook. I usually have to delete all list messages from the actual server and reboot. It only happens with emails from

Re: [PHP] List

2007-04-24 Thread Tijnema !
On 4/24/07, Beauford [EMAIL PROTECTED] wrote: Does anyone else have this problem with the list. It seems that every time I check my email there is one or more messages from the list that royally screws up Outlook. I usually have to delete all list messages from the actual server and reboot. It

Re: [PHP] secure alternative to HTTP_REFERER

2007-04-24 Thread AraDaen
Thanks guys now i know what must i do :) Chris Shiflett escribió: Stut wrote: You could put a hash value into a hidden field on the form, and also store it in the session. When the form is submitted only accept it if the hashes match. However, this is very easy to get around, so I

[PHP] Re: transparent gifs with matte?

2007-04-24 Thread zerof
Ross escreveu: Hi, I am looking to create a transparent text gif that allows me to set a colour for the matte. I have it working as a PNG but this is no good in IE. Does anyone have an exampe of this? This is my code so far. ?php header(Content-type: image/gif); $im = imagecreate (800,

Re: [PHP] transparent gifs with matte?

2007-04-24 Thread tedd
At 3:08 PM +0100 4/24/07, Ross wrote: Hi, I am looking to create a transparent text gif that allows me to set a colour for the matte. I have it working as a PNG but this is no good in IE. Look to javascript for a solution to the PNG/IE problem. Cheers, tedd -- --- http://sperling.com

Re: [PHP] Re: posting variables to parent frame

2007-04-24 Thread Justin Frim
I'll jump in on this one, because I've dealt with the div/object/iframe frustration before. And I would not be very happy if the W3C decided to deprecate iFrames right now, at least with the current state of the world's browsers. I found that with object I didn't have very much control over

Re: [PHP] List

2007-04-24 Thread Wolf
Welcome to Windows Tijnema ! wrote: On 4/24/07, Beauford [EMAIL PROTECTED] wrote: Does anyone else have this problem with the list. It seems that every time I check my email there is one or more messages from the list that royally screws up Outlook. I usually have to delete all list messages

Re: [PHP] List

2007-04-24 Thread Zoltán Németh
2007. 04. 24, kedd keltezéssel 11.11-kor Jim Lucas ezt írta: Beauford wrote: Does anyone else have this problem with the list. It seems that every time I check my email there is one or more messages from the list that royally screws up Outlook. I usually have to delete all list messages

Re: [PHP] Find MAC Address in PHP

2007-04-24 Thread Lori Lay
Nathaniel Hall wrote: Davi wrote: I know it can be done because I have a Fedora Core 4 system doing it right now. I didn't have to do anything special for it to work. The system I am working on now is a Fedora Core 6 box. In /var/log/messages I receive: Apr 24 09:33:51 STUAUTH kernel:

Re: [PHP] List

2007-04-24 Thread Jim Lucas
Beauford wrote: Does anyone else have this problem with the list. It seems that every time I check my email there is one or more messages from the list that royally screws up Outlook. I usually have to delete all list messages from the actual server and reboot. It only happens with emails from

RE: [PHP] List

2007-04-24 Thread Buesching, Logan J
I use Outlook 2003 on Vista, no problem at all, non-digest mode. -Original Message- From: Wolf [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 24, 2007 3:18 PM To: Tijnema ! Cc: Beauford; PHP Subject: Re: [PHP] List Welcome to Windows Tijnema ! wrote: On 4/24/07, Beauford [EMAIL

Re: [PHP] Find MAC Address in PHP

2007-04-24 Thread Tijnema !
On 4/24/07, chris smith [EMAIL PROTECTED] wrote: On 4/24/07, Tijnema ! [EMAIL PROTECTED] wrote: On 4/24/07, Davi [EMAIL PROTECTED] wrote: Em Terça 24 Abril 2007 10:07, Tijnema ! escreveu: On 4/23/07, Davi [EMAIL PROTECTED] wrote: Em Domingo 22 Abril 2007 03:12, Richard Lynch escreveu:

Re: [PHP] Preventing SQL Injection/ Cross Site Scripting

2007-04-24 Thread Justin Frim
Just my two cents worth... Magic quotes are the work of the devil. It's a shame that so many PHP installations have them enabled, and a huge disappointment that PHP is actually distributed with this stuff enabled! The mere fact that a script can't change this setting creates a real hassle

[PHP] Separating words based on capital letter

2007-04-24 Thread Dotan Cohen
I have some categories named in the database as such: OpenSource HomeNetwork I'd like to add a space before each capital letter, ideally not including the first but I can always trim later if need be. As I'm array_walking the database, I have each value at the moment I need it in a string $item.

Re: [PHP] Preventing SQL Injection/ Cross Site Scripting

2007-04-24 Thread Dotan Cohen
On 24/04/07, Justin Frim [EMAIL PROTECTED] wrote: Just my two cents worth... Magic quotes are the work of the devil. It's a shame that so many PHP installations have them enabled, and a huge disappointment that PHP is actually distributed with this stuff enabled! The mere fact that a script

Re: [PHP] Separating words based on capital letter

2007-04-24 Thread Tijnema !
On 4/24/07, Dotan Cohen [EMAIL PROTECTED] wrote: I have some categories named in the database as such: OpenSource HomeNetwork I'd like to add a space before each capital letter, ideally not including the first but I can always trim later if need be. As I'm array_walking the database, I have

Re: [PHP] Separating words based on capital letter

2007-04-24 Thread Richard Davey
Dotan Cohen wrote: I have some categories named in the database as such: OpenSource HomeNetwork I'd like to add a space before each capital letter, ideally not including the first but I can always trim later if need be. As I'm array_walking the database, I have each value at the moment I need

Re: [PHP] Separating words based on capital letter

2007-04-24 Thread Roman Neuhauser
# [EMAIL PROTECTED] / 2007-04-25 00:16:40 +0300: I have some categories named in the database as such: OpenSource HomeNetwork I'd like to add a space before each capital letter, ideally not including the first but I can always trim later if need be. As I'm array_walking the database, I

Re: [PHP] Preventing SQL Injection/ Cross Site Scripting

2007-04-24 Thread Eric Butera
On 4/24/07, Dotan Cohen [EMAIL PROTECTED] wrote: Thanks. Most of that has already been done now, but I'll certainly keep your functions handy. I'll likely need them at some point. One thing you might want to keep in mind is that this little fix is going to get executed on each request if you

Re: [PHP] Separating words based on capital letter

2007-04-24 Thread Arpad Ray
Roman Neuhauser wrote: implode(' ', preg_split('~(?=[[:upper:]])~', 'FooBarBaz', -1, PREG_SPLIT_NO_EMPTY)); Or just.. preg_replace('/\B[A-Z]/', ' $0', 'FooBarBaz') Arpad -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] It works ok on local host but buggy on remote host!

2007-04-24 Thread Jochem Maas
H.T wrote: Hi coders, I wrote this piece of code to use for Google searching using daterange directive. it works ok on local host running IIS and PHP 5.1.2 but when i test it on my host running php 4.4.4 on linux, $julian_days_from and don't develop php4 code on php5, it's like trying to

Re: [PHP] Separating words based on capital letter

2007-04-24 Thread Dotan Cohen
Thanks, all for the suggestions. Richard, that code is a masterpeice. I have no problems with regexs, though, only with the regex that I wasn't doing properly. Roman, I'm still picking your code apart and trying to understand everything. I see I'll be learning quite a bit from that. Arpad,

[PHP] breakthrough: get record, insert on different table works

2007-04-24 Thread Thufir
it ain't pretty, but it's like a sugar rush! Finally, able to enter data on forms which I can create :) [EMAIL PROTECTED] ~]# [EMAIL PROTECTED] ~]# cat /var/www/html/contacts.php -n 1 html 2 headtitlecontacts/title/head 3 body 4 ?php 5 $user=feeds; 6

Re: [PHP] Separating words based on capital letter

2007-04-24 Thread Richard Lynch
On Tue, April 24, 2007 4:16 pm, Dotan Cohen wrote: I have some categories named in the database as such: OpenSource HomeNetwork I'd like to add a space before each capital letter, ideally not including the first but I can always trim later if need be. As I'm array_walking the database, I

Re: [PHP] It works ok on local host but buggy on remote host!

2007-04-24 Thread Richard Lynch
On Tue, April 24, 2007 3:40 pm, H.T wrote: I wrote this piece of code to use for Google searching using daterange directive. it works ok on local host running IIS and PHP 5.1.2 but when i test it on my host running php 4.4.4 on linux, $julian_days_from and $julian_days_to variables don't get

Re: [PHP] List

2007-04-24 Thread Richard Lynch
On Tue, April 24, 2007 12:53 pm, Beauford wrote: Does anyone else have this problem with the list. It seems that every time I check my email there is one or more messages from the list that royally screws up Outlook. I usually have to delete all list messages from the actual server and

Re: [PHP] secure alternative to HTTP_REFERER

2007-04-24 Thread Richard Lynch
On Tue, April 24, 2007 9:35 am, AraDaen wrote: Im looking for info about a secure alternative to the use of $_server['http_refere'] to check in a script from where are arriving $_post vars. any suggestion? HTTP_REFERER is not even reliably sent on all browser, much less useful as a security

Re: [PHP] Separating words based on capital letter

2007-04-24 Thread Myron Turner
Richard Lynch wrote: Why rule out PCRE, which is probably the best weapon for the job? $string = ltrim(preg_replace('([A-Z])', ' \\1', $string)); Don't mean to be pedantic, but you left out the '/. . ./': $string = $string = ltrim(preg_replace('/([A-D])/', \\1, $string));

Re: [PHP] Re: Re: Suggestions for Web based FileServer/Mailaccess

2007-04-24 Thread Richard Lynch
On Tue, April 24, 2007 9:29 am, Michelle Konzack wrote: I suppose you could build a parallel File System to your Maildirs, then within each of those, make a directory by Message-id: header, then put any attachments with the cid: name as the file name. One question: Is the cid: special to

Re: [PHP] transparent gifs with matte?

2007-04-24 Thread Richard Lynch
On Tue, April 24, 2007 9:08 am, Ross wrote: I am looking to create a transparent text gif that allows me to set a colour for the matte. I have it working as a PNG but this is no good in IE. Does anyone have an exampe of this? This is my code so far. ?php header(Content-type:

Re: [PHP] Shell used by system()

2007-04-24 Thread Richard Lynch
On Tue, April 24, 2007 8:39 am, Marco Michelino wrote: Hi *, is it possible to change the shell used by system() , exec() and similar PHP funtions? I'm running mod_php in apache on Linux. Apache shell is set to /sbin/nologin but PHP insists to call /bin/sh... I suspect you cannot change

Re: [PHP] Problems installing php with pdflib

2007-04-24 Thread Richard Lynch
On Tue, April 24, 2007 7:39 am, Tijnema ! wrote: On 4/17/07, Richard Lynch [EMAIL PROTECTED] wrote: On Sat, April 14, 2007 3:55 am, Merlin wrote: I am moving to a new box and want to install php with pdflib again. After configure I get an error saying: pdflib.h not found! Check the path

Re: [PHP] voucher manipulation

2007-04-24 Thread Richard Lynch
On Tue, April 24, 2007 6:55 am, Steven Macintyre wrote: they wish to create a voucher system where if you reach so many points etc you can claim a voucher (using the design) with a expiry date ... current + 30days and a unique voucher number. Now, I have looked at ImageCreateFromjpeg etc

Re: [PHP] What determines the relative directory, and can I control it?

2007-04-24 Thread Richard Lynch
On Tue, April 24, 2007 12:54 am, Dave M G wrote: I am developing a content management system, and one of the goals is to separate out the design entirely from the PHP scripting and content. Go study all the existing big CMS systems out there. And all the Templating engines. Then get back to

Re: [PHP] using ImageTTFText in a page

2007-04-24 Thread Richard Lynch
On Mon, April 23, 2007 12:50 pm, Ross wrote: This script work on it's own but fails when emeded in another php file. Embedding it in another file how?... All I want to do is create a function and call it passing a text parameter. Also is it possbile to output the image to a file insert the

Re: [PHP] make a gif

2007-04-24 Thread Richard Lynch
On Mon, April 23, 2007 12:01 pm, John Taylor-Johnston wrote: I want to print [EMAIL PROTECTED] into a gif or png. How do I do this? Thanks. It seems too simple to ask. -- file: foo.php - ?php $image = imagecreatetruecolor(400, 20); $white =

Re: [PHP] Re: posting variables to parent frame

2007-04-24 Thread Richard Lynch
Maybe he's thinking FRAMESET??? On Tue, April 24, 2007 9:39 am, Stut wrote: Al wrote: iFrames are obsolete and only IE handles them. I don't even know if IE7 does. Well that's just a complete load of rubbish. The iframe tag is not obsolete, and I don't know where you got the idea that

Re: [PHP] help needed to write an installation script for my php application

2007-04-24 Thread Richard Lynch
On Mon, April 23, 2007 7:36 am, [EMAIL PROTECTED] wrote: Could you please help me to write an installation script to install a php based application in Windows. 1. I have WAMP5.0 running my my IBM T43 laptop. 2. I have created a php application. 3. I would like to know how to create an

Re: [PHP] Separating words based on capital letter

2007-04-24 Thread Dotan Cohen
On 25/04/07, Richard Lynch [EMAIL PROTECTED] wrote: On Tue, April 24, 2007 4:16 pm, Dotan Cohen wrote: I have some categories named in the database as such: OpenSource HomeNetwork I'd like to add a space before each capital letter, ideally not including the first but I can always trim

Re: [PHP] should I be looking to eliminate all notices?

2007-04-24 Thread Richard Lynch
On Mon, April 23, 2007 2:56 pm, Justin Frim wrote: Now that's a stupid example, but, you get the idea. Well, we agree that it's a stupid example... :-) :-) :-) ?php $formfield = isset($_GET['formfield']) ? $_GET['formfield'] : ''; // VALIDATE $formfield here!!! // be as strict as you can

RE: [PHP] Preventing SQL Injection/ Cross Site Scripting

2007-04-24 Thread Richard Lynch
On Mon, April 23, 2007 9:48 am, WeberSites LTD wrote: I'm trying to understand from the examples why anyone that has get_magic_quotes_gpc() returning true would need to use stripslashes() and then mysql_real_escape_string(). wouldn't that just add slashes to the same places? If you were 100%

Re: [PHP] Preventing SQL Injection/ Cross Site Scripting

2007-04-24 Thread Richard Lynch
On Tue, April 24, 2007 3:33 pm, Justin Frim wrote: (unfortunately in PHP these are enabled by default. AHH! Which idiot thought this was a good idea to turn them on by default? Rasmus thought it was a Good Idea because it was very convenient for his needs at the time, which as simple

Re: [PHP] Why do i get this error message?

2007-04-24 Thread Richard Lynch
On Sun, April 22, 2007 5:47 pm, H.T wrote: I get this error message when i try to check my site on localhost running IIS and PHP 5.1.2 : Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 24576 bytes) in ... and it points to the line which is pure html code!

Re: [PHP] Re: how to detect type of image

2007-04-24 Thread Richard Lynch
On Sun, April 22, 2007 10:35 am, Jonathan wrote: Alain Roger wrote: Hi, In my web application, end user is able to load images (png, jpeg, gif,..) into database. I would like to know how can i detect automatically the type of image (pnd, jpeg,...) ? i do not want to check the extension

Re: [PHP] Re: how to detect type of image

2007-04-24 Thread Richard Lynch
On Sun, April 22, 2007 12:14 pm, Tijnema ! wrote: Yeah right, a time bomb with an image header :P It should have an ELF header :) But then it would be detected by the mime_content_type i guess. mime_content_type would not detect, say, a PHP script embedded into the comments section of a JPEG

Re: [PHP] echo date('Y-m-d', $mydata-timestamp);

2007-04-24 Thread Richard Lynch
Use the MySQL function that converts timestamp into Unixtime. Or, better yet, use the MySQL function that outputs exactly the date format you want, without dinking around with Unix timestamp in the middle. http://dev.mysql.com/ Search for date_format() I do believe. It's gonna be a whole lot

Re: [PHP] php seems to be inconsistent in its handling of backslashes ... maybe?

2007-04-24 Thread Richard Lynch
On Mon, April 23, 2007 8:36 am, Philip Thompson wrote: On Apr 22, 2007, at 1:29 AM, Richard Lynch wrote: On Sun, April 22, 2007 12:54 am, [EMAIL PROTECTED] wrote: -- or maybe it's just the PCRE extension -- or quite likely I have got something wrong Hello members, I'm hoping you could

Re: [PHP] What determines the relative directory, and can I control it?

2007-04-24 Thread Dave M G
Sancar, Tijnema, Logan, Richard, Thank you all for your replies. I kind of suspected that this was a client side issue. But I thought it was worth fishing for ideas since there are many on this list who are a lot smarter about PHP than I am. I might adopt something similar to Logan's $path

  1   2   >