| wait_css.txt - 236 bytes, 434 downloads | |
| wait.php - 226 bytes, 453 downloads |
English « Post your requirements here «
Adding a 'please wait' message - SUCCESS
Udut Kenneth -- on Oct. 15 2007, from Naples, FLFounder of http://free.naplesplus.us - Naples FL USA News, Jobs, For Sale, Business Directory. Proudly utilizing YACS.
How to add a simple "please wait" message to all of your pages that disappears when ready.
Many times a page, for whatever reason (multiple SQL queries, lots of images, etc) is very slow loading.
This method adds a simple "Please wait..." as the first thing the user sees while the page is loading.
It requires javascript, but so does much of YACS
There are three things to do:
1) Put wait.php in the root directory of your yacs installation (see attached file at bottom of page)
2) Place contents of wait_css.txt in your main CSS file (I put mine right at the beginning);
3) in GLOBAL.PHP:
Just after the last header directive and before loading the page library:
You can see it in action at: http://free.naplesplus.us
Now my site slowness has more to do with using an inexpensive shared server host than YACS but I figure every little thing that helps, helps.
Kenneth Udut
This method adds a simple "Please wait..." as the first thing the user sees while the page is loading.
It requires javascript, but so does much of YACS
There are three things to do:
1) Put wait.php in the root directory of your yacs installation (see attached file at bottom of page)
2) Place contents of wait_css.txt in your main CSS file (I put mine right at the beginning);
3) in GLOBAL.PHP:
Just after the last header directive and before loading the page library:
// handle the output correctly
Safe::ob_start('yacs_handler');
Safe::header('Content-Type: text/html; charset='.$context['charset']);
// include a please wait message added by keu 10/15/07
include_once $context['path_to_root'].'wait.php';
// load the page library
include_once $context['path_to_root'].'skins/page.php';
You can see it in action at: http://free.naplesplus.us
Now my site slowness has more to do with using an inexpensive shared server host than YACS but I figure every little thing that helps, helps.
Kenneth Udut
Files
Comments
Bernard Paquesfrom nearby-an-airport Associate, 8408 posts | It works! I have checked that at your site. For your information, YACS 7.10 uses a similar trick while submitting form data to the server. A hidden panel is displayed when the submit button is hit, showing a spinning circle to make people know that some processing is on-going. This is implemented in the brand new AJAX library in shared/yacs.js, available in the alpha archive to testers.
|








History

