July 2006 Islandnet.com Newsletter
PHP 5, virtual servers, domain privacy & More...
|
If you want a thumbnail sketch of PHP, you can read an earlier newsletter article if you click here. For those of you with tired mouse fingers, here's a quick rundown.
PHP stands for "PHP: Hypertext Processor" and it is an Internet programming language. PHP is one of the most popular Internet programming languages and is the language used to program the vast majority of Islandnet.com's Helpdesk system. If you're an Islandnet.com user and you've used our Helpdesk system, you'll know a bit of what PHP can do.
PHP 5 is now available as an alternative to PHP 4. Customers can choose between the two versions by logging into the Helpdesk, then clicking on the PHP Options icon
for each host in the "Hosts" tab under "My Account". Both versions will remain available for the time being.
The trick to supporting both versions in parallel on the same set of servers is DNS. Each server in our cluster has been assigned an extra IP address, and a second copy of Apache answers on those IPs. The only difference between the two web servers running on each machine is the version of PHP that it uses.
When you change the PHP version, the DNS info for your domain is updated so that the host in question resolves to one set of IP addresses or the other. This change can take several minutes to occur, and DNS caching can mean that it will take an hour or more before sites out on the 'net learn the new addresses. In other words, there is a transition time during which your site may load with either version of PHP. If you want to ensure that your scripts run only on a particular version of PHP, you can use PHP's phpversion() function. For example:
| CODE: |
if( phpversion() < 5 ) |
If we don't handle DNS for you, then changing the PHP version in the host manager will have no effect. In this case contact support for details on how to use PHP 5.
For information on the differences between PHP 4 and PHP 5, please visit http://ca.php.net/manual/en/faq.migration5.php
Also note that the configuration for PHP 5 has been changed to reflect the settings recommended by the developers. For example, the register_globals settings is now 'off'.
If you want to try your site with PHP5 to see how it works, simply create a second host entry. If your site is currently "example.com", try creating a host entry called "test.example.com" and set this one to use PHP 5. When the DNS changes kick in, access your site via "test.example.com" and see how it goes. Note that this counts as an extra host entry, so you'll want to remove it as soon as you are done testing.
First, for those who may not know what a "child" account is or what PEP is, you may want to read over the following sections, "Child Accounts" and "PEP (Personal E-mail Processing)".
Child accounts are "children" of Islandnet.com accounts. While they are created by the "parent" Islandnet account, they are in almost every respect a fully functioning account of their own. They can have their own disk space (which counts toward the "parent" account total), their own domain names (again, counting toward the "parent" total), their own databases, and other account features.
Why have account children? Back in the "olden days" child accounts were for, you guessed it, children. Islandnet.com setup child accounts so that children (or others) could have access to the parent account dialup time. Now, child accounts are typically used for the following reasons:
If you'd like to play around with child accounts, log into the Helpdesk, then go to the following URL:
https://helpdesk.islandnet.com/accountman.cgi?tab=children
In a nutshell, PEP is a program written by Islandnet.com that gives customers very sophisticated tools for dealing with their e-mail. The most common use of PEP is to filter out e-mail. Some other popular uses of PEP include redirecting e-mail depending on who sent it or where it's directed (or one or more other variables), setting "vacation" messages, and setting up automated replies. Because PEP is a system customers can control, what customers can do with e-mail really is limited only by our customers' imagination.
To visit the PEP documentation, go to the following URL:
https://helpdesk.islandnet.com/pep/
We have enhanced PEP to give more control over a child account's PEP rules to the parent account. Some sample scenarios might include:
A new page has been added to the PEP help pages that explains this in more detail.
I have also added a new page on setting up real mailing lists with PEP.
The limit on mailing list sizes via the DISTRIBUTE action has been increased to 10,000 recipients.
The STRIP action has been documented (it was missing previously).
We sometimes get calls from customers asking why their payment hasn't shown up, despite being made online through their bank. The answer is "you have to wait a bit."
Online banking is great. Click a couple of buttons and your payment is made. No licking cement-flavoured envelopes, walking down to the nearest mailbox, and then allowing a week for delivery, receipt, and processing of the payment. It's all done instantly. Or is it?
The short answer is "almost."
When you make a payment through online banking, payments still take time to process, though the process is still far faster than "real world" payments. When you transfer funds from you account to Islandnet (or any other "payee" for that matter), the money is deducted from your account immediately. This is where some customers believe the payment has been immediately applied to their Islandnet account.
However, once the amount is deducted from an account, the payment process is just started. The payment then has to be reviewed by a human being. Once the transaction is reviewed by a human being, the transaction is recorded (along with all other transactions that day) at Islandnet.com's bank. Islandnet.com is then notified of all the payments made during the previous 24 hours. Islandnet.com then credits customer accounts with the payments made.
It's worth noting that this online banking process can take as long as 48 hours. So, if you're very close to having your account suspended you need to allow at least 48 hours for processing of your payment. If you are paying less than 48 hours in advance of having your account suspended, you may want to give us a call to let us know the payment has been made via online banking to avoid having your account suspended.
| Boingboing.net | craigslist.org | Ubuntu | Kevin Kelly Cool Tools |
"A directory of wonderful things" is the tag line below the boingboing.net logo. Lots of people seem to think the site is wonderful because it is arguably *the* most popular blog on the Internet. In fact, if you visit another site we've mentioned here in an earlier newsletter, "technorati.com", you'll see boingboing.net is listed as the second most popular blog, behind a foreign language blog. For those of us Canucks who enjoy a bit of nationalistic chest-thumping, the blog is based in Canada. WARNING: This site is very eclectic and there's a chance you'll see some racy images and / or links to sites that some may find offensive. |
Craigslist.org is a bit of an Internet phenomenon, in that it's taken on a life of its own. Started in 1995 by Craig Newmark, craigslist.org started out as a place to post information about San Francisco events. It grew into a website where anyone can post messages, "for sale" ads, and other things. This may seem like just a bulletin board or forum but it's REALLY BIG. There is a craigslist for just about every country and city you'd care to name. Click here to visit the Victoria, BC craigslist. Click here to visit the Bangladesh craigslist. |
Even if you don't know what "Linux" is and lounging lions on the Serengheti come to mind when you hear the word "Ubuntu," you may still know enough to install this new operating system. That's right. Ubuntu is an operating system like Microsoft Windows. You can browse the Internet, use a sophisticated office suite (that can open Microsoft Office documents), check your e-mail, and even edit red-eye in those vacation photos you just snapped. But the best part is Ubuntu is FREE! Moreover, many of the applications available for Ubuntu (including the office suite) are FREE as well. Because FREE is one of our favourite words, we're going to say it again--"it's FREE!" |
Hmmm--bare foot shoes, an oil change oil sucker, a clamp making tool, and a screw hole repair kit--all covered in this blog. Kevin Kelly has a penchant for unique and useful tools and, as a result, he blogs about them. You may want to visit the rest of Kevin Kelly's site, though. His interests are very broad and he's involved in a project to document every living species on the planet--giving each its own web page. He's also involved in the 10,000 year clock to get people thinking re-e-eally long term. |
| W & J Wilson | QuakeKoso Canada Inc. | Room Raiders | Victoria Salmon Kings Booster Club |
Wow, a clothing store that's been around since the 1870's. You just don't see company longevity like that very often. From the W & J Wilson website: Today, Wilson's is recognized still as the Popular Headquarters for Finest Woolen Imports and Quality Apparel for the Whole Family. W&J Wilson will continue the fine tradition of specializing in the English Craftsmanship and fine loomed fabrics that remain the hallmark of the trade to this day. Why don't you come on in and see for yourself what W&J Wilson's has to offer you and your family. We're happy to say W & J Wilson has their website hosted with Islandnet.com. |
Here in British Columbia, we live on the "ring of fire"--a ring of volcanoes and seismic faults that circle the Pacific Ocean. As a result, we should be ready for "The Big One." If you're not ready, this company can help you prepare. This Islandnet.com-hosted website has information about automatic natural gas shut-off valves. The safety valves are perfect for public buildings and private buildings where many people gather. In the event of an earthquake, these valves will shut down the gas supply, greatly reducing the chance of fires or explosions. |
Hmmm--Room Raiders, Professional Organizing--this isn't some sort of housekeeping union booster organization is it? Well, no it's not. Room Raiders is a company that helps people get and stay organized, from helping organize closets to spring cleaning in the garage. They suggest on their Islandnet.com-hosted site that "an organized home can decrease cleaning time by 40%." Hallelujah to that brothers & sisters! |
Calling all hosers, Y' can't be a Canuck unless y' support yer local hockey team, eh! If we find y' don't support yer local hockey team, we're gonna take back yer Canadian passport, eh. After years without major junior or professional hockey in Victoria, we've got a professional hockey team in town (that is if you're from Victoria). Yeehaw! We're happy to say the booster club has its site with Islandnet.com. Game on, eh! |
Websites are our business--hosting them and building them. If you need a website--blog, retail, business-to-business, personal, database-driven, or something else--Islandnet has plenty of website development and programming experience. Call or e-mail us if you'd like anything from graphics to nit-picky programming.
A virtual server is a middle ground between shared hosting (which all Islandnet.com accounts have) and a dedicated/colocated server (which we also provide). Many virtual servers can exist on a single physical server, but they appear to be distinct machines. You can SSH into a virtual server, become the root user, halt or reboot it, create any number of user accounts, install and run software that would be too insecure to permit in a shared hosting environment, etc. A virtual server is commonly referred to as a VPS (Virtual Private Server) or VDS (Virtual Dedicated Server).
We've been working on adding a virtual server option to Islandnet's offerings, and it's getting close to the point where we'll need some folks to try it out. If this interests you, please contact us. We can't promise that you'll get to be a beta tester as we want to keep the number small to start, and we're looking for folks with UNIX experience.
More details:
If you run a website and you want to try out your newest ninja programming skills on an unsuspecting MySQL database, go ahead, make our day! You can now simply log into the Helpdesk, go to the following URL and create your databases:
https://helpdesk.islandnet.com/accountman.cgi?tab=databases
If you go to the new database creation utility, you'll see there are two types of MySQL databases you can create. You can create a version 4.0.27 database or you can create a 5.0.22 version database. Version 4.0.27 is the previous version, which you may want to use if your scripts don't play well with the newest version--5.0.22.
Go ahead. Create a database then blow it away. We know you want to.
One of the harvesting targets spammers abuse is public "WHOIS" information. "WHOIS" records track who owns which domain names and gives basic information about how to contact them. It's handy information to have since it hopefully has a long term e-mail address and other info people can use to contact the domain owner. Of course, spammers simply gather e-mail addresses from WHOIS records so they can spam to their slimy hearts' content.
However, you can protect your WHOIS information for a few pennies a day. A new option is now available for customers who have registered a domain through us, which replaces the contact information in the WHOIS record with pointers to a privacy service. People can still contact you through this service, but not directly via email. All they can do is visit a special web site, enter your domain name, enter a CAPTCHA code, and type a message to you. They never see who the message is actually going to and they can't automate it.
This service costs $0.25 CDN per month ($3.00 per year) per domain. If this is something you'd like to have enabled on your domain, contact support@islandnet.com. It will be enabled ASAP and the $0.25 charge will start appearing on your monthly statements.
Please note that this service is NOT available for .CA domains at this time.
This news is a bit long-in-the-tooth but we thought it was worth repeating here in case people had not read the forum posting a while back.
It is now possible to connect directly to your Islandnet.com MySQL databases from your office or home computer. This will allow you to manage your databases using Windows, Mac, or Linux front ends instead of having to use phpMyAdmin (although that is a very good interface and will always be available through https://helpdesk.islandnet.com/sql).
The MySQL site (www.mysql.com) has a free "query browser" tool for Windows, Mac, Linux, etc. which you can download at http://dev.mysql.com/downloads/query-browser/1.1.html It's not a great tool, but it's better than nothing.
A search for MySQL GUIs will turn up several other options, both commercial and free. One that I've tried for Windows/Linux that is nice is "SQL Manager 2005 Lite", which is available at http://sqlmanager.net.
If you install the ODBC drivers for MySQL (available from http://dev.mysql.com/downloads/connector/odbc/3.51.html) then you can manipulate your MySQL databases from within Open Office or Microsoft Access, etc. I have tested this with Open Office myself and it works well.
To access your database remotely, you will need to configure your software to use the same MySQL server name, username, password, and database name that you use in your web site. The port number to connect to is the standard MySQL one of 3306.
Our MySQL servers support SSL encryption, and if your side of things also supports it then it's a good idea to enable it, although it will slow things down a bit.
NOTE: By default all IP addresses are NOT allowed access from the outside world for security reasons. Before you can access MySQL remotely you will need to have your IP address authorized. This happens AUTOMATICALLY whenever you make a successful POP3 mail or helpdesk login. Either of these actions will add your IP address to the authorized list for 6 hours. In other words, it is just like the "POP before SMTP" technique that allows folks to send mail through our mail servers. Also note that accessing your database like this will contribute to your bandwidth usage.
Here at Islandnet it's gratifying to see e-mails flying around the Internet with our domain name attached to them. I guess it must be the same for people who see a building they've designed or worked on or something else they've worked on and, as a result, take pride in.
However, you may want to consider using your domain name for your e-mail address. For example, if your domain name is "example.com", you might want to use "josie@example.com" if Josie happens to be your name.
What does that do for you? Well, we can think of a few things. Here they are:
So, while we're gratified to see messages from "lots_of_people@islandnet.com" flying all over the Internet, if you have a domain name, using it as part of your e-mail address has many advantages.
If you run a website, have you ever had to edit one line of text that occurs in a whole site full of pages? Yes you have, haven't you! What a drag!
You don't have to do that anymore. On Islandnet.com there are at least two ways to ensure those copyright statements at the bottom of the page (and maybe those notices at the top of the page) don't have to be edited umpteen dozen times every time you spot a typo or need a change.
Let's say you have a page where the HTML looks like the following (let's also assume the page is named "my_file.html):
<html>
<head>
<title>My Web Page</title>
</head>
<body>
<p>This is text that appears at the top of every page</p>
<p>This is text that appears only on this page</p>
<p>This is text that appears at the bottom of every page</p>
</body>
</html>
If you have 10 pages and every one of them has identical text at the top and bottom, you'd have to go through every single one of them and change them. Maybe you have Dreamweaver or another program that allows you to do a search and replace over multiple files. That makes things much easier but it's still a pain and what if you've inserted an extra space between two characters in one of the pages (seeing as you've probably created them one at a time). That extra space means your search and replace may not work on that one file.
Here's the easy way to handle this situation. Use the following HTML to replace what we've outlined just above:
<html>
<head>
<title>My Web Page</title>
</head>
<body>
<!--#include file="page_top.html" -->
<p>This is text that appears only on this page</p>
<!--#include file="page_bottom.html" -->
</body>
</html>
When the Islandnet web server replies to a request to load the above HTML page, it first looks through the code to see if there are any server instructions in the file. The code <!--include# file="page_top.html" --> tells the server to look for the file "page_top.html" and load it at that particular spot. With the code <!--include# file="page_top.html" --> included in each of the website pages, instead of changing 10 files you can change one instead.
Of course, the "page_top.html" and "page_bottom.html" files can contain any HTML you wish. So, if you wanted "page_top.html" could include the following:
<html>
<head>
<title>My Web Page</title>
</head>
<body>
<p>This is text that appears at the top of every page.</p>
And, you could have "page_bottom.html" include the following HTML:
<p>This is text that appears at the bottom of every page</p>
</body>
</html>
By using the above two examples of "page_top.html" and "page_bottom.html" only the following HTML needs to appear in "my_file.html":
<p>This is text that appears only on this page</p>
Note: If the file you "include" on your page is located somewhere else, you may need to use a variation on the code just covered. You would need to use the code below:
<!--#include virtual="../some_directory/page_bottom.html" -->
Using PHP to accomplish what's outlined above is almost the same as using Server Side Includes. There are only two differences. First, you need to use PHP. Second, you need to name your file with the "php" extension.
Using PHP is easy. Here's what the page code in "my_file.php" (remember, we have to rename the file with a "php" extension) will look like:
<html>
<head>
<title>My Web Page</title>
</head>
<body>
<?php include "page_top.html"; ?>
<p>This is text that appears only on this page</p>
<?php include "page_bottom.html"; ?>
</body>
</html>
That's it. "page_top.html" and "page_bottom.html" can keep their "html" extensions if you like.
When our web server responds to a request for the page "my_page.php" it sees the file should be interpreted with PHP. When going through the file, our server responds to everything between the "<?php" and "?>" brackets as PHP code and carries out the commands between them.
Once again, you don't have to go through every one of those 10 pages in the future to make a change to text at the top or bottom of the page. Once will do it!
Here's an annual time saver. If you've got one of those copyright notices at the bottom of the page that states the year, it's easy to forget to change the year every January 1. If you're using a header and footer, as suggested in the rest of this article, you're already ahead of the game. However, it's easy to forget.
The good news is it's okay to forget! Let PHP change the year automatically on January 1 each year. All you need is the following bit of code:
<?php echo date('Y'); ?>
Remember, the file that contains the above code has to be renamed with a "php" extension. Once there, the code will always display the current year like so: 2008.
This is an aside but some of you may want to display the current date and time, though not for the copyright notice. Here is date and time as displayed with a bit of PHP code: Thursday, July 24, 2008: 11:22:46 am. Here is the code to display the date and time as just demonstrated:
<?php echo date('l, F j, Y: g:i:s a'); ?>
For information on formatting the date and time with PHP, visit php.net.
The information displayed in this newsletter and any previous or subsequent newsletters is for information purposes only. Islandnet.com, AMT Solutions Group, Inc. and related companies are not responsible for any losses or damages resulting from the use of information in the newsletter. While the information contained in this newsletter is believed accurate, readers must verify information for themselves. Sites we link to do not necessarily represent the opinions or policies of AMT Solutions Group, Inc.
The content of this newsletter is copyright 2004 - 2008 © AMT Solutions Group, Inc. All rights reserved.