Posts Tagged ‘hack’

google week: 101 tips, tricks and hacks

Wednesday, September 3rd, 2008

The ultimate collection of Google tips

1. The best way to begin searching harder with Google is by clicking the Advanced Search link.

2. This lets you search for exact phrases, “all these words”, or one of the specified keywords by entering search terms into the appropriate box.

3. You can also define how many results you want on the page, what language and what file type you’re looking for, all with menus.

4. Advanced Search lets you type in a Top Level Domain (like .co.uk) in the “Search within site of domain” box to restrict results.

5. And you can click the “Date, usage rights, numeric range and more” link to access more advanced features.

(more…)

wordpress: post category style

Thursday, August 28th, 2008

how to style main page posts by category.

have no time to do a full length pseudo-geeky post now now, but will expand on it after i’ve tested it out. :)

from codex

update: whoops. those two links seem to be for category styling as opposed to having posts from different categories appear differently on the home page.

these two seem to be more of what i’m looking for. Styling Posts by Category and Category-Specific Images, using wordpress categories to style posts

much more complicated too. ;p

wordpress: exclude categories from main page

Tuesday, August 26th, 2008

to exclude certain categories from the main page of your blog (assuming you’re like the other 99% non-freaks who use blog posts not a static page as your main page) like how i’m not cluttering my posts with my baju category aka category 23 and instead forcing voyeuristic casual surfers with ephebephilic tendencies to click on a navigational link in my interesting footer

deep breath

in the earlier layout, i used wordpress’ built-in Query_posts, placing following syntax into the index.php file of my theme. (whitespace makes no difference.)

<?php
   if (is_home()) {
      query_posts("cat=-23");
   }
?>

but for some reason, this method didn’t work with derek powazek’s awesome minimalist DePo skinny theme (which, if you hadn’t noticed, i’m currently loving).

so, i googled this trick. just pop in

<?php query_posts($query_string . “&cat=-23″); ?>

before the line that says:

< ?php if (have_posts()) : ?>

ta-dah! done.additional: for hemingway reloaded template, insert &cat=-23 into existing query like so

<?php query_posts(’showposts=10&cat=-23‘); ?>

wordpress comments off

Saturday, August 16th, 2008

when you turn off comments for individual posts, the nasty “comments off” text is shown, giving everyone the impression that you’re a antisocial ogre. then they get mad.

also, when you google for help on how to remove this “comments off” you get smart alecky answers on how to entirely remove the option of commenting from your blog. leaving your millions of fans without a voice (or trolls without any dinner).

so, intermediate users can head down to your server and edit the file in wordpress root > wp-includes > comment-template.php

find and delete bolded text as follows:

$more = ‘% Comments’, $css_class = ”, $none = ‘Comments Off‘ )

if you don’t believe me, i got it from the codex

Line 720 of wp-icludes/comment-template.php has the words ‘Comments Off’ as the value of the variable $none (in the comments_popup_link function)