pietbez Posted April 3, 2012 Share Posted April 3, 2012 Hi, can anybody please tell me how i can make "Arson" into a php variable <script type="text/javascript" src="js/swfobject.js"></script> <script type="text/javascript"> swfobject.embedSWF( "open-flash-chart.swf", "my_chart", "550", "400", "9.0.0", "expressInstall.swf", {"data-file":"ofc-chart.php?crime=Arson"} ); </script> Quote Link to comment Share on other sites More sharing options...
The Little Guy Posted April 3, 2012 Share Posted April 3, 2012 Like this: <?php $var = "Arson" ?> <script type="text/javascript" src="js/swfobject.js"></script> <script type="text/javascript"> swfobject.embedSWF( "open-flash-chart.swf", "my_chart", "550", "400", "9.0.0", "expressInstall.swf", {"data-file":"ofc-chart.php?crime=<?php echo $var; ?>"} ); </script> Quote Link to comment Share on other sites More sharing options...
pietbez Posted April 3, 2012 Author Share Posted April 3, 2012 thank you so much, that is exactly what i was looking for you saved me alot of pain Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.