> I really have no idea what is the correct name(I'm not a  
> javascript guru), handle is a function in function(or jQuery?) scope?
> You know , i just copy your code structure. xD
> 
> Demo page:
> http://61.191.26.228/jQuery/plugins/modal/test.html

Your functions named plugin, modal_handle, modal_parse, modal_display,
modal_load, modal_after_load, modal_error, modal_resize, parseQuery, and
modal_close are all defined like this:

   theName = function() {
      ...
   },

There are two mistakes there. The functions are globals, when you probably
want them to be local. The fact that they are global is what was causing one
to overwrite another with the same name.

Also, that comma after the } shouldn't be there. It looks like you picked up
the use of the comma from object literals such as:

   var foo = {
      oneFunction: function() { ... },
      anotherFunction: function() { ... },
      andAnother: function() { ... }
   };

These functions should be defined with either:

   var whatever = function() {
      ...
   };

Or:

   function whatever() {
      ...
   }

The latter is probably a better choice because it's simpler.

Finally, you're missing a semicolon after "settings" in the "var" list at
the top. That won't affect anything unless you try to run the code through a
packer to compress it - then you may have errors.

I didn't look at the code in any great detail other than that.

-Mike


_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

Reply via email to