Skip navigation
lovespring
Currently Being Moderated

handle dreamweaver event in extension

Apr 12, 2009 11:58 AM

I have ported ctags to dreamweaver. so that we can click and go to the definition of tags.

I want handle all dw.saveDocument() event in my extension, so I can just update the tags of the document.

How can do this?

 

MM.event.registerFnCall('dw.saveDocument()', 'myhandler.htm')

This doesn't work.

 
Replies
  • Currently Being Moderated
    Apr 13, 2009 9:15 AM   in reply to lovespring

    You can use the _beforeSave and/or _afterSave mechanisms to handle this event.

     

    Randy

     
    |
    Mark as:
  • Currently Being Moderated
    Apr 14, 2009 8:20 AM   in reply to lovespring

    Try this:

     

    var url = "";

    var dom = dw.getDocumentDOM();

    if (dom != null) {

      url = dom.URL;

    }

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points