I am using PHP preg_match_all, and this is what I can get so far ....
[A-Za-z+\W]+\s[\d]
The only problem is that I need \ W not to be ".
So I tried:
[A-Za-z+[^\dA-Za-z"]\s?]+\s[\d]
[A-Za-z+]\s?+[^A-Za-z\d"]?\s[\d]
by the way, and he just fails, and I really can't understand why.
EDIT:
Here is the whole RegEx;
([A-Z][a-z]+\s){1,5}\s?[^a-zA-Z\d\s:,.\'\"]\s?
[A-Za-z+\W]+\s[\d]{1,2}\s[A-Z][a-z]+\s[\d]{4}
I divided it into two lines, the second line begins with what I published.
Patterns trying to match:
India – Adulterated Tea Powder Seized 18 April 2011
India – Importer of Haldiram’s Petha Sweet Cubes Issuing Voluntary Recall 26 April 2011
India – Undeclared Gluten Found in Sweets by Canadian Authorities 27 April 2011
India – Adulteration Found in Edible Oils 28 April 2011
India – Viral Disease Affects Chili Crop in Goa 28 April 2011
NOT ----> Chili – India: Goa". 8 April 2011
Ivory Coast – Potential Cocoa Quality Decline despite Sufficient Surplus 11 April 2011
Japan – Sanuki Kanzume Co. and Failure to Comply with FDA Standards 27 April 2011
Madagascar – Toxic Sardines 14 April 2011
Madagascar – Update: Toxic Sardines 26 April 2011
source
share