php-general Digest 29 May 2009 18:12:18 -0000 Issue 6148

2009-05-29 Thread php-general-digest-help
php-general Digest 29 May 2009 18:12:18 - Issue 6148 Topics (messages 293340 through 293355): detecting spam keywords with stripos 293340 by: Merlin Morgenstern 293341 by: Per Jessen 293343 by: Tom Worster 293346 by: Merlin Morgenstern 293347 by:

Re: [PHP] Confirmation email caught by spam filter

2009-05-29 Thread Per Jessen
Ashley Sheridan wrote: On Thu, 2009-05-28 at 07:45 +0200, Per Jessen wrote: Ashley Sheridan wrote: I've also seen this happen where the address that the mail was sent from is different from the MX record for the domain the email says it is sent from. The only way round this is to have

[PHP] detecting spam keywords with stripos

2009-05-29 Thread Merlin Morgenstern
Hi there, I am matching text against an array of keywords to detect spam. Unfortunatelly there are some false positives due to the fact that stripos also finds the keyword inside a word. E.G. Bewerbung - Werbung First thought: use strpos, but this does not help in all cases Second thought:

Re: [PHP] detecting spam keywords with stripos

2009-05-29 Thread Per Jessen
Merlin Morgenstern wrote: Hi there, I am matching text against an array of keywords to detect spam. Unfortunatelly there are some false positives due to the fact that stripos also finds the keyword inside a word. E.G. Bewerbung - Werbung First thought: use strpos, but this does not help

Re: [PHP] detecting spam keywords with stripos

2009-05-29 Thread Tom Worster
On 5/29/09 5:36 AM, Merlin Morgenstern merli...@fastmail.fm wrote: Does somebody have an idea on how to make my function better in terms of not detecting the string inside a word? i agree with per. learn pcre: http://us.php.net/manual/en/book.pcre.php as for successfully filtering spam by

Re: [PHP] cURL loop?

2009-05-29 Thread Daniel Brown
On Thu, May 28, 2009 at 23:31, espontaneo acohln...@gmail.com wrote: Hello! I am currently working on a script that will scrape data from a property advertising web page. The web page has multiple pages. What I'm getting is only the first page. What I wanted to do is to use curl to scrape all

Re: [PHP] Hebrew Directory Names

2009-05-29 Thread Tom Worster
On 5/28/09 2:06 PM, Nitsan Bin-Nun nit...@binnun.co.il wrote: preg_replace(/([\xE0-\xFA])/e,chr(215).chr(ord(\${1})-80),$s); ... The preg_replace() above convert the Hebrew chars into UTF8. that preg_replace takes a byte string $s and: - leaves bytes with value 0-127 intact - converts bytes

Re: [PHP] Hebrew Directory Names

2009-05-29 Thread Nitsan Bin-Nun
Your point is right but these code point does not exist in the subject string so this isn't the issue here. I'm really stuck at this one :S Thank you again for trying to help! On Fri, May 29, 2009 at 2:40 PM, Tom Worster f...@thefsb.org wrote: On 5/28/09 2:06 PM, Nitsan Bin-Nun

Re: [PHP] detecting spam keywords with stripos

2009-05-29 Thread Merlin Morgenstern
Per Jessen wrote: Merlin Morgenstern wrote: Hi there, I am matching text against an array of keywords to detect spam. Unfortunatelly there are some false positives due to the fact that stripos also finds the keyword inside a word. E.G. Bewerbung - Werbung First thought: use strpos, but

Re: [PHP] detecting spam keywords with stripos

2009-05-29 Thread Stuart
2009/5/29 Merlin Morgenstern merli...@fastmail.fm: Per Jessen wrote: Merlin Morgenstern wrote: Hi there, I am matching text against an array of keywords to detect spam. Unfortunatelly there are some false positives due to the fact that stripos also finds the keyword inside a word. E.G.

Re: [PHP] detecting spam keywords with stripos

2009-05-29 Thread Bastien Koert
On Fri, May 29, 2009 at 10:02 AM, Merlin Morgenstern merli...@fastmail.fmwrote: Per Jessen wrote: Merlin Morgenstern wrote: Hi there, I am matching text against an array of keywords to detect spam. Unfortunatelly there are some false positives due to the fact that stripos also finds

[PHP] recipes anyone?

2009-05-29 Thread PJ
I'd like to get some input on how to deal with recipes. use html pages to store and display, XML or db or... ? And what about clips, like flvs ? TIA. -- Hervé Kempf: Pour sauver la planète, sortez du capitalisme. - Phil Jourdan ---

Re: [PHP] recipes anyone?

2009-05-29 Thread Richard Heyes
Hi, I'd like to get some input on how to deal with recipes. use html pages to store and display, XML or db or... ? And what about clips, like flvs ? TIA. Actual recipes? As in a pork roast? I would put them on the file system in .html files. You could use a PHP file to serve them, and have a

RE: [PHP] recipes anyone?

2009-05-29 Thread Bob McConnell
From: PJ I'd like to get some input on how to deal with recipes. use html pages to store and display, XML or db or... ? And what about clips, like flvs ? TIA. There are as many ways to do cookbooks as there are cooks. I am familiar with half a dozen, without counting the professional

Re: [PHP] detecting spam keywords with stripos

2009-05-29 Thread Per Jessen
Stuart wrote: I'm sure you could integrate SpamAssassin or similar because at the end of the day all those systems expect is a bunch of text. Exactly. You can run SA as a daemon (spamd) and feed data to it using spamc. Works very well. The full ruleset is probably too much, but it's easy to

[PHP] Numerical Recipe - Scheduling Question

2009-05-29 Thread bruce
Hi.. Got a need to be able to allow a user to specify the frequency to run certain apps/processes.. I need to be able to have the user specify a start Time, as well as a periodic frequency (once, hourly, daily, weekly...) as well as allow the user to specify every XX minutes... So i basically

RE: [PHP] Numerical Recipe - Scheduling Question

2009-05-29 Thread kyle.smith
I'm confused as to why cron doesn't work for you. It doesn't explicitly tell you when the next X occurences will be, but math does. If you schedule something to run every 5 minutes starting at 1:45 PM, it's simple work to be able to report that the next times would be 1:50 PM, 1:55 PM, 2:00 PM

Re: [PHP] Numerical Recipe - Scheduling Question

2009-05-29 Thread Stuart
2009/5/29 kyle.smith kyle.sm...@inforonics.com: I'm confused as to why cron doesn't work for you.  It doesn't explicitly tell you when the next X occurences will be, but math does.  If you schedule something to run every 5 minutes starting at 1:45 PM, it's simple work to be able to report that

Re: [PHP] Numerical Recipe - Scheduling Question

2009-05-29 Thread Bastien Koert
On Fri, May 29, 2009 at 2:12 PM, Stuart stut...@gmail.com wrote: 2009/5/29 kyle.smith kyle.sm...@inforonics.com: I'm confused as to why cron doesn't work for you. It doesn't explicitly tell you when the next X occurences will be, but math does. If you schedule something to run every 5

Re: [PHP] recipes anyone?

2009-05-29 Thread PJ
Bob McConnell wrote: From: PJ I'd like to get some input on how to deal with recipes. use html pages to store and display, XML or db or... ? And what about clips, like flvs ? TIA. There are as many ways to do cookbooks as there are cooks. I am familiar with half a dozen, without

RE: [PHP] recipes anyone?

2009-05-29 Thread Bob McConnell
From: PJ Bob McConnell wrote: From: PJ I'd like to get some input on how to deal with recipes. use html pages to store and display, XML or db or... ? And what about clips, like flvs ? TIA. There are as many ways to do cookbooks as there are cooks. I am familiar with half a

Re: [PHP] Numerical Recipe - Scheduling Question

2009-05-29 Thread Stuart
2009/5/29 Bastien Koert phps...@gmail.com: On Fri, May 29, 2009 at 2:12 PM, Stuart stut...@gmail.com wrote: Hmm, might have to write that lot up as a blog post with some example code. Sometime... I would be very interested in that. I am developing a project where a queue is required to

Re: [PHP] recipes anyone?

2009-05-29 Thread Michael A. Peters
PJ wrote: I'd like to get some input on how to deal with recipes. use html pages to store and display, XML or db or... ? And what about clips, like flvs ? TIA. I believe there is already an xml format for recipes. I would either use that format to store them, or use equivalent database

Re: [PHP] recipes anyone?

2009-05-29 Thread Michael A. Peters
PJ wrote: Thank you gentlemen. Basically, that's what I figured. But this does give me some more stuff to mull over. The only thing I'm really wondering is if it's worth doing anything with XML. For display in a web browser, the only thing you should do with xml is what browsers know how

Re: [PHP] recipes anyone?

2009-05-29 Thread Michael A. Peters
Bob McConnell wrote: like a web based front end, exclusion of specific ingredients due to allergies and being able to attach dated notes about alterations or substitutions I try each time That sounds wicked. One of my brothers is allergic to corn. Being able to flag ingredients that contain

Re: [PHP] Confirmation email caught by spam filter

2009-05-29 Thread Dee Ayy
Are you sure it's a PHP thing? The way I have some of my email accounts setup is that I only accept email from folks in my address book. If I just registered a new account somewhere, chances are I do not have them in my address book, so it will go to the Junk/Spam folder. If this is your issue,

Re: [PHP] recipes anyone?

2009-05-29 Thread Shawn McKenzie
Michael A. Peters wrote: Bob McConnell wrote: like a web based front end, exclusion of specific ingredients due to allergies and being able to attach dated notes about alterations or substitutions I try each time That sounds wicked. One of my brothers is allergic to corn. Being able to

[PHP] Re: Numerical Recipe - Scheduling Question

2009-05-29 Thread Shawn McKenzie
bruce wrote: Hi.. Got a need to be able to allow a user to specify the frequency to run certain apps/processes.. I need to be able to have the user specify a start Time, as well as a periodic frequency (once, hourly, daily, weekly...) as well as allow the user to specify every XX minutes...

RE: [PHP] Re: Numerical Recipe - Scheduling Question

2009-05-29 Thread bruce
hey shawn... strtotime (or something similar) might just work i'll always know the interval... which can be used to compute the nexttime, which then becomes the next starttime... i'm assuming there's an equally simple way to find the last day of a given month if i choose that as an interval as

RE: [PHP] Re: Numerical Recipe - Scheduling Question

2009-05-29 Thread bruce
hey shawn... on the strtotime function... it appears to simply take intervals of a string type.. is there a way to have it take intervals of the number of secs? or is there another time function that takes the current date/time, and allows you to add an interval in secs? thanks -Original

Re: [PHP] Re: Numerical Recipe - Scheduling Question

2009-05-29 Thread Stuart
2009/5/29 bruce bedoug...@earthlink.net: hey shawn... on the strtotime function... it appears to simply take intervals of a string type.. is there a way to have it take intervals of the number of secs? or is there another time function that takes the current date/time, and allows you to

Re: [PHP] Confirmation email caught by spam filter

2009-05-29 Thread LAMP
partially, this is my issue. but it looks like the message add the email address ord...@mydomain.com to you address book didn't help. at least not noticeable. afan Dee Ayy wrote: Are you sure it's a PHP thing? The way I have some of my email accounts setup is that I only accept email from

Re: [PHP] recipes anyone?

2009-05-29 Thread PJ
Michael A. Peters wrote: Bob McConnell wrote: like a web based front end, exclusion of specific ingredients due to allergies and being able to attach dated notes about alterations or substitutions I try each time That sounds wicked. One of my brothers is allergic to corn. Being able to

Re: [PHP] recipes anyone?

2009-05-29 Thread PJ
Shawn McKenzie wrote: Michael A. Peters wrote: Bob McConnell wrote: like a web based front end, exclusion of specific ingredients due to allergies and being able to attach dated notes about alterations or substitutions I try each time That sounds wicked. One of my brothers

Re: [PHP] Re: Numerical Recipe - Scheduling Question

2009-05-29 Thread Shawn McKenzie
bruce wrote: hey shawn... strtotime (or something similar) might just work i'll always know the interval... which can be used to compute the nexttime, which then becomes the next starttime... i'm assuming there's an equally simple way to find the last day of a given month if i choose