The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.
Revision history for WWW::Mechanize::Plugin::JavaScript and ::DOM

0.005a  7 September, 2008
        The DOM plugin (0.006):
        • The  window  object’s  *_function  methods  (alert_function,
          etc.)  have been renamed to  set_*_function,  which is what
          the docs already said;  and they actually work  now.  As  a
          result,  the corresponding options to the JavaScript plugin
          now work again. (They were broken in the previous release.)
        JE back end (0.005):
        • Properties and methods  that  are  supposed  to  return
          DOMStrings can now return null. They used to return the
          string ‘undefined’.

0.005   7 September, 2008
        The DOM plugin:
        • New scripts_enabled method for enabling/disabling scripts.
        • The window object has been disentangled from the JavaScript
          plugin and made its own Perl class, under the DOM namespace.
          It is accessible via the ‘window’ method.
          • This allows the window  object  to  inherit
            from HTML::DOM::EventTarget, which provides
            addEventListener, onclick, etc.
          • As a bonus, it has a ‘self’ method.
        • The JS plugin’s check_timeouts method is now deprecated. Use
          the DOM plugin’s new check_timers method instead.
        The JavaScript plugin:
        • Support for javascript: URLs
        • The JavaScript back end’s constructor is now called with the
          window object as its argument.  It has to  make  the  global
          object delegate to the window.
        JE back end (0.004):
        • Modified to conform to the previous item. It does not yet
          support wrapping global objects when they are  passed  to
          other JS environments.

0.004   19 August, 2008
        The DOM plugin:
        • <body onload=...> now works.
        • The DOM plugin can now be C<require>d without Mech already
          loaded, so it works with tools like pmvers.
        The JavaScript plugin:
        • The location object now stringifies to its href property
          instead of [object Location].

0.003   29 July, 2008
        The DOM plugin:
        • Event attribute handlers now receive URL and line
          number info.
        • On a page that has no Content-Script-Type header, a
          script element with no language specified no longer
          causes warnings.
        • It used to be that,  if multiple script elements  or  event
          attributes used the same  handler,  and  that  handler  was
          passed to the plugin with a regexp to select it (as opposed
          to 'default'),  only every other script/event would be trig-
          gered  (forgot to clear a couple of hash  iterators).  This
          has been fixed. 
        • $mech->content now returns the content in the encoding of
          the page itself, rather than the encoding of the first page
          encountered.
        The JavaScript plugin:
        • The engine method (experimental and undocumented--read the
          source) has been added.
        • clear_timeouts now actually works properly. It used to run
          the code for each timeout only if the specified  time  had
          *not* elapsed.
        • Line numbers for event attributes are now passed to the back
          end’s event2sub method.
        JE back end:
        • Read-only properties are now marked as such in the JS  envi-
          ronment  (which prevents the setting of a property if a pro-
          totype has a read-only property of the same name --the only
          difference it makes) and now have their types (string,  num-
          ber, etc.) set properly.
        • Class bindings now use JE’s ‘unwrap’ feature, so version
          0.022 is now required.
        • event2sub now supports line numbers.

0.002   23 December, 2007
        The DOM plugin:
        • The DOM plugin’s interface has changed.  The  callback  rou-
          tines passed to it now get a WWW::Mechanize object as their
          first argument.
        • Line numbers for inline scripts now work properly.
        The JavaScript plugin:
        • You can now set up class bindings before fetching the first
          page (it used to die).
        • CSS::DOM is now a prerequisite.
        • setTimeout and clearTimeout have been added, along with the
          check_timeouts plugin method.
        • There is now a ‘screen’ object, but it has no properties.
          You have to  set  them  yourself  with  an  ‘init’  call-
          back routine.
        • There is an  ‘open’  method which simply moves to the  next
          page, ignoring all arguments except the first. It is just a
          temporary placeholder.
        • The navigator object now has an appName property, set to
          WWW::Mechanize.
        • Back-ends are now expected to accept a third argument to
          new_function, indicating the return type (the JE binding
          supports this of course :-).
        • JavaScript code referenced in the page itself (as opposed to
          code passed to the plugin’s eval method)  used to  be  evalu-
          ated in the same JS environment  for  all  pages.  This  has
          been fixed.
        JE back end:
        • JS event handlers for HTML elements now have the form in the
          scope chain.  (This applies to  all  elements  that  have  a
         ‘form’ method.)
        • JS event handlers now have the ‘this’ value set correctly.

0.001   24 November, 2007
        First CPAN release
        • The JavaScript plugin has been completely restructured. It
          now supports multiple backends.
        • It now allows one to provide an initialisation function that
          is run whenever a JavaScript environment is created, as well
          as custom alert, confirm and prompt functions.
        • Allows binding of custom Perl classes via 'bind_classes'.
        • The DOM plugin’s callback routines  for  fetching  the  page
          content as HTML or text now check to see whether the page is
          HTML first.
        • The DOM plugin now overrides extract_forms.
        • Started work on event-handling.
        • A few other minor things

0.0.2   19 July, 2007
        Updated ::DOM to work with a new patch for WWW::Mechanize
        (modified according to Eric Wilhelm's suggestion) 

0.0.1   17 July, 2007
        A proof-of-concept sent to Andy Lester and to the LWP mailing
        list.  Requires a  patch  to  WWW::Mechanize  (also  sent  to
        the list).