My favorites | Sign in
Project Home Downloads Issues
READ-ONLY: This project has been archived. For more information see this post.
Search
for
  Advanced search   Search tips   Subscriptions
Issue 268: Using append function to write a nyroModal link doesn't work
2 people starred this issue and may be notified of changes. Back to list
Status:  Invalid
Owner:  ----
Closed:  Jun 2009


 
Reported by bwaymark...@gmail.com, Jun 22, 2009
What steps will reproduce the problem?
1. Create a function that will write a link:
<script type="text/javascript">
$(document).ready(function() {
	$('#ben').append("<a href=\"test\" class=\"nyroModal\">This one is
generated with jquery and doesn't work</a>");
});
</script>
2. Click on the link that has been generated, nyroModal doesn't work
(executes as normal link)
3. See http://www.clickcreations.com/example.html for a sample script

What is the expected output? What do you see instead?

Instead of opening a nyroModal, link is being exectured

What version of the product are you using? On what operating system?

jQuery JavaScript Library v1.3.1
nyroModal $version: 1.5.0
Apache2 server w/ php5 on Debian
Firefox 3.0.11
Internet Explorer 8.0.6001.18702

Jun 23, 2009
Project Member #1 nyro...@gmail.com
of course it doesn't work.
Nyromodal parse the DOM once the page is loaded.
At this time, your link isn't already in the DOM, so it won't be parsed and processed.
to fixe it, just add $('#ben a.nyroModal').nyroModal() after adding it to your page
and it'll works great.
Status: Invalid
Jun 23, 2009
#2 bwaymark...@gmail.com
Ah-ha!  That makes sense.  Thanks for clarifying.

Powered by Google Project Hosting