Welcome Guest, Not a member yet? Register   Sign In
A different approach to "trim," and a question about project templates
#1

Hi all.  This is my first post, and I'm assuming that in Lounge it's okay to touch on two related topics in one post.  If I'm wrong, kindly correct me and I'll kindly modify as needed.
I've seen a lot of posts in various places about the removal of "trim" from the validations library, and I totally get the reason for it (modifying data and validating data are two very different things).  It got me thinking about the fact that for anything else where we use rules to dictate how a user can input data, it falls on that user to modify the data to fit our desired format.  So, I personally am opting to create a custom validation rule that directs the user to remove whitespaces at the beginning or ending of their inputs.  I'm just curious if anyone else is taking this approach?  As an aside, if there happens to be a significant number of people doing this, I wonder if it would be worth suggesting as a "replacement" for the removed "trim" function, as it does play nicely with the "validate; don't modify" concept.

Along these lines, this particular validation came into play on something else I'm working on.  I was realizing that for any project I'm going to develop in CI, there's a very high likelihood that I'm going to want / need a subtantial user interface.  In other words, I'm going to need user-related functions like register, login, logout, remember me, update profile, reset forgotten password via email temporary token, failed login lockouts, etc.  I've decided to build a "starter" project for myself with all of that fully developed ... and nothing else.  I'll simply use it as the starting point for projects I'm developing where I need that functionality, and just make small modifications to the database and models as needed when additional fields for users come into play.  Then I'll develop all other functionality and content like normal, on top of that skeleton.  I'm curious if anyone else has taken this approach.  Besides user account / access functionality, is there anything else that anyone "streamlines" as a baseline for projects they build?

Last question - once I have this starter project complete, I'd be interested in hiring someone who knows CI4 well to kick the tires a bit, and let me know if they see anything I should be doing differently.  I'm fairly new to CI, but extremely well-versed in PHP development.  It would be great to get a CI expert set of eyes on what I'm doing.  Thanks all - cheers!
Reply




Theme © iAndrew 2016 - Forum software by © MyBB