Categories
Operating Systems Vista

Fixing Windows Exporer and other Vista problems

Windows Explorer in Vista is enough to drive one to drink, not least for its constant inability to remember folder preferences.

windowsannoyances.org has a great solution at www.annoyances.org/exec/show/choosetemplate.

PCMag also has a link to that solution and some other good advice here.

Categories
Application Tips

Creating a repeating 3-up flyer in Microsoft Publisher 2007

Microsoft Publisher can be used to create repeating content in a flyer format.

Imagine that you want to subdivide a letter size page – in landscape mode – into three vertical panes, with the same content repeating the the tree panes.

You work with the content in one pane, and when printed, the content will repeat into the other two panes.

The key seems to be to understand the distinctions between page setup and print setup, and when in the Page Setup > Advanced "Custom Page Size Dialog" understanding the distinction between 'Page' and 'Sheet'.

When you click File > Print Preview, you'll see a 3-up presentation with 3 identical content panes.

Here's a rough guide to what worked for me:

File > Page Setup
 
  Advanced
 
    Custom Page Size Dialog
 
    Layout Type:
      Multiple pages per sheet
 
    Page:
      Page Width:  3.6666"
      Page Height: 8.5"
 
    Options:
      Target Sheet Size: Custom
      Sheet width:       11"
      Sheet height:      8.5"
 
File > Print Setup
  Printing options: Multiple copies per sheet
  Paper size:       Letter
  Orientation:      Landscape
Categories
PHP

PHP Debug Message Function

PHP coders frequently need to display a message in code for debugging purposes. It helps to be able to display these messages in a distinctive matter that sets them apart from normal page content, and to display the line number where the message was triggered.

This function displays the massage in a visually distinctive form, and prepends the line number from which the function is called.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
function debugMsg($message) {
	/*-------------------------------------------------------------------------------------------------
	 *   SCRIPT: debugMsg()
	 *  PURPOSE: Accept a text string and display is in a formatted div, preceeded by the line
	 *           number of the line that called the message.
	 *   SYNTAX: debugMsg('this is my error message.');
	 *-----------------------------------------------------------------------------------------------*/
	// 	
	// determine calling line - line number which called this function	
	// Reference: http://php.net/manual/en/function.debug-backtrace.php
	$call_info = array_shift( debug_backtrace() );
	$calling_line = $call_info['line'];
	// now print the message with the line number from which the message was generated.
	echo "<div style='border:1px dashed silver;background-color:#F7F3E8;margin:.25em; padding:.25em .5em;color:darkgray;font-size:100%;'>";
	echo "<pre style='margin:0px;'>$calling_line: $message</pre>";
	echo "</div>";
}
Categories
Joomla!

How to clear sample data from a Joomla Website

Load Joomla to your site with all the sample data. This is the sequence of steps to remove most of the sample data.

  • Article Manager – Trash All
  • Trash Manager – Delete All
  • Category Manager – Delete All
  • Section Manager – Delete All
  • Menu Manager – Delete those not wanted. I keep the Main and Top ( Joomla requires one )
  • Menu Trash Manager – Delete All
  • The next are Optional if you don't want them:
  • Banner Manager – Delete all Banners, Clients and Categories
  • News Feed Manager – Delete all feeds and categories
  • Poll Manager – Delete all
  • Web Link Manager – Delete all links and categories
  • Module Manager – Delete Admin Welcome and turn off ones you don't want running. Example: banners etc.
  • Template Manager
    At this point, you have a bare bones Joomla without the sample data but with the core modules intact. ( less the optional ones you may have uninstalled.)

Now, if you want to duplicate this bare bones site to other sites without having to go through all the above steps:

1. Export the database (from the above site) and save it. It's used to provide the new site's DB.
2. Load Joomla to a new site, but don't go through the install procedures.
3. Create an empty mysql database on the new site.
4. Import the database created in step 1 into the new DB created in step 3..
5. Copy the configuration.php file from the original site to the new site and make changes to reflect the new site's info. e.g. host name, password, site name etc.
6. Rename the installation directory to something else or delete it.
That's it. You should be able to access the new "cloned" site with the same admin name and password.

Source: PhilOSparta in http://forum.joomla.org/viewtopic.php?f=428&p=1212862

Categories
Web Development

Joomla Must-Have Extensions

Some of the most useful Joomla Extensions:

  • eXtplorer
    • A web-based file manager to manage files on your server.