1 Reply Latest reply on Aug 25, 2014 6:21 AM by joel_pau

    Simple code doesn't work in edge?

    RavenDesign Level 1

      Ok so if I was hand coding this it would work fine but for some reason it doesn't wok in edge ? here it is

       

      sym.$("#Stage_Info_Facebook img").click(function() {

      sym.$("#Stage_Info").hide();

      });

       

      For some reason it doesn't work?

      there is method to the madness I need the img inside the div to be clickable not the actual div itself

      Any idea's?

        • 1. Re: Simple code doesn't work in edge?
          joel_pau Level 5

          Hi,

           

          Well, i don't see your code panel. But, it doesn't run because you are mixing Edge API and jQuery.

          • jQuery: $(selector). Selector can be the id:"#Stage_...".
          • Edge API: sym.$(elementName).

           

          Here is a good mix: $( sym.lookupSelector("elementName") ).hide();

          Because sym.lookupSelector("elementName") returns the id: "#Stage_..."

           

          Note: with a click event, you can use e.target: sym.$("elementName").click( function(){ sym.$(e.target).hide() }).

           

          Using this line $("#Stage_Info_Facebook img") what do you want ? Targeting #Stage_Info_Facebook and then $(img) ?

          1 person found this helpful