Pyro4816 Posted April 5, 2007 Share Posted April 5, 2007 Well, my site is running a membership system and i am having some problems with the registrations I need to block certain characters and i need to check the lingth of some of them and i'm not sure about how to do that. Example: username <?php echo 'hi'; ?> I not only need to block the characters <, $, and > but i need to make sure the username is not to long. Link to comment https://forums.phpfreaks.com/topic/45818-solved-need-help-with-validating/ Share on other sites More sharing options...
PC Nerd Posted April 6, 2007 Share Posted April 6, 2007 um, read about the special charascyers, and the fnction ti replaces them Link to comment https://forums.phpfreaks.com/topic/45818-solved-need-help-with-validating/#findComment-222624 Share on other sites More sharing options...
Pyro4816 Posted April 6, 2007 Author Share Posted April 6, 2007 can u give me any more to go on then that? Link to comment https://forums.phpfreaks.com/topic/45818-solved-need-help-with-validating/#findComment-222629 Share on other sites More sharing options...
kenrbnsn Posted April 6, 2007 Share Posted April 6, 2007 You want to look at the functions strlen(), strip_tags(), str_replace(), and htmlentities(). If you need more help, please post code that is causing problems. Ken Link to comment https://forums.phpfreaks.com/topic/45818-solved-need-help-with-validating/#findComment-222633 Share on other sites More sharing options...
Pyro4816 Posted April 6, 2007 Author Share Posted April 6, 2007 Thanks for the help Link to comment https://forums.phpfreaks.com/topic/45818-solved-need-help-with-validating/#findComment-222638 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.