Category: ‘Geeky Stuff’

:grin:

About Yoghurts

© Bonkers World

+2 more (duh)..
Read more »

Бгыгы!!1 :giggle:


800×528

© Galit Weisberg

:mrgreen:

“Yeah? Well at least I don’t Alt+Tab through three guys a week!”
“Yeah? Well I’m going to Shift+Del you from my life!”

© Something of That Ilk

:giggle:

A pretty cool commercial for Calgary-based photographic retailer The Camera Store.

via GeeksAreSexy

:giggle:

© unknown

Буагага!!1 :giggle:


900×810

© Downright Average


900×1022

© Downright Average

Хмм.. :grin2:

Playboy has launched a naughty Tron-inspired editorial entitled “Game On“, starring Irina Voronina and Sasckya Porto.


1600×1066

+3 more…
Read more »

Artist Paul Destieu recreated a common Windows error using 500 copies of his “My Favourite Landscape” print. It’s like that rare mesmerizing calm that I feel after winning a game of Solitaire.


via Buzzfeed.com

Переводить не буду, т.к. в основном это как памятка для себя… :smoking:

There are a lot of tutorials available for editing the quicktags.js file in the WordPress wp-includes folder, but they all seem to want you to edit the file directly. That’s a Bad Idea because the next time you upgrade, your changes are kaput. [...] There are some perfectly capable plugins for adding new buttons, too. [...]

The quicktags.js file

1. Go into the /wp-includes/js folder and find quicktags.dev.js. Copy it to your template folder (or any subfolder) and rename it quicktags.js.

2. Edit the file. The code has some localization in it which we’re about to break, so search for quicktagsL10n and replace every instance with an appropriate, quoted string.

For example:
prompt(quicktagsL10n.enterURL, defaultValue);

Should be something like:
prompt('Enter the URL', defaultValue);

Overriding the original

Now we just need to change which script gets called when you’re in the post editor. Add the following to your theme’s functions.php file:

function bt_load_admin_scripts() {
  if ( is_admin() ) {
    wp_deregister_script('quicktags');
    wp_register_script('quicktags', ("/path/to/your/quicktags.js"), false, '', true);
  }
}
if (is_admin()) {
  add_action('init', bt_load_admin_scripts);
}

Modify the path in wp_register_script to point to the location where you put your quicktags.js file. This will tell WordPress to load your file instead of its own.

Now, edit a new post (in the HTML editor, not the Visual editor) to test out your changes. If everything is correct, modified and new buttons should show up and function the way you want. Your changes will persist, even after a WordPress upgrade!

© BrettTerpstra.com

Comment and Win a Userpic!

Recommended Stuff

This is a random selection from a list of stuff/posts I personally enjoyed a lot. Some sort of "My Favorites" or "Bookmarks"...

  • Apnea
  • George Carlin – Carlin on Campus
  • Andie Muise
  • SNL – Harry Potter Parody
Bookmark and Share