javascript - Load own script on client's site -
I'm trying to create some kind of API in JavaScript. Basically, I want the client to include a script on my script and this script would load jquery, colorbox and execute a custom function, for now, will display a color box popup with a message. Of course, the script that the customer puts on their page will be hosted by me.
What does this script look like for all of the above?
something like
var p = document.createElement ('script '); Po.type = 'text / javascript'; Po.async = true; Po.src = 'Link to your script here'; Var s = document.getElementsByTagName ('script') [0]; S.parentNode.insertBefore (POS, S); to
Comments
Post a Comment