Ostedesign - ostedesign.com - Web Development and Design, Rochester NY
General Information:
Latest News:
Get controller name inside Symfony2 twig template 11 Dec 2012 | 11:22 pm
Have you ever wanted to get the name of the current controller inside one of your Symfony2 Twig files? Well good news, I can show you how. {{ app.request.attributes.get('_template').get('controller') ...
Compiling less files with assetic on MAMP 9 Dec 2012 | 04:47 am
If you followed my previous post to get mopa bootstrap working with assetic, you might be running into a problem like the error below. After some digging around I found this which points to a forum po...
Symfony2 with intl extension using MAMP 8 Dec 2012 | 09:29 pm
I have been using Symfony2 a lot lately and I recently had the need to use the Country Form Type. When I tried to use the form type $builder->add('country', 'country'); I was getting the following err...
Using Twitter Bootstrap and Symfony2 with MopaBootstrapBundle 5 Jul 2012 | 11:26 pm
The other day I wanted to integrate Bootstrap into a Symfony2 project. I came across a nice bundle that helps with this called MopaBootrapBundle. Here are the steps I took to get it working. We need...
Useful Helper Function to Add http:// To a URL If Needed 11 May 2012 | 08:15 am
Have you ever tried to create a link dynamically in php with a URL such as ‘facebook.com’? If you have you know that URLs like that don’t work so well. It will simply append the URL onto the end of th...
Show Current and Future Posts 8 May 2012 | 06:30 am
If you would like to disregard the post date and show both future and current posts I would recommend using the following code. Or you can set it up so that it will only be valid for a specific custo...
jQuery Plugin in its Most Simple Form 14 Mar 2012 | 08:34 am
If you are looking for the absolute bare bones layout for a jQuery plugin, look no further. Below is a basic starting point for any jQuery plugin.
get template directory uri VS get stylesheet directory uri 14 Feb 2012 | 12:03 pm
Have you ever wondered what the difference is between get_template_directory_uri and get_stylesheet_directory_uri? The Codex starts off by telling us that they return the template directory and styles...
Remove WordPress Admin Bar the Easy Way 11 Feb 2012 | 10:42 am
Sometimes the WordPress admin toolbar simply gets in the way. Usually when working on design work or if you just want to view your site how a visitor would see it removing the admin bar is a must. Pa...
Using Ajax on Front End of WordPress Site 31 Jan 2012 | 10:20 am
Using ajax in the admin of a WordPress site is easy because the variable ajaxurl is provided for you. This allows you to write the following code without issue. However, if you tried to use this same...