What i'm doing wrong I want to remove scripts added to my guestbook
$txt = eregi_replace('<SCRIPT(*)/SCRIPT>', 'scripts not allowed', $txt);
Use preg_replace(). Doing this with eregi_replace would be a tedious pain because it doesn't do ungreedy matching.
!<script[^]*>.*?</script>!is
for example. Also watch out for
!<script.*?/>!is