CodeIgniter Thanks

Thanks and information sharing left with the guys at CodeIgniter following the development of Map of Needs

The following is the thanks and information sharing left with the guys at CodeIgniter following the development of Map of Needs

“Hi – this is my first post

After a couple of years slogging away on my daily train commutes and working into the wee hours, my new start-up went live a few weeks back.

I had a very enjoyable time learning and building this with CodeIgniter on the way. The framework made most things a breeze and was backed with a great community of supporters that, for most issues, meant answers were generally at hand. Apologies for not being an active member along the way!

So, a big thanks to all the engineers & contributors with EllisLab and elsewhere for CodeIgniter and special thanks too to the folks in the forums who helped along the way but may not have known it.

At this risk of this turning into an ad and offending, I’ll get the new site promo out of the way now: www.mapofneeds.com. Feedback, comments, questions all welcome.

I’ll make with this by sharing a little info and experience gathered along the way 🙂

I’ve integrated with Paypal, Google recaptcha, Tank Auth and of course Google Maps. JQuery & JQueryUI are used along with Slimbox and another couple of scripting helpers. Ajax is your friend! And I’m using Flexigrid for some of the browser based administrations i.e. User, custom blog admin.Of the more split vote discussions I came across, the following come to mind tonight:

  • Store uploaded images in the DB or file store? I went with DB. Slightly slower to upload/retrieve, but easier to manage (can always chuck some hardware at the former –incidentally, I’m running on a VSP from Hostgator.
  • Switching site to “Back Soon”. I just remove the _ from the html file I have in my /maintenance directory and the following code in the primary index.php takes care of everything:
$maint = 'maintenance/maintenance.html';
if (file_exists($maint))
  require_once($maint);
else
  require_once BASEPATH.'core/CodeIgniter'.EXT;
  • Tank Auth – should it support profiles or not?? Hah, that was a fun one. I request the user completes their profile population following email verification of the account, but would have preferred this done earlier in the process. Still, not a big deal and a lot of sites are doing it this way these days. Tank Auth could do with some caching and support for ‘Secured action’ checks though.

One thing I did find myself doing was to add

function set_default($field, $value){
  $this->_field_data[$field]['postdata'] = $value;  
}

to Form_validation.php so I could set fields when doing an initial load from the database and reduce the amount of additional work elsewhere. Was this wrong of me? (don’t bother answer thing this just today). Obviously I’ll have to keep an eye on this with CI upgrades, so might review when this becomes necessary again. I did do one upgrade throughout the project.

My background tasks are PHP files executed by cron invoking a wrapper php file located in a Private folder (outside the CodeIgniter framework) i.e. php –f which in turn invokes a public PHP file via within the CodeIgniter framework using get_web_page. There’s a private token passed from the wrapper to the main code to ensure no one can just execute it publically. Regardless of how long background task takes, cron runs all the time and there’s a singleton check to avoid double-ups.

Some of the stuff above is very brief. I’m happy to share most of my IP with folks – the stuff you can’t just pinch off the site that is. Is perhaps a couple of articles the best way to do this? Let us know if there’s anything I should begin with.

So, nice to be here. Many thanks again. Thanks for visiting the site if you do. Extra thanks for making use of the site and or spreading the word 🙂

Regards Brendan Lester “

Last modified August 6, 2024: updates - additioal blog (2086932)