Re: [Bug] no notes, no page

From: Date: Thu, 29 Aug 2002 17:08:31 +0000
Subject: Re: [Bug] no notes, no page
References: 1 2  Groups: php.doc.chm 
Request: Send a blank email to php-doc-chm+get-433@lists.php.net to get a copy of this message
At 16:46 8/29/2002 +0200, Gabor Hojtsy wrote:
This is not a solution. Because: - You will be able to update the notes file and manual file
independently,
    so it's not guaranteed that a note file will always exist for a
page. Granted. URL should be scripted in somehow then. The URL is scripted in, just we cannot get information on the existence of a file, unless we try to load it (which fires this bug)...
Well - we can, allthough it's a bit unortodox :-) <script> var isOk = new Boolean(false); function checkState() {
        if(event.srcElement.readyState == 'interactive')
        {
                isOk=true;
        }
} chm_path = unescape(location.href.substring(8, location.href.lastIndexOf("/")+1)); document.write(
        '<xml src="mk:@MSITStore:' + chm_path +
        'simplepage.chm::/simplepage.html" name="nbuff" ' +
        'style="display:none;" onreadystatechange="checkState()" ></xml>'
    );
function showResult() {
        alert(isOk);
} window.onload=showResult; </script> change the url to notthere.html and you'll see the difference. I'll leave the details up to you :-) Met vriendelijke groeten / With kind regards, Webmaster IDG.nl Melvyn Sopacua <@Logan> I spent a minute looking at my own code by accident. <@Logan> I was thinking "What the hell is this guy doing?"

« previous php.doc.chm (#433) next »