I've tried to insert Javascript code to a src tag from an img, the code looks like:
<img id="p1" width="90%" height="100%" src="javascript:img_info();" />
So basically it gets an image out of an API since the function img_info(); generates a link. The problem is that when i run this code it doesn't return anything, any ideas?