capsx Posted January 4, 2004 Report Share Posted January 4, 2004 (edited) vajag no43kot $var vai ir tikai vārds un garaks par 3 simboliem if(!preg_match("/([a-z]|ž|č|ņ|ā|š|ģ|ķ|ļ|ē|ū|ī){3}/i",$var)) shiten no43kojas vai pirmie 3 simboli ir burti, kaa tur uzraxtit lai 43ko vai viss vards ir simboli un vai ir garaks par 3 simboliem ? un jautajums - kaa lai piespeizh [a-z] atpaziit visus lv burtus, ne tikai dazhus ? :) Edited January 4, 2004 by capsx Link to comment Share on other sites More sharing options...
hu_ha Posted January 4, 2004 Report Share Posted January 4, 2004 nu ja tev shitais straadaa, tad tikai piemet vienu komatinju if(!preg_match("/([a-z]|ž|č|ņ|ā|š|ģ|ķ|ļ|ē|ū|ī){3,}/i",$var)) par lv burtiem nezinu, visdriizaak ka naaksies uztaisiit masiivu, kuraa buus visi lv burti. jo tas pats ir ar funkcijaam kur paarveido lielos burtus uz mazajiem - arii paarveido tikai burtus a-zA-Z un paareejiem ir vajadziigs masiivs... Link to comment Share on other sites More sharing options...
capsx Posted January 5, 2004 Author Report Share Posted January 5, 2004 hmzz ieprieksh man bija 3, bet tad nebija ^$ :) shitac darbojas: preg_match("/^([a-z]|ž|č|ņ|ā|š|ģ|ķ|ļ|ē|ū|ī){3,}$/i",$var) Link to comment Share on other sites More sharing options...
Recommended Posts