John Crumpton

Archive for the ‘code’ Category

My Blackberry pearl will only ring twice before going to voicemail. Which is never enough time to answer the call!

You can however adjust the amount of time (in seconds) that a number will ring if you dial the following code (press the green button then dial):

**61*901*11*25#

The last digits are the seconds before going to voicemail (25 seconds in this instance). The default is 15 seconds.

There are times when you want to hide Joomla’s breadcrumb, for example the homepage or search results.

In your template add the following where you want your breadcrumbs to appear:

<div id="breadcrumbs">
<?php
if ( ( $_REQUEST['option'] != "com_frontpage" ) and ( $_REQUEST['option'] != "com_search" ) and ( $_REQUEST['option'] != "com_xmap" ) ) { ?>
    <jdoc:include type="modules" name="breadcrumbs" />
     <?php } ?>
&nbsp;</div>

This hides the breadcrumb from the home page (com_frontpage) the search results (com_search) and the site map, in this case Xmap (com_xmap). Make sure your breadcrumb mobile appears in the “breadcrumb” module position.

To hide a specific page add:

 ( $_REQUEST['id'] != "8" )

Where 8 is the id of that page. You can also do this for a task as well as an option, just adjust $_REQUEST['option'] to $_REQUEST['task'].

If you use several templates on your Joomla site, such as a homepage template and a global template, you’ll know that the search results page irritatingly uses the homepage template and not your global template.

It is possible to change this by adding a hidden field to the search module, here’s how:

Within your homepage template folder create a new directory called “html” and then “mod_search”

Copy the “default.php” file from /modules/mod_search/tmpl/ into your newly created “mod_search” folder under your template folder.

Open this file at near the bottom just before the end of the form add:

 <input type="hidden" name="Itemid" value="2" />

The value refers to the menu item, we need to create a new hidden menu in the administrator, add a search menu item, make a note of the menu’s Item ID, then add this to the above code under the value.

Don’t publish the hidden menu in the module manager, we’ve just creating this to get the Item ID of the search page.

A leading enewsletter provider has analysed the last six months of data covering more than 250 million emails opens and compiled the most popular email clients as of February 2009.

33.0% Outlook 2000, 2003, Express
16.5% Yahoo! Mail
16.0% Hotmail
6.1% Outlook 2007
5.5% Apple Mail 3
5.1% Gmail
3.6% iPhone 2.0
2.1% Apple Mail 2
1.7% Lotus Notes 6-7
1.7% AOL Mail

It’s intersting to note than Outlook 2000, Hotmail and Yahoo are the most popular, as coding enewsletters is slightly different for each system. Ensure you test your enewsletter in each one.

Some useful HTML codes for making a website look good, best used at larger sizes for example in headings.

Just insert the code instead of the usual character. The most useful being the apostrophe or right single quote ’ which looks alot better than the prime or rat’s tooth ' as it’s sometimes called.

’s compared with the usual 's

Left single quote: &lsquo;
Right single quote: &rsquo;
Left double quote: &ldquo;
Right double quote: &rdquo;
Multiplication sign: &times; ×
Minus sign: &minus;
Registered trademark: &reg; ®
Copyright: &copy; ©
Trademark sign: &trade;
Pound sterling: &pound; £
En dash: &ndash;
Em dash: &mdash;
Ampersand: &amp; &
Ellipsis (dot dot dot): &hellip;
Degree sign: &deg; °
Em space (shown pink): &emsp;
En space (shown pink): &ensp;