Frage

I am placing the below inside document.write(). But its a third party function & the first param is the key and second is the value. I will be passing the value , so it cannot be inside document.write() . So how do I write it?

document.write('populateData("Number",shownum);');
War es hilfreich?

Lösung

If you're asking how to concatenate strings in Javascript, it would look like this, using the + operator:

document.write('populateData("Number", "' + shownum + '");');
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top