Skip to content

Instantly share code, notes, and snippets.

View jonhargett's full-sized avatar

Jon Hargett jonhargett

View GitHub Profile
@jonhargett
jonhargett / LoginForm
Created September 5, 2012 20:39
Backbone View that checks to see if you are logged in and if not display a login form.
var LoginForm = Backbone.View.extend({
className : 'divLogin',
initialize : function() {
this.dialogContent = '<div class="field"><label for="username">User Name:</label> <input type="text"' +
'name="username" id="username" value="" />' +
'</div><div class="field"><label for="password">Password:</label>' +
'<input type="password" name="password" id="password" value="" /></div>';
this.render();