INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Member Login




Remember Me
Forgot Password?
Join Us!

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

Join Tek-Tips
*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.
Jobs from Indeed

Link To This Forum!

Partner Button
Add Stickiness To Your Site By Linking To This Professionally Managed Technical Forum.
Just copy and paste the
code below into your site.

htmlfile: Type Mismatch (MooTools 1.11)

Share

htmlfile: Type Mismatch (MooTools 1.11)

htmlfile: Type Mismatch (MooTools 1.11)

(OP)
I have a page that keeps throwing javascript errors in IE. When I run script debugger, I get an error "htmlfile: Type Mismatch".

It's something to do with MooTools 1.11, but I'm very clueless with Javascript. Might even be another javascript file that is throwing off this one, for all I know.

Any ideas? Here's the page: http://www.sunshineartist.com/
 

RE: htmlfile: Type Mismatch (MooTools 1.11)

It may be something to do with the fact that you have no end of head section </head>, or start of body section <body>

Having waited for quite some time for your page to load, you may also like to look at http://www.websiteoptimization.com/services/analyze/

For these type of problems it's always worth checking your CSS for validity (http://jigsaw.w3.org/css-validator/) and your HTML (http://validator.w3.org/) and rectifying those errors first. Then bring any outstanding items to the forum.

If you want the best response to a question, please check out FAQ222-2244: How to get the best answers first.
'If we're supposed to work in Hex, why have we only got A fingers?'
Drive a Steam Roller  

RE: htmlfile: Type Mismatch (MooTools 1.11)

(OP)
Sorry for wasting your time... that's remedial stuff. Very sorry!

RE: htmlfile: Type Mismatch (MooTools 1.11)

(OP)
Okay, so I have some work to do cleaning up some of the CSS and HTML. However, the major Javascript issues are coming from the gallery script I'm using on the home page (where the picture changes, text scrolls up, etc.)

It's JD Gallery and it used MooTools and I've done very little to change it. The problems being reported when I validate are far too many for me to try and change myself.

Does anyone know of a similar script that's not so problematic?

RE: htmlfile: Type Mismatch (MooTools 1.11)

(OP)
Dan,

Thanks for forwarding that. I was hopeful at first, but it didn't worked. It asked me to change line 2590 in the MooTools JS from:

CODE

removeListener: function(type, fn){
            if (this.removeEventListener) this.removeEventListener(type, fn, false);
            else this.detachEvent('on' + type, fn);
            return this;
        }

to

CODE

removeListener: function(type, fn){
         try
         {
                        if (this.removeEventListener) this.removeEventListener(type, fn, false);
                        else this.detachEvent('on' + type, fn);
         }
         catch (e)
         {
         }
                        return this;
                }

Saying it would suppress errors, which would be about all I could do since I don't "own MooTools". But that didn't work. I'm getting the same error. Another solutions suggested I stop including the compressed MooTools JS file, but when I did, JD Gallery didn't work anymore (shockers of all shockers!)

One solution suggested I used Error Console in FF to debug the javascript, but it didn't even find an error with the JS (only some CSS warnings). ARGH!!!

So, I'm still at square one.

RE: htmlfile: Type Mismatch (MooTools 1.11)


Using the uncompressed MooTools file shouldn't break your code, so perhaps you have other errors?

Personally, I would never develop using a packed version of anything, as they are a nightmare to debug.

My advice: Go to the full, uncompressed, library until you have resolved your problem.

Dan

 

Coedit Limited - Delivering standards compliant, accessible web solutions

Dan's Page @ Code Couch: http://www.codecouch.com/dan/

Code Couch Tech Snippets & Info: http://www.codecouch.com/
 

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close