send variable fancybox onclick event

Posted by samuel saul on Stack Overflow See other posts from Stack Overflow or by samuel saul
Published on 2010-04-27T01:30:21Z Indexed on 2010/04/27 1:33 UTC
Read the original article Hit count: 911

Filed under:
|
|

hi,

i want to send href value. but its not working.

function display () {
$.fancybox({
'href': 'index.php',
'width'    : '75%',
'height'   : '75%',
'autoScale'   : false,
'transitionIn'  : 'none',
'transitionOut'  : 'none',
'type'    : 'iframe'

 });

}

i tryed this :

function display (who) {
$.fancybox({
'href': 'index.php'+who,
'width'    : '75%',
'height'   : '75%',
'autoScale'   : false,
'transitionIn'  : 'none',
'transitionOut'  : 'none',
'type'    : 'iframe'

 });
}

<a onclick="javascript:display("?id=11");" href="#"  >create</a>

this onclick event inside the innerhtml so its not working with ''

why

© Stack Overflow or respective owner

Related posts about jQuery

Related posts about fancybox