WordPress › WordPress Plugins

Popular »

Newest Plugins »

Recently Updated »

WordPress Plugins

Popular WordPress  Plugins

BuddyPress

Social networking in a box. Build a social network for your company, school, sports team or niche community all based on the power and flexibility of

WordPress  Plugins

wp-seatingchart

Create a seating layout using tables, chairs, restroom locations and trash recepticles via a drag-n-drop interface. Allow users to reserve a seat.

Recently Updated WordPress  Plugins

Xhanch – My Quote

Xhanch – My Quote shows a random quote with provided predefined quotes or your own collections.

How to add sidebar(s) to a WordPress Theme | Blog Oh Blog

Adding Extra Sidebar to your WordPress Theme

You like a WordPress theme on the Internet but Oh!… What’s this?? The theme has only one sidebar! You need more than one and are on the verge of switching to some other theme with more sidebars. But wait!! Let me teach you how to add an extra sidebar or sidebars to your favorite theme. People who know PHP will find it easy to follow but even novices can easily do it using the code that I have provided in this tutorial. I am assuming that you already know HTML and a bit of CSS.

Working Hard!To begin the tutorial, extract your theme into a folder and open it to see all the files. If your theme has only one sidebar, then most probably you will NOT find a file called functions.php in your theme folder. In that case you will have to create this file yourself. Just open notepad or any other code editor to start a new file. Put this code into that file :-
<?php
if ( function_exists('register_sidebars') )
register_sidebars(2);
?>

Save the file as functions.php and put it in your theme folder. This piece of code actually tells WordPress to register two sidebars for you (See register_sidebars(2) in the code). If your theme has more than one sidebar, you will find the functions.php file already present in your theme folder. You just have to edit the number to your requirement and save the file. You can increase this number if you want more sidebars and if your theme’s layout can accommodate it. Now, when you go to your WordPress admin section and browse to the widgets under the menu item called presentation, you will see two sidebars listed there. You can drag your widget items into any of the sidebars.

Now comes the part where we actually build the sidebars. If your theme has only one sidebar, try to locate a file called sidebar.php in your theme folder. In this example, where we are trying to modify the theme for two sidebars, let’s rename sidebar.php to sidebar1.php and make a new blank file called sidebar2.php. Put this code into sidebar2.php and save the file :-
<div>
<ul>
<?php if ( function_exists('dynamic_sidebar') && dynamic_sidebar(2) ) : else : ?>
<?php endif; ?>
</ul>
</div>

So, we have the two sidebars ready but they have not been placed in the index.php file yet. Both these sidebars need to be called from the index.php file in order to include them in your theme. Just open the index.php file from your theme folder and locate the code that calls your sidebar file (sidebar.php earlier). It should look something like :-

<?php include (TEMPLATEPATH . '/sidebar.php'); ?>

Edit this code and change the words sidebar.php to sidebar1.php.

Here you go!This takes care of the first sidebar. Now take a look at the index.php file carefully and find a suitable place to insert the second sidebar. This might involve modifying your layout or adding new divs. Once you find a suitable place, place the following code there :-

<?php include (TEMPLATEPATH . '/sidebar2.php'); ?>

via How to add sidebar(s) to a WordPress Theme | Blog Oh Blog.

Using Permalinks « WordPress Codex

Using Permalinks

/%category%/%postname%/

Structure Tags

You can use these tags to customize your “Pretty” or “Almost Pretty” permalinks. A few hints:

  • Make sure to end your structure with either %post_id% or %postname% (e.g. /%year%/%monthnum%/%day%/%postname%/) so that each permalink points to an individual post.
  • For performance reasons, it is not a good idea to start your permalink structure with the category, tag, author, or postname fields. The reason is that these are text fields, and using them at the beginning of your permalink structure it takes more time for WordPress to distinguish your Post URLs from Page URLs (which always use the text “page slug” as the URL), and to compensate, WordPress stores a lot of extra information in its database (so much that sites with lots of Pages have experienced difficulties). So, it is best to start your permalink structure with a numeric field, such as the year or post ID. See wp-testers discussion of this topic.
%year%
The year of the post, four digits, for example 2004
%monthnum%
Month of the year, for example 05
%day%
Day of the month, for example 28
%hour%
Hour of the day, for example 15
%minute%
Minute of the hour, for example 43
%second%
Second of the minute, for example 33
%postname%
A sanitized version of the title of the post (post slug field on Edit Post/Page panel). So “This Is A Great Post!” becomes this-is-a-great-post in the URI (see Using only %postname%). Starting Permalinks with %postname% is strongly not recommended for performance reasons.. *** Note – this has been changed and is ok to do since ver. 2.0
%post_id%
The unique ID # of the post, for example 423
%category%
A sanitized version of the category name (category slug field on New/Edit Category panel). Nested sub-categories appear as nested directories in the URI. Starting Permalinks with %category% is strongly not recommended for performance reasons.
%tag%
A sanitized version of the tag name (tag slug field on New/Edit Tag panel). Starting Permalinks with %tag% is strongly not recommended for performance reasons.
%author%
A sanitized version of the author name.

Category base and Tag base

The Category base and Tag base are prefixes used in URLs for category and tag archives, which look like this:

 example.net/wp/category_base/category_name
 example.net/wp/tag_base/tag_name

The default values for these are category and tag. You can change them, but you can’t remove them from the URLs altogether.

Custom permalinks work on most systems without any problems, but there are still some conditions where problems occur.

Using %category% with multiple categories on a post, or %tag%

When you assign multiple categories to a post, only one can show up in the permalink. This will be the lowest numbered category (see Manage Categories). The post will still be accessible through all the categories as normal.

The same thing applies to using the %tag% field in your permalink structure.

Using “Pretty” permalinks

Requirements:

  • Apache web server with the mod_rewrite module installed
  • In WordPress’s home directory,
    • The FollowSymLinks option enabled
    • FileInfo directives allowed (e.g. AllowOverride FileInfo or AllowOverride All)
    • An .htaccess file (if this file is missing, WordPress will try to create it when you activate “pretty” permalinks)
    • If you want WordPress to update the .htaccess file automatically, WordPress will need write access to the file.

When you create or update a “pretty” permalink structure, WordPress will generate rewrite rules and attempt to insert them into the proper .htaccess file. If it can’t, it will say something like You should update your .htaccess now and print out the rules for you to copy and paste into the file (put them at the end).

In WordPress 2.0+ versions, you’ll probably need to do this only once, because WordPress does the rewriting internally. If you ever move your WordPress home directory (Blog address), you’ll need to repeat this step.

WordPress will play nice with an existing .htaccess and will not delete any existing RewriteRules or other directives. If you have other mod_rewrite rules, put yours before WordPress’s.

Where’s my .htaccess file?

WordPress’s index.php and .htaccess files should be together in the directory indicated by the Blog address (URI) setting on your General Options page. Since the name of the file begins with a dot, the file may not be visible through an FTP client unless you change the preferences of the FTP tool to show all files, including the hidden files. Some hosts (e.g. Godaddy) may not show or allow you to edit .htaccess if you install WordPress through the Godaddy Hosting Connection installation.

Creating and editing (.htaccess)

If you do not already have a .htaccess file, create one. If you have shell or ssh access to the server, a simple touch .htaccess command will create the file. If you are using FTP to transfer files, create a file on your local computer, call it 1.htaccess, upload it to the root of your WordPress folder, and then rename it to .htaccess.

You can edit the .htaccess file by FTP, shell, or (possibly) your host’s control panel.

If your .htaccess file contains errors that bring down your site (“Internal Server Error (500)”), you will need to use FTP or your host’s control panel to delete the rogue .htaccess file.

Automatically updating .htaccess

If WordPress can’t update your .htaccess file automatically, it will tell you something like If your .htaccess file were writable, we could do this automatically, but it isn’t… near the bottom of the Settings → Permalinks panel.

If you want to let WordPress do this, you’ll need to give WordPress write access to the .htaccess file. The exact permissions necessary depend on your server setup. Try adding write permissions for the owner, then group, then world, testing after each change; once WordPress has edited the file successfully, don’t add any further write permissions.

After applying the permalinks, you should change the permissions to something stronger like 660 or 644 to prevent others on the server from potentially having access to it.

Permalinks without mod_rewrite

“Pretty” permalinks usually require mod_rewrite, and IIS (common on Windows servers) does not support mod_rewrite. (If you are using Apache 2.0.54, on Windows, mod_rewrite may work, provided it is enabled in apacheconfhttpd.conf.)

If you are using IIS 7 and have admin rights on your server, you can use Microsoft’s URL Rewrite Module instead. Though not completely compatible with mod_rewrite, it does support WordPress’s pretty permalinks. Once installed, open the web.config file in the WordPress folder and add the following rule to the system.webServer element

<rewrite>
    <rules>
        <rule name="Main Rule" stopProcessing="true">
            <match url=".*" />
            <conditions logicalGrouping="MatchAll">
                <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
                <add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
            </conditions>
            <action type="Rewrite" url="index.php/{R:0}" />
        </rule>
    </rules>
</rewrite>

There’s a full installation guide on the IIS site. The module is available for x64 and x86 systems.

If this isn’t an option, you can try PATHINFO permalinks; put index.php/ at the start of your custom permalink structure:

 /index.php/%year%/%monthnum%/%day%/%postname%/

This option may not always work, especially in cases of WordPress running on IIS 6. To make this option work on IIS, add these 2 lines to a php.ini file and store that file in your webroot (http://blog.taragana.com/index.php/archive/wordpress-tip-on-permalink-options):

via Using Permalinks « WordPress Codex.

google maps & iframes in WordPress pages/posts

Include It.

I tried this and got it working for a iframe google map after:
1]installing the plugin
2]adding [include file=location.htm iframe=true width=550 height=310] in the page, [visual view]
3] added location.htm in root directory & in the loaction.htm is:
<iframe width=”540″ height=”300″ frameborder=”0″ scrolling=”no” marginheight=”0″ marginwidth=”0″ src=”http://maps.google.com/maps/……………”></iframe>

simple as that
Ps Thanks to the developer.:}
http://www.satollo.com/english/wordpress/include-it

Download

The plugin is availiable on WordPress Plugins Repository on this page. Sorry to all people who kindly claimed for not finding a download link.

WordPress › hidden subCategories in wordpress

Folding Category List (FoCaL)

  • Requires WordPress Version: 2.3.0 or higher
  • Compatible up to: 2.9.2
  • Main Features

  • Very few SQL queries so it does not put strain on server (except when post count is enabled)
  • Option to cache navigation structure to further reduce server load
  • Very fast (typically < 0.025 seconds) to generate category tree, even with many categories
  • Priority based category selection where multiple categories are available (e.g. single post view)
  • Pages can expand category navigation
  • Full configuration via administration screens
  • Add static links to the list
  • Control category order by name, id, description, post count or use with “My Category Order” plugin for total control

Download

via WordPress › Folding Category List (FoCaL) « WordPress Plugins.