Problem firing click event .
Hello,
Im trying to fire a click event on an id that I have ?"bolded"?. Only it's not firing, hence my post.
The code is from a third party that cant be changed.
The code builds a div section at the very last element, on every keydown in a text box.
It's an autosuggest that produces markup and is deleted after every new keydown or click
My code is as follows
Any help is most appreciated
- alert("clicked");
- $("ul > #as_ul a").on("click", "#as_ul", function() {
- });
The markup is as follows:
- <div style="left: 347px; top: 1024px; width: 400px;" class="autosuggest" id="as_testinput_xml">
- <div class="as_header">
- <div class="as_corner"></div>
- <div class="as_bar"></div>
- </div>
- <ul id="as_ul">
- <li>
- <a name="1" href="#">
- <span class="tl"> </span>
- <span class="tr"> </span>
- <span><em>W</em>aldron, Ashley<br><small>Leicestershire</small></span>
- </a>
- </li>
- <li>
- <a name="2" href="#">
- <span class="tl"> </span>
- <span class="tr"> </span>
- <span><em>W</em>heeler, Bysshe<br><small>Lincolnshire</small></span>
- </a>
- </li>
- </ul>
- <div class="as_footer">
- <div class="as_corner"></div>
- <div class="as_bar"></div>
- </div>
- </div>