Adding a Prefixr command to TextMate 2

I was recently looking into how to add a Prefixr command to TextMate 2. For those of you not familiar, Prefixr is a way (created by Jeffrey Way of NetTuts) to take a new-ish CSS property like box-shadow or transform and add all the vendor-specific prefixes automatically. So: transform: rotate(-7deg); becomes: -webkit-transform: rotate(-7deg); -moz-transform: rotate(-7deg);… Continue reading Adding a Prefixr command to TextMate 2

Easy way to pass multiple variables to a CodeIgniter validation callback

I was recently working on a custom form validation callback for my CodeIgniter script. By default, one gets the field that you’re validating available in the callback function. For example, if I have the following form validation rule: $this->form_validation->set_rules(‘discountGlobal’, ‘Global Discount’, ‘trim|integer|max_length[1]|xss_clean|prep_for_form|only_one_global_discount[]’); My custom callback is only_one_global_discount. I am not explicitly passing anything through to… Continue reading Easy way to pass multiple variables to a CodeIgniter validation callback