Preload an iframe with errorhandler
Hello guys ...
I'm looking for a function which loads an iframe in the background.
When the iframe is loaded the preload-image should be hidden (look at the function below).
But if the iframe-content can not be load (error 404, 500, ...) an error message should appear instead of the iframe.
This is my function:
- jQuery("#fzgsuche-iFrame").ready(function() {
- jQuery("#fzgsuche-iFrame").css('display', 'block');
- jQuery("#fzgsuche-iFrame-PreloadImg").css('display', 'none');
- });
Is it possible to integrate an error message if the page in the iframe can not be displayed?
Would you be so kind and tell me how to integrate it?
Thanks in advance!