Busy little bee
For the past few days (maybe even weeks) I've been busy getting my hosting company back up. One thing that I really love about the Internet is hosting other people. Helping them getting their website(s) online is one of the things I really like doing, besides coding and writing obviously. I'd like to promote my webhosting company and hopefully you guys will sign up for a package: Silent Web Services. As you can see it's not only a hosting website but we also offer design and coding packages. So, head over there (if you haven't already) and order! Please! I'm begging you... :-p
Special character codes
Here's a list of commonly used special characters also known as ASCII code.
| Symbol | Code | Description |
|---|---|---|
|   or | Space | |
| © | © or © | Copyright sign |
| ! | ! | Exclamation mark |
| " | " or "e; | (Double) quote |
| & | & or & | Ampersand |
| ' | ' | Single quote |
Add a directory installed WordPress on the root
If you have WordPress installed in a directory but want to show the url as http://www/yourdomain.com instead of http://www.yourdomain.com/wpdirectory then you can follow the following few steps:
- Log in to your wordpress website
- Go to Settings->General and change the "Site address (URL)" setting to your domain URL (e.g. http://www/yourdomain.com) Note: Make sure you don't change the "WordPress address (URL)" setting or your blog won't work anymore.)
- Once your done you need create a index.php file in your favourite editor and past the following code in there:
<?php define('WP_USE_THEMES', true); require('./wpdirectory/wp-blog-header.php'); >
make sure you change the "wpdirectory" to the folder you've installed WordPress in
- Save the file and upload it to your website using any FTP program
That's it! Now you can visited your website on http://www.yourdomain.com and see if it works.
The centering cheat
If you are using div’s to built your layouts than a good thing to know is how center it. Because of the many different browsers it can sometimes be a hassle to find out what works with which browser.
Now centering a div isn’t at all difficult. Normally in HTML you could easily use the<center> tag but in XHTML it’s deprecated. So, you may wonder how you’ll make it work in XHTML. All you need to do is add the following code to your CSS.
.centered{
margin: 0 auto;
}
If you wish to use the centering cheat in your layouts make sure to add the following in your CSS.
body{
text-align: center; //To make it work in IE
}
#containerdiv{
margin: 0 auto;
text-align: left; //To make the text start at left (or justify/right) instead of center) side again.
}
Now your layout should be centered in every browser!