Hi, I've created a javascript bookmarklet that gets the current page's title and URL, using the following code:
//Check to see if jQuery is already loaded
if (typeof jQuery == 'undefined') {
var jQ = document.createElement('script');
jQ.type = 'text/javascript';
jQ.onload=runthis;
jQ.src = 'http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js';
document.body.appendChild(jQ);
} else {
runthis();
}
// main Javascript function
function runthis() {
title = document.title;
url = document.URL;
tag = "customTag";
alert("Added to paperclip: Page Title: "+title+" | URL: "+url);
}
I now want to take that info and add it as a bookmark on my Delicious account. How do I go about this with Javascript/jQuery? I've taken a look at the API documentation but am having trouble getting my head around it (completely new to this, and OAuth makes my head spin), and can't find any full code examples to tinker with.
Would really appreciate any help/examples.