Bug Tracker

Modify

Ticket #5741 (closed bug: worksforme)

Opened 3 years ago

Last modified 3 years ago

$(element).html(val) SERIOUS BUG

Reported by: Taturana Owned by:
Priority: undecided Milestone: 1.4
Component: ajax Version: 1.4a2
Keywords: html Cc:
Blocking: Blocked by:

Description

The problem is: when you change successively the html of an element (and the new html content has javascript code), after certain change the javascript code is no longer executed (inside the element). I'll give example in code, just download the attached file and test. Click successively on the button and you'll see the alert won't appear after the second or third click.

Attachments

test.php Download (438 bytes) - added by Taturana 3 years ago.

Change History

Changed 3 years ago by Taturana

comment:1 Changed 3 years ago by dmethvin

  • Component changed from unfiled to ajax

comment:2 Changed 3 years ago by zjs

The attachment does not use the $(element).html(val) function you refer to in the subject of the ticket. I'm not sure I see a bug in the provided php file; it seems to be behaving as I would expect it to. Could you verify that you've uploaded the correct attachment?

comment:3 Changed 3 years ago by rwaldron

Additionally, this is calling "jquery-1.4a2.min.js"

comment:4 Changed 3 years ago by snover

  • Status changed from new to closed
  • Resolution set to worksforme

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.