Q:

Dojo: Get ID of inlineEditBox on OnChange

I'm using dojo and dijit and have an inlineEditBox widget.  I'm trying to capture the onchange event and send a key/value post to a php page (to set into a database).  The value is the new value just submitted, available from e.target.value.  That's easy.
I'd like the key value to be the id of the inlineEditBox widget.  How can I access that programatically?

A:

Since InlineEditBox is a widget it's best not to monitor DOM level events.   Instead, why not connect to InlineEditBox.onChange?   For example:
<span dojoType="dijit.InlineEditBox" ...>
     <script type="dojo/connect" event="onChange" args="value">
          console.log(this.id + " changed to value" + value);
     </script>
</span>

