Can this be done, yes.
If you must use Javascript:
step 1 - find yourself a javascript cookies library you are happy with.
step 2 - use the "getCookieValue(cookiekey)" function (it will be named differently) from the library like this:
Code:
var orderNumber = getCookieValue('orderno');
var orderValue = getCookieValue('gtotal');
Hopefully you can place an ID onto that image, so that the image is like:
Code:
<img id='Booyah' src="https://www.twistoflemon.co.za/report?orderNumber=orderno&orderValue=gtotal">
Then you update the image's source, like this:
Code:
document.getElementById('Booyah').src = 'https://www.twistoflemon.co.za/report?orderNumber=' + orderNumber + '&orderValue=' + orderValue ;
Bookmarks