First steps towards saving settings

This commit is contained in:
Ricardo Tomasi 2013-05-19 18:52:12 -03:00
parent fefd0c930c
commit b808f73eff
2 changed files with 19 additions and 2 deletions

View File

@ -30,6 +30,23 @@
$('input').iCheck({
checkboxClass: 'icheckbox_square-grey'
});
$('.button-save').click(function(e){
e.preventDefault();
console.log(getSettings());
})
});
var defaultSettings = {
title: 'My Blog',
description: ''
};
function getSettings () {
return $.extend(defaultSettings, {
title : $('#blog-title').val(),
description : $('#blog-description').val()
});
}
}(jQuery));

View File

@ -128,13 +128,13 @@
<label>
<b>SEO Title Pattern</b>
<input id="blog-title" type="text" value="[Post Name] - [Site Title]" />
<input id="seo-title" type="text" value="[Post Name] - [Site Title]" />
<p>The pattern used to display your title tags</p>
</label>
<label>
<b>SEO Description Pattern</b>
<input id="blog-title" type="text" value="Auto" />
<input id="seo-description" type="text" value="Auto" />
<p>The pattern used to display your meta descriptions</p>
</label>