Closed GoogleCodeExporter closed 8 years ago
To avoid having the workaround AJAX library dependencies, perhaps the more
generic
solution to to somehow be able to pass an addition <object> attribute (such as
onClick):
{{{
$AE->addObjectAttribute('onclick'=>"alert('hi')");
}}}
Original comment by jhi...@gmail.com
on 11 Feb 2009 at 11:01
Original comment by phpu...@gmail.com
on 12 Feb 2009 at 2:22
Original comment by phpu...@gmail.com
on 12 Feb 2009 at 3:18
added setObjectAttrib.
Will be in release 1.3
Original comment by phpu...@gmail.com
on 13 Feb 2009 at 9:03
I've discovered that the below can work _without the need to have AE handle the
extra
attribute_:
Wrap the embed output in a div with a class name
{{{
<div class="embedded"><?=$AE->getEmbedCode();?></div>
}}}
Then use Javascript to observe any clicks to the embedded object:
{{{
$$('div.embedded').each(function(e) {
e.firstDescendant().observe('click', function() {
alert('This video has been clicked.');
});
});
}}}
Original comment by jhi...@gmail.com
on 20 Feb 2009 at 6:51
oh nice... I think this is still a useful feature. It could be used to add a
css
class to the embedded object or give it a specific id for manipulation via
javascript..
and it makes the code look nicer ;)
Original comment by phpu...@gmail.com
on 20 Feb 2009 at 5:05
Original comment by jhi...@gmail.com
on 19 Aug 2009 at 4:22
Original issue reported on code.google.com by
jhi...@gmail.com
on 11 Feb 2009 at 10:51