Adsense
Translate it to ur language
Monday, May 24, 2010
Sunday, May 23, 2010
Simple Hook Tutorial
Hooks are one of the main building blocks of WordPress plug-ins. Almost every plug-in uses a hook to overwrite WordPress’ core functionality.
How to Use Hooks on Your WordPress Blog
Unless you’re writing a plug-in, you would write hooks in the functions.php file. This file is located in the wp-content/themes/yourtheme directory.
A hook, as you would expect, “hooks” one function to another. For example, you could write a custom function and attach it to one of WordPress’ core functions:
I will tell u a simple hook to understand the process:
Let whenever a post is done a mail alert should be sent to a mail:
first we need to name our function let it be mailalert
function mailalert()
{
mail('tamojyoti.bose@gmail.com','You got a post', 'Hello I am from ur blog we received a new post ');
}
add_action('publish_post','mailalert');
now what this thing did :
we all come across simple mail fn of php which i used to just drop a mail to me when a post is done.
add action is just hooking up core function publish_post with my one just created
Please comment:) This is my first writing so please pardon me if i m wrong
Friday, May 21, 2010
Blog protector
Features:
* Disable right click on your blog
* Disable selection of text on your blog
* Disable dragging of images on your blog so that images can’t be saved using.
* Disable Microsoft Image Toolbar to protect images from your blog.
Plugin url: http://wordpress.org/extend/plugins/blog-protector/
Thursday, May 20, 2010
Saturday, May 15, 2010
Best On WordPress From The Past Week N.5
Sent to you by Tamo, TJ, Tom, Bose via Google Reader:
All of these were tweeted on our twitter account during the past week, so don't forget to follow wpCanyon on twitter for awesome wordpress related links.
USING WORDPRESS "AS A CMS"
Joomla And WordPress: A Matter Of Mental Models
Working With MultiSite In WordPress 3.0
Quick Tip: A 4 Minute Crash-Course in WordPress Custom Fields
Add Private Content to Posts via Shortcode
Build a WordPress Plugin to Add Author Biographies to your Posts
8 Incredible Wordpress Plugins
Use More Flexibility In WordPress Templates
40 More Stylish, Minimal and Clean Free Wordpress Themes
Things you can do from here:
- Subscribe to wpCanyon using Google Reader
- Get started using Google Reader to easily keep up with all your favorite sites
Monday, May 10, 2010
10 sites developers should have in their bookmarks
Sent to you by Tamo, TJ, Tom, Bose via Google Reader:
Mysql Format Date
MySQL Format Date helps you to format your dates using the MySQL DATE_FORMAT function. Just select a common date format and then change it to your suit your needs. The MySQL DATE_FORMAT code will be generated at the bottom of the page which you can then copy into your query.
Visit site: http://www.mysqlformatdate.com
Script Src
Are you tired of hunting the Internet in order to find the script tag for the latest version of the Javascript library of your choice? ScriptSrc.net has compiled all the latest versions of jQuery, Mootools, Prototype and more in a single page which lets you copy it in your browser clipboard with a single click.
Visit site: http://scriptsrc.net
Em Chart
I never been a fan of ems in CSS files, but sometimes you have to deal with it. In that case, Em chart will translate ems to pixels so you'll save time and hassle.
Visit site: http://aloestudios.com/tools/emchart
Twitter API Explorer
If you're using the Twitter API in the site you build, you'll for sure enjoy this very handy website which allow you to search through the Twitter API. Even better, the website can generate ready-to-use code snippets. A real time gain for you and your clients!
Visit site: http://twitapi.com/explore
Browser Sandbox
Cross browser compatibility is definitely one of the biggest problems a web developer has to face in his daily job. The browser sandbox lets you run any Windows browser from the web. The only bad thing is that you must run a Windows machine: The app does not work on Macs and GNU/Linux.
Visit site: http://spoon.net/browsers
PHP Forms
Web forms are one of the most important part of a website, but creating them is also very time-consuming. So, what about using a website that can speed up your form development for free?
PHP forms allows you to create advanced forms that can fit the needs of most websites.
Visit site: http://www.phpform.org
.htaccess editor
A .htaccess file is a must have for any website. Don't know how to write one? No problem, just visit this site to create your .htaccess file using a wizard. It doesn't allow very advanced stuff, but the results are great for 95% of the websites you'll make.
Visit site: http://www.htaccesseditor.com/en.shtml
Smush it!
Images may be worth a thousand words, they're also well known to use a lot of bandwidth. Images can be optimized for the web using programs like Photoshop; but if you don't own a copy of this software or simply don't have a clue how to do it, smush.it is what you need.
Brought to you by Yahoo developers network, Smush.it is an online tool that will reduce your image size without reducing their quality. For WordPress users, a very handy plugin for your favorite blogging engine is available here.
Visit site: http://developer.yahoo.com/yslow/smushit/
CSS Compressor
Especially on site with many different page layouts, CSS files can become huge and use a lot of server bandwidth. This tool, named CSS Compressor, can consequently reduce the size of any CSS file by removing comments, indentation and more.
Even better, compression level can be configured to fit your needs.
Visit site: http://www.csscompressor.com
Test everything
This site is a definitive must-have for your bookmarks: As the name says, Test everything allows you to test lot of things such as XHTML and CSS markup, PageRank, back-links, and a lot more.
Visit site: http://tester.jonasjohn.de
Like CatsWhoCode? If yes, don't hesitate to check my other blog CatsWhoBlog: It's all about blogging!
10 sites developers should have in their bookmarks
Things you can do from here:
- Subscribe to CatsWhoCode.com using Google Reader
- Get started using Google Reader to easily keep up with all your favorite sites