Monday, April 27th, 2009

CiteDrag: Cool library that groks the new drag and drop model

Category: HTML, JavaScript, Library

<p>Elijah Grey has a very cool new script CiteDrag that “adds automatically citation (ie. blockquotes, text quotes, ect.) to any dragged content off of the website which is using the script. CiteDrag requires no additional setup other than include the script somewhere on your website.”

I just dragged that above text from my blog post where announced the creation of CiteDrag and dropped it into my WordPress “Edit Page” interface, where automatically appeared quoted. Looking into the <blockquote> we can see that it even has the cite attribute defined. That is just one example of how CiteDrag works.

In a browser such as Firefox 3.5 beta (Shiretoku or a Firefox Nightly) go over to the test page and then start to drag the links, text, and image over to the text area.

Very cool work!

Related Content:

Posted by Dion Almaer at 8:21 am
5 Comments

++---
2.7 rating from 10 votes

5 Comments »

Comments feed TrackBack URI

You copypasted the <blockquote> literally where it is supposed to say “Looking into the <blockquote> we can see..”. Make sure to escape < and > with &lt; and &gt;

Comment by EliGrey — April 27, 2009

CiteDrag will also work in WebKit as soon as they fix bug 23695.

Comment by EliGrey — April 27, 2009

It seems to work in FF 3.0.9 as well, or am I missing some extra functionality available only with FF 3.5?

Comment by pmontrasio — April 28, 2009

EliGrey,

And if they ever intend to support richtext with any degree of flexibility, they’ll also need to fix 19893.

It appears from the demo that Firefox 3.5b may suffer from the same problem, as it treats images differently as part of your selection than as a single drop item.

Comment by eyelidlessness — April 28, 2009

lame

Comment by leptons — April 28, 2009

Leave a comment

You must be logged in to post a comment.