I have a function that checks the syntax of a string using preg_match. This function is used in a loop and always hangs on the same string (7 out of many more). However, the function acts as expected when used individually on that string (ie when the array of strings to loop on is reduced to just the "problem string". The string and the preg_match are: $text = 'C56_3, C55_3, C57_3, C59_3, C58_3, C52_3, C50_3, C53_3, C54_3, C51_3, C60_3, C2_3, C3_2, C7_2, C8_2, C5_2, C64_3, C61_3, C65_3, C67_3, C66_3, C28_3, C29_3, C26_3, C27_3, C32_3, C33_3, C30_3, C31_3, C1_2, C4_2, C6_2, C9_3, C24_3, C25_3, C22_3, C23_3, C44_3, C45_3, C42_3, C43_3, C48_3, C49_3, C46_3, C47_3, C36_3, C37_3, C34_3, C35_3, C40_3, C41_3, C38_3, C39_3, C41_2, C40_2, C43_2, C42_2, C39_2, C36_2, C35_2, C38_2, C37_2, C7_0, C48_2, C11_0, C16_0, C47_2, C18_0, C44_2, C46_2, C45_2, C4_1, C27_2, C8_1, C3_1, C26_2, C1_1, C23_2, C25_2, C24_2, C32_2, C31_2, C34_2, C33_2, C30_2, C6_1, C28_2, C29_2, C5_1, C10_0, C19_0, C21_0, C22_0, C23_0, C59_2, C56_2, C55_2, C58_2, C57_2, C66_2, C65_2, C1_0, C67_2, C64_2, C60_2, C20_0, C61_2, C15_0, C12_0, C13_0, C17_0, C6_0, C14_0, C8_0, C9_0, C2_0, C3_0, C24_0, C52_2, C54_2, C53_2, C51_2, C5_0, C4_0, C50_2, C49_2, C47_1, C48_1, C45_1, C46_1, C49_1, C52_1, C53_1, C50_1, C51_1, C44_1, C37_1, C38_1, C35_1, C36_1, C39_1, C42_1, C43_1, C40_1, C41_1, C5_3, C6_3, C66_1, C67_1, C8_3, C1_3, C7_3, C3_3, C4_3, C65_1, C56_1, C57_1, C54_1, C55_1, C58_1, C61_1, C64_1, C59_1, C60_1, C27_1, C26_1, C25_1, C28_1, C2_2, C30_1, C29_1, C2_1, C9_2, C7_1, C22_1, C24_1, C23_1, C22_2, C31_1, C32_1, C33_1, C9_1, C34_1'; var_dump(preg_match('/^\W*(?:[A-Z]{1,4}\d{1,3}(?:_\d{1,2})?(?(?!\Z)\W+))+$/' , $text)); Does anybody have any tips on what to try/look for? Thanks, Pascal PS I haven't found any notice about this, but I am starting to think there might be a limit to either the length of the string passed to preg_match or the number of time a pattern is repeated in preg_match. -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php