• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
MeNeedz Password

#17
[eluser]Pinkiee[/eluser]
I have just started looking into CI, and I was writing a prototype and needed something similar to this.

Sorry, not be be harsh, but I can't in good conscious let people who don't know any better use this with out knowing how much work it needs. I only had a look at one of the functions. (Password strength)

Couple of things you need to look into bud,

ctype (in general)
ctype_lower
ctype_upper
ctype_digit
ctype_punct

Creating an array for "lower case" etc isn't needed in this situation given the scope of the helper.

If your not doing anything to a variable then there is no reason to make an assignment

$i +=0; // is useless

You don't need to loop through the string for every single check your doing, you could loop through it once and do a switch statement and just increment the counters.

This is a bit of personal choice, but if you are looping through a string looking for something and you find it, there is no reason to keep looping.

Sorry this is all off memory as I was looking at it last night.

You can do one loop.

Really good concept though, and I think it would be quite a useful helper, when I get to a computer with a winrar on it, I will post a little clean up of the code so you can see the changes I would suggest.


Messages In This Thread
MeNeedz Password - by El Forum - 01-02-2009, 04:28 AM
MeNeedz Password - by El Forum - 01-04-2009, 04:51 AM
MeNeedz Password - by El Forum - 01-04-2009, 10:17 AM
MeNeedz Password - by El Forum - 01-04-2009, 11:08 AM
MeNeedz Password - by El Forum - 01-04-2009, 12:16 PM
MeNeedz Password - by El Forum - 01-04-2009, 02:41 PM
MeNeedz Password - by El Forum - 01-04-2009, 10:13 PM
MeNeedz Password - by El Forum - 01-05-2009, 03:01 AM
MeNeedz Password - by El Forum - 01-05-2009, 12:13 PM
MeNeedz Password - by El Forum - 01-05-2009, 12:26 PM
MeNeedz Password - by El Forum - 01-05-2009, 01:08 PM
MeNeedz Password - by El Forum - 01-05-2009, 01:15 PM
MeNeedz Password - by El Forum - 01-05-2009, 02:34 PM
MeNeedz Password - by El Forum - 01-05-2009, 02:45 PM
MeNeedz Password - by El Forum - 01-05-2009, 02:52 PM
MeNeedz Password - by El Forum - 01-23-2009, 11:01 PM
MeNeedz Password - by El Forum - 06-30-2009, 06:38 PM
MeNeedz Password - by El Forum - 07-01-2009, 01:36 AM
MeNeedz Password - by El Forum - 07-01-2009, 07:10 PM
MeNeedz Password - by El Forum - 07-02-2009, 02:03 AM
MeNeedz Password - by El Forum - 07-02-2009, 06:28 AM
MeNeedz Password - by El Forum - 07-02-2009, 06:29 AM
MeNeedz Password - by El Forum - 07-02-2009, 07:03 AM
MeNeedz Password - by El Forum - 07-02-2009, 09:00 AM
MeNeedz Password - by El Forum - 07-02-2009, 09:36 AM
MeNeedz Password - by El Forum - 01-02-2010, 07:26 AM
MeNeedz Password - by El Forum - 01-02-2010, 07:35 AM
MeNeedz Password - by El Forum - 01-02-2010, 07:58 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.