941-685-8851

March, 2010

WordPress Blogroll import – export

The ability to import existing blogroll links from one Wordrpess website  into another could be a big timesaver. Manually recreating Blogroll links in Wordrpess can be a tiresome task, especially if you have many links. Fortunately, WordPress has an easy way to automate this task.

First, export the links:

OPML (Outline Processor Markup Language) is an XML format for outlines. In wordpress, OPML is already created for you. You can access it using the below mentioned URL:

http://yourdomain.com/wp-links-opml.php

You can save this file for storage

Second, export the links:

Import the existing blogroll from the OPML URL or the file you saved to your local system.

1)     Login to your WordPress dashboard.

2)     Click on Tools>Import.

3)     Select Blogroll.

4)     Enter the OPML URL of your blog or select the file from your local system.

5)     Click on Import.

The Blogroll links have now imported to the new Wordrpess website

Share
 

Magento Left Callout Image

The Magento default left callout image has a link to checkout/cart and alt content of “Our customer service is available 24/7….”

To change this go to app/design/frontend/default/client/layout/catalog.xml.

Find the following block:

<reference name=”left”>
<block type=”core/template” name=”left.permanent.callout” template=”callouts/left_col.phtml”>
<action method=”setImgSrc”><src>images/media/col_left_callout.jpg</src></action>
<action method=”setImgAlt” translate=”alt” module=”catalog”><alt>Our customer service is available 24/7. Call us at (555) 555-0123.</alt></action>
<action method=”setLinkUrl”><url>checkout/cart</url></action>
</block>
</reference>

Change the aforementioned items as needed:

<reference name=”left”>
<block type=”core/template” name=”left.permanent.callout” template=”callouts/left_col.phtml”>
<action method=”setImgSrc”><src>images/media/col_left_callout.jpg</src></action>
<action method=”setImgAlt” translate=”alt” module=”catalog”><alt>Call us at 941-685-8851 or click here to email us.</alt></action>
<action method=”setLinkUrl”><url>contacts</url></action>
</block>
</reference>

Share
 

Magento: remove update notifications from admin

To disable Magento upgrade notifications from the admin, do as follow:

1) Remove from app/design/adminhtml/default/default/layout/main.xml two lines:

<block type="adminhtml/notification_window" name="notification_window" as="notification_window" acl="system/adminnotification/show_toolbar" template="notification/window.phtml" />

and

<block type="adminhtml/notification_toolbar" name="notification_toolbar" as="notification_toolbar" acl="system/adminnotification/show_toolbar" template="notification/toolbar.phtml"></block>

2) Change following code in app/etc/modules/Mage_All.xml

<Mage_AdminNotification>
<active>true</active>
<codePool>core</codePool>
<depends>
<Mage_Core />
</depends>
</Mage_AdminNotification>

into

<Mage_AdminNotification>
<active>false</active>
<codePool>core</codePool>
<depends>
<Mage_Core />
</depends>
</Mage_AdminNotification>
Magento update notifications should now be disabled. Tested in Magento 1.3.2.4
Share
 

Magento Setup Checklist

Magento Commerce is widely accepted as the world’s best shopping cart software. The steps involved in the initial setup of Magento can be elaborate. Here are some common procedures performed when installing and configuring a new Magento ecommerce website: read more…

Share
 

WordPress functions.php

Here is the default WordPress functions.php:

--------------------
<?php
/**
 * @package WordPress
 * @subpackage Default_Theme
 */

$content_width = 450;

automatic_feed_links();

if ( function_exists('register_sidebar') ) {
 register_sidebar(array(
 'before_widget' => '<li id="%1$s">',
 'after_widget' => '</li>',
 'before_title' => '<h2>',
 'after_title' => '</h2>',
 ));
}

 ?>
----------------

Here is a customized functions.php:

----------------

<?php
/**
 * @package WordPress
 * @subpackage Default_Theme
 */

$content_width = 650;

automatic_feed_links();

if ( function_exists('register_sidebar') ) {
 register_sidebar(array('name'=>right.'Right',
 'description'=>right.' The Right SideBar',
 'before_widget' => '<li id="%1$s">',
 'after_widget' => '</li>',
 'before_title' => '<h2>',
 'after_title' => '</h2>',
 ));
if ( function_exists('register_sidebar') ) {
 register_sidebar(array('name'=>left.'Left',
 'description'=>left.' The Left SideBar',
 'before_widget' => '<li id="%1$s">',
 'after_widget' => '</li>',
 'before_title' => '<h2>',
 'after_title' => '</h2>',
 ));
}

 ?>
------------------------
Share
 

Custom Options with *Optional in Title label

In Magento custom options, required fields are indicated by a red asterisk *. But what if the client requests that required fields are indicated by *Required , and unrequired fields are indicated by a *Optional?

Screen print of product options with * only on required fields:
Magento Custom Options asterisk required and optional

Screen print of product options with *Required on required fields and *Optional on unrequired fields:
Magento Custom Options asterisk required and optional

Edit the file:  app\design\frontend\default\client\template\catalog\product\view\options\type\select.phtml

On line 29 find this code:

 <?php if ($_option->getIsRequire()): ?><span>&nbsp;*</span>

and change it to this:

 <?php if ($_option->getIsRequire()): ?><span>&nbsp;*Required</span>

Now required select menus will be indicated by an asterisk and the word Required.

To specify the *Optional indicator for unrequired fields, add the following code right after the previous code:

<?php elseif ($_option): ?><span>&nbsp;*Optional</span>

Now unrequired select menus will be indicated by an asterisk and the word Optional.

Share