[PHP] Re: FImage $aSubDir

2008-10-28 Thread John Taylor-Johnston
Could it be this easy? $chopped= strlen($aFn) - 4; $filename = $chopped.".txt"; print"color='#99'>"; include($filename); print""; John Taylor-Johnston wrote: I have http://www.flash-here.com/downloads/fhimage.html installed. I like it just the way it is. But instead of displaying (

[PHP] FImage $aSubDir

2008-10-28 Thread John Taylor-Johnston
I have http://www.flash-here.com/downloads/fhimage.html installed. I like it just the way it is. But instead of displaying (see function below). Instead of displaying the file name under the photo, weak excuse for a caption, I would like to open and nl2br the contents of a like named text file.

Re: [PHP] Regex validation

2008-10-28 Thread Micah Gersten
How is anything but your webserver decrypting the $_POST data? PHP should get it after that as is. Thank you, Micah Gersten onShore Networks Internal Developer http://www.onshore.com VamVan wrote: > SSO process: > > $_POST the Email Address and password > > Get Authenticated, Get the COOKIE (

Re: [PHP] Regex validation

2008-10-28 Thread VamVan
SSO process: $_POST the Email Address and password Get Authenticated, Get the COOKIE ( Through Oracle IDM suite SOAP call) Decrypt the COOKIE ( Through Oracle Enterprise business suite SOAP call) and get the profile Info Thats what happens now. But there is a glitch in the decryption algorith

Re: [PHP] Regex validation

2008-10-28 Thread Micah Gersten
What are you talking about with a cookie and an E-Mail address? Thank you, Micah Gersten onShore Networks Internal Developer http://www.onshore.com VamVan wrote: > Yeah, I understand that its allowed in RFC. But unfortunately I use > SSO layer which decrypts the Cookie to get email address. > >

Re: [PHP] Regex validation

2008-10-28 Thread Lupus Michaelis
VamVan a écrit : This is where it messes up. So I have decided not to allow people to use that as well. By that way, you're making a lot of ennemies on this very list :D -- Mickaël Wolff aka Lupus Michaelis http://lupusmic.org -- PHP General Mailing List (http://www.php.net/) To unsubscrib

Re: [PHP] clear a mysql table

2008-10-28 Thread Lupus Michaelis
Jim Lucas a écrit : I would ass-u-me that if someone had foreign keys and/or triggers setup that they would not need to ask how to clear/empty a table I never assume that kind of thing, because he could be cleaning a database he didn't designed. It happends. :) -- Mickaël Wolff aka Lupus M

Re: [PHP] Regex validation

2008-10-28 Thread VamVan
Yeah, I understand that its allowed in RFC. But unfortunately I use SSO layer which decrypts the Cookie to get email address. This is where it messes up. So I have decided not to allow people to use that as well. Thanks On Tue, Oct 28, 2008 at 5:10 PM, Ashley Sheridan <[EMAIL PROTECTED]>wrote:

Re: [PHP] Regex validation

2008-10-28 Thread Ashley Sheridan
On Tue, 2008-10-28 at 18:07 -0500, Micah Gersten wrote: > Keep in mind that ereg will disappear with PHP 6. You might want to use > the preg functions: > http://www.making-the-web.com/2007/09/21/becoming-php-6-compatible/ > > Thank you, > Micah Gersten > onShore Networks > Internal Developer > ht

Re: [PHP] Waste of storage space?

2008-10-28 Thread Bastien Koert
On Tue, Oct 28, 2008 at 4:24 PM, Frank Arensmeier <[EMAIL PROTECTED]>wrote: > Hi all. > > In short, I am working on a system that allows me to keep track of changes > to a large amount of short texts (a couple of thousand text snippets, two or > three sentences per text). All text is stored in a d

[PHP] Re: clean data

2008-10-28 Thread Shawn McKenzie
blackwater dev wrote: > I have a project now where we would like to properly remove unwanted data > before it goes into the db such as ` and of course slashes. The problem is > I have tons of pages. Is there an easy way to add in a clean up routine on > the db side to clean it going in and coming

Re: [PHP] Regex validation

2008-10-28 Thread Micah Gersten
Keep in mind that ereg will disappear with PHP 6. You might want to use the preg functions: http://www.making-the-web.com/2007/09/21/becoming-php-6-compatible/ Thank you, Micah Gersten onShore Networks Internal Developer http://www.onshore.com VamVan wrote: > Thank Guys, > > I at least got par

Re: [PHP] Regex validation

2008-10-28 Thread VamVan
Thank Guys, I at least got part of it working , not the double words but almost everything else than that: function _email_validate($mail_address){ $invalid_charset_pattern = "[(*+?)|~<>:;{}/ ]"; if(ereg($invalid_charset_pattern, $mail_address)){ return false; }else{ return true;

[PHP] Re: Waste of storage space?

2008-10-28 Thread Maciek Sokolewicz
Frank Arensmeier wrote: Hi all. In short, I am working on a system that allows me to keep track of changes to a large amount of short texts (a couple of thousand text snippets, two or three sentences per text). All text is stored in a database. As soon as a user changes some text (insert, del

Re: [PHP] Waste of storage space?

2008-10-28 Thread Chris
1) Store the "delta" (=the actual change) of a text change. This could be done by utilizing the Pear package TextDiff. My idea was to compare the old with the new text with help of the TextDiff class. I would then grab the array containing the changes from TextDiff, serialize it and store thi

Re: [PHP] Regex validation

2008-10-28 Thread Nitsan Bin-Nun
Good to know filter_var() exists in PHP5 Unless you have PHP5 you better validate the string in the way of checking if it is fit's to your allowed characters and not checking if it contains the NOT allowed charaters. You better use: [a-z0-9A-Z\_\.]+ instead of [^\)\(\*\&[EMAIL PROTECTED] and I ha

Re: [PHP] Regex validation

2008-10-28 Thread Yeti
> If your trying to filter E-Mail addresses, then filter_var is what you > should use: > > http://php.net/filter_var If the OP (original poster) got PHP5+ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] Regex validation

2008-10-28 Thread Boyd, Todd M.
> -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On > Behalf Of Richard Heyes > Sent: Tuesday, October 28, 2008 4:30 PM > To: VamVan > Cc: php List > Subject: Re: [PHP] Regex validation > > > Hello Team of Nerds, > > Not the best way to start your request for help

Re: [PHP] Regex validation

2008-10-28 Thread Micah Gersten
VamVan wrote: > Hello Team of Nerds, > > I need help in writing a regular expression for this: > > invalid character set is: > > INVALID_STRING={"/","*","+","(",")","'\'","<",">",",",":",";","~","..",".@","@."}; > > I want to a pregmatch for these characters on my whole email address and if > matc

Re: [PHP] Regex validation

2008-10-28 Thread Richard Heyes
> Hello Team of Nerds, Not the best way to start your request for help. > I need help in writing a regular expression for this: > > invalid character set is: > > INVALID_STRING={"/","*","+","(",")","'\'","<",">",",",":",";","~","..",".@","@."}; > > I want to a pregmatch for these characters on m

Re: [PHP] Regex validation

2008-10-28 Thread Daniel P. Brown
On Tue, Oct 28, 2008 at 4:10 PM, VamVan <[EMAIL PROTECTED]> wrote: > Hello Team of Nerds, > > I need help in writing a regular expression for this: > > invalid character set is: > > INVALID_STRING={"/","*","+","(",")","'\'","<",">",",",":",";","~","..",".@","@."}; Then you need to STFW and RTF

[PHP] Regex validation

2008-10-28 Thread VamVan
Hello Team of Nerds, I need help in writing a regular expression for this: invalid character set is: INVALID_STRING={"/","*","+","(",")","'\'","<",">",",",":",";","~","..",".@","@."}; I want to a pregmatch for these characters on my whole email address and if match is found I need to return fal

[PHP] Waste of storage space?

2008-10-28 Thread Frank Arensmeier
Hi all. In short, I am working on a system that allows me to keep track of changes to a large amount of short texts (a couple of thousand text snippets, two or three sentences per text). All text is stored in a database. As soon as a user changes some text (insert, delete, update), this a

Re: [PHP] clear a mysql table

2008-10-28 Thread Jim Lucas
Lupus Michaelis wrote: > Daniel P. Brown a écrit : >> In direct response to your question, you're looking for the >> TRUNCATE command. > > I hope he doesn't have any foreign keys nor triggers. > I would ass-u-me that if someone had foreign keys and/or triggers setup that they would not nee

Re: [PHP] clear a mysql table

2008-10-28 Thread Lupus Michaelis
Daniel P. Brown a écrit : In direct response to your question, you're looking for the TRUNCATE command. I hope he doesn't have any foreign keys nor triggers. -- Mickaël Wolff aka Lupus Michaelis http://lupusmic.org -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] clean data

2008-10-28 Thread Bastien Koert
On Mon, Oct 27, 2008 at 9:53 PM, Micah Gersten <[EMAIL PROTECTED]> wrote: > In that case, I suggest you look to the MySQL lists for tips on handling > data coming in. > > Thank you, > Micah Gersten > onShore Networks > Internal Developer > http://www.onshore.com > > > > blackwater dev wrote: > > Y

Re: [PHP] Parsing URLs

2008-10-28 Thread Yeti
One could also abuse basename and pathinfo. Works in PHP4+ http://www.domain.com/page/file/'; $pathinfo = pathinfo($uri); $webpageaccess = array(); $webpageaccess[1] = $webpageaccess[2] = ''; if (isset($pathinfo['basename'])) $webpageaccess[1] = $pathinfo['basename']; if (isset($pathinfo['dirname'

Re: [PHP] PHP XSLT caching

2008-10-28 Thread Aschwin Wesselius
vladimirn wrote: Hi all, i was wondering whats the best approach to do next. I have an xml file delivered from service of my partner. On my web server (windows) i have xslt files used for xml transformation. Those files are getting bigger, so i have request to cash them and use cashed. I was t