OCDProgrammer.com

It's Microsoft's World, and I'm just living in it
View Clarence Klopfstein's profile on LinkedIn

Clarence Klopfstein's Facebook profile

This site is under construction...

Categories

New Comments

Referring Sites


Disclaimer

  • This is MY blog. The views represented here are not in relation to anybody else. Please read my full disclaimer for a more complete disclaimer.

Quicker Links

- Discuss this Extension -

I have developed a new extension for the DNBE platform.  This feature will replace certain key words with a link to a site you specify.  I have named it "Quicker Links", and using it is rather easy.

After following the README.txt file in the zip file you will see a new option in the Extensions tab of your administrative secion.  You can click the Edit to add more settings to this extension.

Once you get into the Extension manager part of the site you can specify what words to replace.  A sample setting will look like this:

This works pretty easily, you enter the text you entered in the first text box and it will be made into a link.

So download it for yourself! 

QuickerLinks1.2.zip (3.68 kb) - Version 1.2 - January 3, 2007
- Version 1.2 works with the new Extension Manager that is in version 1.3 of the DotNetBlogEngion.

For Older Versions Scroll to the bottom of this page. 

Now I have tried to account for many different ways for this text to appear in HTML, but I'm sure it could use some improvement.  So if you have a code change let me know!  Here what the code should be able to replace in version one.  Lets assume that you have ckurl defined in your entry to be replaced with a link. 

  • If you just have it normally in a sentence, like above it will become a link. 
  • I also allow for certain punctuation to follow the word (!.,?:).
  • I check for a leading or trailing HTML bracket <, or >.  This is mainly if the word appears after a paragraph or line break.
  • I allow it if the word is followed by a space.  So lets say I have ckurl at the beginning of a sentence it will be replaced with a link.
    • NOTE: This introduced the only known bug.  If your word is in the end of a word it will break that word and give you a link.  For example if I have this wordckurl, the ckurl part of that will become a link.  Would love some better regular expressions for this, so I'm all ears.
  • One last note, I ignore case here.  So if you type cKuRl, it will make that word... just as it is a link.

Well I hope you enjoy!

Older Versions

QuickerLinks1.1.zip (6.61 kb) - Version 1.1 - December 15, 2007
- Version 1.1 has some tie into this extension.  If you use version 1.1 you should get the other extension as well.  But if you don't, clicking the redirect check box in the admin page will result in a javascript error on your page.  There are no functional differences in the core function of this extension between 1.0 and 1.1.

QuickerLinks.zip (6.01 kb) - Version 1.0 - December 1, 2007