1
0
mirror of https://github.com/e107inc/e107.git synced 2025-07-10 09:36:23 +02:00

Load Signup JS code only when needed.

This commit is contained in:
Cameron
2013-03-27 16:20:31 -07:00
parent 737caec05d
commit 75e0344efe
4 changed files with 25 additions and 28 deletions

View File

@ -1,5 +1,24 @@
$(document).ready(function()
{
$('.e-typeahead').each(function() {
var id = $(this).attr("id");
var name = '#' + id.replace('-usersearch', '');
var newval = $(this).attr("data-value");
$(this).typeahead({
source: $(this).attr("data-source"),
updater: function(text, type){
if(type == 'value')
{
$(name).val(text);
}
return text;
}
})
});
// run tips on title attribute.
$(".e-tip").each(function() {