This post is about how to implement Umbraco MVC forms with Unobtrusive bootstrap validation and use knockout js to perform data binding. It also covers adding additional functions and properties to mapped observables without having to add them to your c# view models.
Category Archives: Javascript
jQuery DataTables filter plugin and QUnit
Here’s something about how to create a filter plugin for the jquery datatables plugin and then test it using qunit.
Continue reading “jQuery DataTables filter plugin and QUnit” »
Easy way to expand a foundation accordion
Here’s a simple way to get a zurb foundation accordion to open all its accordion’y goodness on a single button click.
Continue reading “Easy way to expand a foundation accordion” »
Front end techniques and tips
So, I recently went to the smashing mag workshop in London, which was great. Here’s a big brain-dump of stuff I learnt. I’m not saying I agree with everything, but here it is. Continue reading “Front end techniques and tips” »
Front-end development with Hubspot and Grunt Part 2
So, the last postĀ talked about the hubspot set up. This part talks about how we used grunt to automate certain aspects of the build process.
Continue reading “Front-end development with Hubspot and Grunt Part 2” »
Front-end development with Hubspot Part 1
Recently, we’ve startedĀ using Hubspot, which is a service that helps companies with their inbound marketing. It provides a content management system (which they call a ‘content optimization system’ :p) that can be hooked in to fairly easily. For me, its syntax is very similar to twig, a popular php templating language. It provides control structures, filters, functions etc. There’s some nice bits and some truly flakey bits – here’s what I’ve learnt so far…
Continue reading “Front-end development with Hubspot Part 1” »
Unit tests for angular services
I’m trying to follow john papa’s excellent angular design principles article. One aspect to this is setting up routes that resolve service calls that can immediately be called by controllers using the ‘controllerAs’ syntax. However, the question arises of how to test these? After trawling round loads of different articles, I’ve cobbled together a solution that works (for better or worse).
Leafletjs maps for Umbraco 7
I’ve been working on a mapping property editor for Umbraco 7 recently that allows users to pick a location and zoom, or do an address lookup. Since users of the front-end website will see open street map tiles when they publish their pages, I thought it’d make sense to also show them the same style map in the back-office when they’re actually creating it. I learnt a few bits and pieces about angularjs directives here as well. Grab the code here if you like and read on.
Ajax contour forms and zurb abide
This post is about implementing the contour forms package for Umbraco and still trying to follow best practices with regard to loading javascripts just before the closing body tag. I also implemented an ajax form submission method which grabs the resulting success message. It also uses zurb’s abide javascript validation library.
Auto-output doctype template for Umbraco
This post is a continuation of this one. It discusses how to output a generic content page that loops through all properties of that page and outputs them automatically. So, for document types that are quite similar, only 1 template is required instead of 1 for each. Also, I’ve been looking at the zurb foundation reveal component, specifically using ajax to load content into it.
Continue reading “Auto-output doctype template for Umbraco” »