alexking.org

Main Navigation

  • Blog
  • Projects
  • Sports
  • About
  • Contact
Capsule

Capsule, The Developer’s Code Journal

I’m very pleased today to announce the release of Capsule, the developer’s code journal. Capsule replaces the scratch document you have…

Read More
Game Tonight: Yes

GameTonight for Status Board

GameTonight now creates a module for Panic’s excellent Status Board iPad app. The URL is simple, add ‘/statusboard’ to any metro…

Read More
threads-timeline

Announcing Threads

I’ve just released an initial beta of Threads, a WordPress plugin I’ve been working on for about a year. The idea is simple: show posts…

Read More

JS Quicktags Under LGPL

June 3, 2004

I’ve released my JavaScript Quicktags under the LGPL license as planned. This means that anyone (open source projects, closed source, commercial, etc.) can use them.

Here is an example page so you can see how they work, and here is the download.

69 Replies

Categories Development

  • 69 Replies
  • 55 Comments
  • 0 Tweets
  • 0 Facebook
  • 7 Pingbacks
Last reply was November 23, 2009
  1. Geof
    View June 3, 2004

    Any chance you’d add acronym to that? ;)

  2. Alex
    View June 3, 2004

    I think you’re capable of copying the 5 lines to add it. :)

  3. Christian
    View June 3, 2004

    Well, I just had a look at it and I wondered where the difference between the new js and the phpmyadmin function insertAtCursor() you posted on your site was. (Besides the fact that the new one looks much more difficult to understand, the output seems to be pretty similar to me.)
    Christian

  4. Alex
    View June 3, 2004

    There isn’t much difference, this is an implementation of it for HTML quicktags.

  5. Geof
    View June 3, 2004

    Alex: you are right, of course. But you know that someone had to start asking for features … might as well be someone whose ears you can box with abandon! ;)

  6. scriptygoddess.com
    View June 3, 2004

    Javascript Quick Tags (GPL)
    Matt posted a link to Alex’s javascript quick tags. I’ll need to update my “deCoder” javascript using that (if I can) – since Alex’s javascript DOES work with Firefox – and my (current) deCoder does not….

  7. Phil
    View June 4, 2004

    Is it me, or does the ‘cursor-awareness’ not function in Safari? Works lovely in Firefox.

  8. Alex
    View June 4, 2004

    Nope, they aren’t cursor aware in Safari and won’t be until Safari supports getting the cursor position in a textarea. This is actually noted in the comments at the top of the file.

  9. Andrew
    View June 6, 2004

    After finding your fantastic site while looking for WordPress hacks I came across this great post, which is just what I was in the middle of making for an intranet site. No point reinventing the wheel… Thanks! :D

  10. Alex
    View June 6, 2004

    Excellent!

  11. Tim
    View June 7, 2004

    Alex, thanks a a lot. I just integrated this with a cmsimple site I am working on, and it works like a charm.

    I wrote up instructions for other cmsimple users at http://www.cmsimple.[...]ic.php?t=869

  12. Jennifer
    View June 9, 2004

    Alex – I start to gloss over when I read the license text. I modified your code mostly to simplify it to the most “popular” tags people use in comments – that is: bold, italic, link. (I also added h3 since that’s what I use to stylize code on scriptygoddess). I’d like to offer the code for download with instructions on how to include it on wp-comments (obviously with credit to you for the script itself). Does the license allow me to do this?

  13. Alex
    View June 9, 2004

    The short answer is yes, you just need to abide by the rules in the license. See #2 in the license for more details of what you need to do (commenting your changes, etc.).

  14. evilabmonkey.org
    View June 21, 2004

    design notes, pt. 2
    welcome back to today’s last design notes. as you can easily see, nothing changed too drastically anymore. i’m very happy with the color scheme and the handling of the whole site. i really get along well with movable type. i…

  15. Mama Write's Sideblog
    View July 7, 2004

    Safari Friendly Buttons
    JS Quicktags Under LGPL – Safari-friendly buttons for WordPress…

  16. 99 shades of grey
    View August 18, 2004

    Customising Quicktags II
    A quick update to the Quicktag customisation : I just incorporated Scriptygoddess’ decodeIt function, which neatly translates ‘ into ‘>’. The original version of the function was IE-friendly only, however an update sees it working quite happ…

  17. alexking.org: Blog
    View September 6, 2004

    JavaScript Quicktags Updated
    I’ve updated the JavaScript Quicktags to version 1.1. This includes a small change that keeps Mozilla from jumping to the top of the textarea when a tag is inserted.

    Thanks to Chris Snell who did the research to find the Mozilla bug and submit th…

  18. Movable type resourses
    View September 29, 2004

    JS Quicktags Under LGPL

  19. CEIT
    View October 21, 2004

    Thank you!!!!!! This is cool!

  20. Julie
    View November 29, 2004

    Oh my gosh – I searched for so long to find a tutorial on how to do this. Imagine my joy to find your code. This is fantastic. More than fantastic. Thank you so much.

  21. Schoschie
    View January 21, 2005

    Thank you very much. I didn’t think this was possible, either. I knew insertion at the cursor was possible using proprietary JS extensions (?) in MSIE only, but not anywhere else. And now this. Very cool. On Mac OS X, the code works fine with Firefox and other Gecko-based browsers like Netscape 7.x. It does NOT apparently work in MSIE on OS X, however (text inserted at end only). Like you said, it does not work in Safari either, which is a pity since it’s my browser of choice, but anyway.

    I will probably add this to my “homebrew” blog software Blogoid and use it for some code patched into our University’s pinboards (http://www.uni-weimar.de/pinnwand/). Thanks again.

  22. ysu
    View February 9, 2005

    Nice script!
    a question: do you know of any way to achieve this cursor awareness in Opeara, or know it’s not possible at all?

  23. Alex
    View February 9, 2005

    Opera doesn’t support it. One more reason not to use Opera. ;)

  24. Carl
    View February 17, 2005

    Very nicely done!
    i’d tip my hat if i had one.

  25. Jonathan
    View March 13, 2005

    Just what I needed.
    Excellent bit of coding.

    Now where’s that tip jar…

  26. Alex
    View March 13, 2005

    Right over here. :)

  27. Lw
    View March 21, 2005

    Has anyone made quicktags work for 2 distinct textarea fields on the same page?

    Thank you Alex King….

  28. Eric J.
    View April 13, 2005

    decidedly cool. This is the closest to 1 to what I need for adding into aether. all I need now is to modify the tag definitions

    http://www.logarithm[...]ction=manual

    adding some sub tags would be interesting as well but given the fact that JavaScript is not easy to manipulate when 1) you don’t know it and 2) when you’re disabled and use speech recognition. speech recognition and programming in JavaScript just don’t get along.

    anyway, I will pick out the problem as fast as my hands permit.

    Alex, I’m hoping you will answer one question which is why don’t people put search/replace capability into these editors and why don’t they use keystroke commands for navigation/editing by character, word, sentence, paragraph (yes I’m an Emacs user) so that one can write speech recognition macros to let you navigate/edit by speech.

    by the way, I am speaking at a conference at the end of the month hosted by the open source speech recognition initiative and it would be wonderful to be able to dropping note to them on someone willing to support us (hint hint) :-)

  29. Rudolf
    View June 16, 2005

    Alex, this is fantastic, especially the JS quickstart! This saves me a lot of time. It took me 5 hours to get to half of this and it only worked in IExplorer. Tha

  30. alexking.org: Blog
    View July 1, 2005

    JavaScript Quicktags 1.2

    I’ve released a new version of my JavaScript Quicktags. I’ve been using this version for a while now, just hadn’t gotten around to packaging it up for release.

    This version has a changes:

    A few additional tags, including an “External Link…

  31. Dan Parnell
    View November 10, 2005

    Works just dandily in Opera 8.5, just FYI. I only skimmed the comments list, so you may have already said this.

    Saved me about an hour, since I hate writing JavaScript. Then again, perhaps this is not such a good thing, because I could have been paid for that hour of clicking around and looking silly. ;-)

  32. Karl Bishop
    View November 21, 2005

    Nice script!
    a question: do you know of any way to achieve this cursor awareness in Opeara, or know it’s not possible at all?

  33. Alex
    View November 21, 2005

    Please post support questions in the forum, not in the blog comments.

  34. Eric Tohanson
    View November 26, 2005

    Is it me, or does the ‘cursor-awareness’ not function in Safari? Works lovely in Firefox.

  35. Alex
    View November 26, 2005

    Perhaps you could read this page more carefully.

  36. Aslak
    View January 4, 2006

    Really, really nice, man. I’ve been looking all over for something like this. I love it :) . Thank you for doing this for us javascript analphabets.

  37. Helmut
    View January 17, 2006

    Is it me, or does the ‘cursor-awareness’ not function in Safari? Works lovely in Firefox.

  38. Dennis
    View January 24, 2006

    Nice work champ! – I’m using your brilliant script on my own website!

  39. eric
    View February 25, 2006

    Hey man, this thing is awesome. I was looking all over the place, and had almost settled on an overly large and annoying rich text editor, but a small script that I can use to mark up entries is all I need. Awesome man!

  40. cc
    View March 22, 2006

    Works fine in Safari 1.3. Thanks!

  41. Florian
    View April 5, 2006

    Great stuff! And it _does_ work in Opera (8.52 / Linux).
    Florian

  42. Tournesol
    View June 13, 2006

    Is it possible to change the buttons to graphics?

  43. Juglar :: Comentarios: la conversación de los bloggers :: March :: 2006
    View June 23, 2006

    [...] En mi blog comentan: Quicktags: Comando Javascript para crear un menú de botones que permitan a tus comentaristas incorporar fácilmente etiquetas HTML en sus comentarios. [...]

  44. 3stripe
    View June 24, 2006

    Looking good :)

    I’m going to try and impliment Quicktags as a plugin for the Vanilla forum I think….

  45. 3stripe » Blog Archive » My first extension… Quicktags for Vanilla
    View June 25, 2006

    [...] Having used the Quicktags on WordPress for quite some while, I figured they would make a good add-on for the Vanilla forum, as they allow you to quickly apply HTML formatting to the contents of any textarea. You can also use keyboard shortcuts to apply them, and easily add your own Quicktags, which is an added bonus. [...]

  46. Mark
    View July 26, 2006

    Good stuff! … just a quick note though that, at least with the sample page… in the Dict lookup, if you hit cancel when it pormpts you for a word, it still proceeded to lookup “null” on the dictionary website :)

    I have a knack for finding little bugs like this (if that’s in fact what it is). It’s the very first thing I clicked on that page.

  47. Alex
    View July 26, 2006

    Thanks. If that isn’t fixed in the current downloadable version I need to put out a more decent version. That was fixed a long while back.

    Please use the forums for future bug reports.

  48. Andy
    View August 30, 2006

    Coincidence!: I’ve just been trying to do this; remembered PHPadmin’s Query page; looked at the code; didn’t recognise the selectionStart property; didn’t find it in ‘JavaScript Bible’; did a Google search and there you are at number1!!
    So thanks Alex, for saving me hours of Javascript webcrawling.
    BTW, it works fine on Safari 1.3.2 on insertion AND replacement.

  49. Eliah
    View September 19, 2006

    Very useful code. And it works almost excellent in Opera 9, I tested it.

  50. mctk
    View October 17, 2006

    Stumbled across this. Just what I was looking for. Simple to implement. Thanks very much!

  51. Nicolas
    View December 13, 2006

    Thanks a lot Alex!

    This is just what i was trying to do for a website! I was looking for cursor position in textarea and I found your website! It works so good!

    Many thanks!

  52. Garth
    View January 26, 2007

    Alex, thanks so much for sharing this invaluable asset with us. I have spent several hours on and off over the last few months attempting to rectify the Mozilla problem, but to no avail. This is exactly the core code I need to build off of.

    Thanks so much for your willingness to share with the development community!

  53. Joey
    View February 13, 2007

    Wow what a big help. I had just finished writing my version with just basic tags, but this pretty much replaces that. I am thrilled to find this when I did.

  54. n3z
    View February 18, 2007

    Hi, please forgive me if I’m missing it, I really would love to use this plugin, but I can’t find your original documentation, and there is no readme file with the download. I’m happy to donate for it, but while I am a graphic designer and have built my entire blog and customized it, it is all at great pains and slowly and with much reading. I am no developer or code writer, and am just lokoing for basic instructions on how to install this (where to put it), if I need to tweak my config file, etc.

    Is there a document somewhere I am missing? I have searched your site and read many pages, so I am asking you last as I know how it is to be asked dumb questions by those not willing to expend effort.

    I am using MT 3.34.

    Thank you in advance for any help.

  55. Gareth
    View May 18, 2007

    Alex thanks for this script, it is exactly what we have been looking for.

  56. Mark
    View May 23, 2007

    Alex this is great, thanks. When I started searching for a way to find a cursor position I never thought I’d find something that did exactly what I was trying to achieve with very little development needed.
    I’ll add you a link on my new site when its up and running as you’ve saved me hours of work.
    cheers.

  57. (a different) Alex
    View June 17, 2007

    Thank you.

  58. Geoff
    View July 15, 2007

    Many thanks Alex,

    My two day search has eventually lead me to your door. This is a fantastic script. Imagine my suprise when I first clicked on the little arrow button at the end of the toolbar to reveal even more buttons :) Absolutely top notch work, even cross-browser compatible. I will be using this bit of essential code in an upcoming website of mine. Please let me know if there is anything I/We all can do to help make this code even better known (assuming you would like that;))

    Thanks again

    Geoff

  59. kb-one
    View August 22, 2007

    I am trying to figure out how to implement this. I am familiart with ASP, but totally clueless when it comes to JS. I have a textarea in a form and all I need is a button that will insert a line break at the cursor position. Can anyone help in posting code for this. Thank you very much JS GODS!!!

  60. NBA
    View September 20, 2007

    Thanks so much for your willingness to share with the development community!

  61. Dj Tiesto
    View September 20, 2007

    This is just what i was trying to do for a website! I was looking for cursor position in textarea and I found your website! It works so good!

    Many thanks!

  62. Alonzo Mourning
    View September 20, 2007

    Just what I needed.
    Excellent bit of coding.
    keep up the your great work.
    thank you.

  63. zichzach
    View April 16, 2008

    Thanks this great.

  64. Nuevas herramientas y apartados en el blog — WydBlog
    View August 12, 2008

    [...] que no están muy familiarizadas con el Html. [Demo: en el formulario de comentarios del blog] [Página Oficial] *Nota: Muy facil y rapido de instalar, “No hace falta wordpress”, en próximos post explicare [...]

  65. Rin - Broken Kode Test
    View August 26, 2008

    [...] buttons (code courtesy of Alex King) incorporated into the original [...]

  66. Manji - Broken Kode Test
    View August 28, 2008

    [...] buttons (code courtesy of Alex King) incorporated into the original [...]

  67. Manji - Broken Kode
    View December 1, 2008

    [...] buttons (code courtesy of Alex King) incorporated into the [...]

  68. Bene
    View June 23, 2009

    thanks, very useful!!!

  69. Broken Kode . No8 by Khaled Abou Alfa
    View November 23, 2009

    [...] buttons (code courtesy of Alex King) incorporated into the original [...]

Logging In...

Comments are closed.

June 3, 2004 » « Photos 4.1b1 released
wcsea-speakinggolf-swingsxswwcsfPhotographing Big Ben
prev next

Alex King, Web Developer

I live in Denver, CO where I founded Crowd Favorite. We enjoy building cool web stuff – especially with WordPress and Open Source.

I was an original contributor to WordPress, creator of ShareThis and the Share Icon.

You find me fascinating? Read more!

  • Twitter
  • Facebook
  • Instagram
  • GitHub
  • WordPress
  • Pinboard
  • Stellar
  • Untappd
  • Golfshot
  • LinkedIn
  • Crowd Favorite

Recent Blog Posts

  • Screeny Green Screen Revisited
  • 100 App.net Invites
  • Software is Like Legos
  • GameTonight, now with Event Times
  • Twitter vs. Feed Reading
  • Capsule Hotkeys and Background Queue
  • Awesome Web App/UI Designer Wanted (Contract)
  • GameTonight for Status Board
  • Capsule Reaction and My Usage
  • Capsule, The Developer’s Code Journal

Recent Threads

  • Passwords
  • Content Presentation
  • Social
  • Year in Review
  • Expectations

Archives

Categories

Powered by WordPress  ·  FavePersonal by Crowd Favorite

Copyright © 2002-2013 Alex King. All Rights Reserved.