transparencia Posted December 14, 2009 Share Posted December 14, 2009 I'm having some problems with this code: echo ' <A HREF="javascript:void(0)" onclick="window.open('http://website.net/community/xspf_player.swf?playlist_url=http://website.net/community/playlist.php?u=',$message['member']['id'],'')"> Open a new window</A>'; Can anybody help formatting this right? Link to comment https://forums.phpfreaks.com/topic/185025-help-with-echo/ Share on other sites More sharing options...
Buddski Posted December 14, 2009 Share Posted December 14, 2009 <?php echo ' <A HREF="javascript:void(0)" onclick="window.open(\'http://website.net/community/xspf_player.swf?playlist_url=http://website.net/community/playlist.php?u='.$message['member']['id'].'\');"> Open a new window</A>'; ?> Link to comment https://forums.phpfreaks.com/topic/185025-help-with-echo/#findComment-976676 Share on other sites More sharing options...
teamatomic Posted December 14, 2009 Share Posted December 14, 2009 if you enclose it with single quotes you must escape any single quotes within it. If you enclose it in double quotes you must escape any double quotes within it. all these are valid echo " she said, \"yes\" "; echo ' she said, don\'t '; echo "she said, 'yes' "; echo "she said, don't "; HTH Teamatomic Link to comment https://forums.phpfreaks.com/topic/185025-help-with-echo/#findComment-976683 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.