Message delay

Got something cool to share with AppGini users? Feel free to post it here!
Post Reply
gerardus
Posts: 20
Joined: 2013-11-11 08:29

Message delay

Post by gerardus » 2014-02-11 12:22

Hi all,

Does anybody know how to reduce the time the message "New record saved" appears?
I stays there for 4 or 5 seconds and I find it very irritating.

Best regards,

Gerard.

gerardus
Posts: 20
Joined: 2013-11-11 08:29

Re: Message delay

Post by gerardus » 2014-02-12 08:23

Ok, I reply to myself.

incCommon.php, line 299:

Code: Select all

$notify_template = '<div id="%%ID%%" class="alert %%CLASS%%" style="display: none;">%%MSG%%</div>' .
			'<script>' .
				'jQuery(function(){' .
					'jQuery("#%%ID%%").show("slow", function(){' .
						'setTimeout(function(){ jQuery("#%%ID%%").hide("slow"); }, 4000);' .
					'});' .
				'});' .
			'</script>'."\n";
You can change the delay here :

Code: Select all

						'setTimeout(function(){ jQuery("#%%ID%%").hide("slow"); }, 4000);' .
to something faster:

Code: Select all

						'setTimeout(function(){ jQuery("#%%ID%%").hide("slow"); }, 1000);' .
Gerard.

Post Reply