Archive for the ‘Site Tips’ Category

Adobe Spry Menus

Wednesday, March 10th, 2010

When I first started designing website around 1996 or so, I did not have fancy programs like Dreamweaver to guide me through the process. A typical session involved the Windows notepad, lots of “Save As” and refreshing in the browser. Here I am 14 years later and I love using Dreamweaver. It’s not my sole tool for designing websites. I still use free options when I feel the need. However, Dreamweaver makes certain things much easier. One of them is CSS/Spry menus.

The Spry menu is a very quick and handy way to add a fancy CSS menu to your site design and it works very well with one caveat. That would be Internet Explorer. IE manages to screw up an otherwise beautiful horizontal CSS menu by displaying the submenu items incorrectly. In a typical scenario the submenu would be displayed as a vertical list of items. IE would rather display this as a horizontal block of items. Now ideally the best solution would be to have the user view your site in Firefox or Chrome but that’s not going to happen. The easiest solution is to add the following line of code to your CSS page that links to the menu.

ul.MenuBarHorizontal li ul li{
clear: left;
}

That’s it. Your menu should now appear correctly in all versions of IE.

MySQL Backup in Windows

Tuesday, February 23rd, 2010

So you’ve spent the past few hours creating your new website and are ready to upload your files from your localhost to your web server.  You upload your site files and everything seems fine but how do you get that pesky MySQL database over to the new server?  If you are running a Windows machine, then this guide will help.  The following steps are assuming that you already have a MySQL database and know its name the username and password.

  1. Open the Windows Command Prompt.
  2. Type cd\program files\MySQL\MySQL Server 5.1\bin (keep in mind that you may be using a different version of MySQl and as such you should change the version number accordingly.
  3. Press Enter
  4. Type mysqldump -u -p db_name > db_name output file type (mysqldump -u root -p12345 db_name > db_name.txt)
  5. Keep in mind that db_name=your db’s name and db_name output file type = the name and file extension you wish to use.  You can also choose to backup the database with the SQL extension.
  6. Press Enter
  7. Depending on the database’s size, this action could take a few seconds or a minute.
  8. Once completed, browse to C:\Program Files\MySQL\MySQL Server 5.1\bin and locate the file.

It’s really as simple as that.  You can now upload this TXT or SQL file to your server using the PHP import function.