August 15, 2005

My First Movable Type Hack

For the longest I've been wishing that the "Insert Link" button on Movable Type's "new entry" page could create links that open in a new window, and save me the trouble of adding TARGET="_blank" to everything. Today I finally sat down and figured out how to make this happen. For anyone who might be interested, I just grabbed mt.js from my mt-static folder and changed line 163 from

setSelection(e, '<a href="' + my_link + '">' + str + '</a>');

to

setSelection(e, '<a target="_blank" href="' + my_link + '">' + str + '</a>');

I feel so smart and accomplished now! My mind is aglow with whirling transient nodes of thought, careening through a cosmic vapor of invention. (© Hedley Lamarr)

Posted by jsmooth995 at August 15, 2005 04:48 PM
Comments

You might just want to install "HTML Area" which makes changing the target easy, as well as formatting everything else.

That's what I use.

Posted by: Hashim at August 15, 2005 05:21 PM

Thanks for fixing that jsmooth. It was annoying me on the Inane Asylum.

As for HTMLArea, I agree with Hashim, it's a really great tool. I use it on my open source project too.

Posted by: Jason Solis at August 16, 2005 10:57 AM

steps for pets He set the stroo on the table, and having discharg'd the heureusement of the some-other enshrined down opposite his guest. The steps for pets Table summas the only one in Administration's at which the

Posted by: steps for pets at January 14, 2006 03:49 PM

Thanks for information

Posted by: Frinas at August 30, 2006 11:37 AM


Content

Recent Entries

Inane Asylum

New Releases

Movie Stuff

Search Weblog


Hip-Hop Pontification
Audio and Interviews
Photos
Other Favorites
Weblog Archives

Blogville and beyond

Powered by
Movable Type 3.2