Deprecated: Assigning the return value of new by reference is deprecated in /home/webmogul/public_html/mogul/wp-settings.php on line 520

Deprecated: Assigning the return value of new by reference is deprecated in /home/webmogul/public_html/mogul/wp-settings.php on line 535

Deprecated: Assigning the return value of new by reference is deprecated in /home/webmogul/public_html/mogul/wp-settings.php on line 542

Deprecated: Assigning the return value of new by reference is deprecated in /home/webmogul/public_html/mogul/wp-settings.php on line 578

Deprecated: Function set_magic_quotes_runtime() is deprecated in /home/webmogul/public_html/mogul/wp-settings.php on line 18

Warning: Cannot modify header information - headers already sent by (output started at /home/webmogul/public_html/mogul/wp-settings.php:520) in /home/webmogul/public_html/mogul/wp-content/themes/unnamed-one-10-stable/js/livesearch.js.php on line 1

Warning: Cannot modify header information - headers already sent by (output started at /home/webmogul/public_html/mogul/wp-settings.php:520) in /home/webmogul/public_html/mogul/wp-content/themes/unnamed-one-10-stable/js/livesearch.js.php on line 1

Warning: Cannot modify header information - headers already sent by (output started at /home/webmogul/public_html/mogul/wp-settings.php:520) in /home/webmogul/public_html/mogul/wp-content/themes/unnamed-one-10-stable/js/livesearch.js.php on line 1

Warning: Cannot modify header information - headers already sent by (output started at /home/webmogul/public_html/mogul/wp-settings.php:520) in /home/webmogul/public_html/mogul/wp-content/themes/unnamed-one-10-stable/js/livesearch.js.php on line 1

Warning: Cannot modify header information - headers already sent by (output started at /home/webmogul/public_html/mogul/wp-settings.php:520) in /home/webmogul/public_html/mogul/wp-content/themes/unnamed-one-10-stable/js/livesearch.js.php on line 1
Livesearch = Class.create(); Livesearch.prototype = { initialize: function(father, url, pars, attachitem, contentitem, loaditem, resetitem, searchtext) { this.father = father; this.attachitem = attachitem; this.contentitem = contentitem; this.resetitem = resetitem; this.url = url; this.pars = pars; this.loaditem = loaditem; this.searchtext = searchtext; this.t = null; // Init timeout variable $(father).innerHTML = ''; // Style the searchform for livesearch $(this.resetitem).hide(); $(this.loaditem).hide(); Event.observe(attachitem, 'focus', function() { if ($(attachitem).value == searchtext) $(attachitem).setAttribute('value', '') }); Event.observe(attachitem, 'blur', function() { if ($(attachitem).value == '') $(attachitem).setAttribute('value', searchtext) }); // Bind the keys to the input Event.observe(attachitem, 'keyup', this.readyLivesearch.bindAsEventListener(this)); }, readyLivesearch: function(event) { var code = event.keyCode; var currentLivesearch = this; if (code == Event.KEY_ESC || ((code == Event.KEY_DELETE || code == Event.KEY_BACKSPACE) && $F(this.attachitem) == '')) { this.resetLivesearch(); } else if (code != Event.KEY_LEFT && code != Event.KEY_RIGHT && code != Event.KEY_DOWN && code != Event.KEY_UP && code != Event.KEY_RETURN) { if (this.t) { clearTimeout(this.t) }; this.t = setTimeout(this.doLivesearch.bind(this), 400); } }, searchComplete: function() { Event.observe(this.resetitem, 'click', this.resetLivesearch.bindAsEventListener(this)); Effect.Fade(this.loaditem, {duration: .1}); Effect.Appear(this.resetitem, { duration: .8 }); Effect.Appear(this.contentitem, {duration: .5}); }, doLivesearch: function() { $(this.resetitem).hide(); Effect.Appear(this.loaditem, {duration: .1}); new Ajax.Updater( this.contentitem, this.url, { method: 'get', parameters: this.pars + encodeURIComponent($F(this.attachitem)), onSuccess: this.searchComplete.bind(this) }); }, resetLivesearch: function() { Effect.Fade(this.resetitem, { duration: .7 }); Effect.Fade(this.contentitem, {duration: .5}); $(this.attachitem).value = ''; } } new FastInit( function() { new Livesearch('searchform', 'http://mogul.webmogulenterprises.com/wp-content/themes/unnamed-one-10-stable/livesearch.php', 'searchquery=', 'searchinput', 'search-results', 'search-loading', 'search-reset', 'Type and Wait to Search'); } );