What the difference between dojo.byId and dijit.byId?
问题 Each time am trying the get the value of an element in my page, I have an error as is undefined: I have tried dijit.byId('myid').innerHTML('loading...'); I get an error but when i do the same using jquery, it works $('#myid').html('loading ...') And what is the equivalent of this $('#myid').html() in dojo? Thanks for any advise 回答1: dijit.byId returns a dijit object by some id. dojo.byId is the equivalent of $() . To get/set it's HTML, use dojo.byId("my_id").innerHTML dojo.byId("my_id")