iBlog random » site http://blog.zurka.us Just another WordPress weblog Tue, 28 May 2013 20:28:47 +0000 en-US hourly 1 http://wordpress.org/?v=3.6 Make Your Titles Dynamic with PHP http://blog.zurka.us/make-your-titles-dynamic-with-php/ http://blog.zurka.us/make-your-titles-dynamic-with-php/#comments Tue, 26 May 2009 15:25:00 +0000 nasal http://blog.zurka.us/?p=938

When developing your website, if you want to rank well in search engines it is crucial that you use different titles for every sub-page you’ve got online. This is because these search engines (Google, MSN etc) love your titles and categorize your site based on them. This is good for SEO.

This is a simple thing to accomplish using PHP but it really is very effective. I will put dumb text into them but you should use titles rich with keywords related to your niche.

$title = 'Welcome to our website!';
if (key($_REQUEST) == 'register') { $title = 'Register now'; }
if (key($_REQUEST) == '404') { $title = 'Error 404: The page is unavailable'; }
if (key($_REQUEST) == 'about') { $title = 'Who we are, what we do'; }
if (key($_REQUEST) == 'news') { $title = 'Recent news'; }

This would work if you are using urls like yoursite.com/?register, ?news etc. What it does is set a variable $title which will include the text your define according to the page we are watching. Now we need to display it in our browser.

<head>
    <title><?= $title; ?> - Your Company Name</title>
</head>

Pretty easy, isn’t it?

Oh and today I’ve found a FREE product that helps you make some money with google, all you have to pay is less then $3 for shipping and handling and they mail it to you. The offer is only valid for the US though. Click here if you are interested. It can do no harm if you’re serious about making some money online and $3 really isn’t something you could not afford!

Have swing!

]]>
http://blog.zurka.us/make-your-titles-dynamic-with-php/feed/ 2
Use PHP To Display Page Content (LMAWT part 2) http://blog.zurka.us/use-php-to-display-page-content-lmawt-part-2/ http://blog.zurka.us/use-php-to-display-page-content-lmawt-part-2/#comments Fri, 23 Jan 2009 15:27:16 +0000 nasal http://blog.zurka.us/?p=826

If you missed the previous posts, you can read the Introduction and First part to catch with us.

What we are going to do today is make our links work and display the content depending on what link we click.

First let’s make our links go live. In our final result of part 1, our links were dead. To make a link work, we must use this syntax:

<a href="./">Home</a>
<a href="./?news">News</a>
<a href="./?contact">Contact</a>
*** notice we use ?news for the news, ?contact for the contact page etc, will be explained later ***

So let’s change all of our links to this. Our final result will be this. As you can see, the links are underlined and you can click on them. But if you click on them you will notice nothing really changes on the page, except for the URL in the browser.. that’s because we need our PHP code that will “read” the URL and display the content that comes along.

Let’s see the PHP code that we put into our #main-content div. To load different contents depending on what click we link on, we are going to use the switch function, which is not hard to understand, is very useful and works fast!

<?php
switch (key($_REQUEST)) {

	case 'news':
		echo 'We will display our news here';
	break;

	case 'members':
		echo 'This will be the member list';
	break;

	// we continue like this for all our links
	// and finish with the default statement

	default:
	echo 'Welcome to my first website';

}
?>

As I said before, put this code between inside your #main-content DIV.

<div id=”main-content”>
<?php switch () {} ?>
</div>

What will this piece of code do?
It will display different contents based on the page we are on. If, for example, we will click on our “news” link, the URL will change to “domain.com/?news” and the content that will be shown will be “news.php“, because of the ‘case’ we wrote. In this case, what comes after the question mark in the URL is called a “query string” and we will work with these.

In this example we are using the “key($_REQUEST)” but we could change this to react to something like “domain.com/?page=news” and in this case we would use a different switch. Tell me if you want to know about it and I’ll write an example for this.

Anyway, check what we accomplished now. We made our first working website, we could actually put whatever we would like inside, we are done. The content is changing and everything is working fine.

Any questions? Feel free to ask!

]]>
http://blog.zurka.us/use-php-to-display-page-content-lmawt-part-2/feed/ 4
Color meaning http://blog.zurka.us/color-meaning/ http://blog.zurka.us/color-meaning/#comments Mon, 06 Oct 2008 14:36:04 +0000 nasal http://blog.zurka.us/?p=536

Did you ever wonder what color should your website be? Depending on what the content of the site is, different colors will suit best. I give you a list of colors, their meaning and what the human brain feels when it comes in contact with them.

Red

Red is the color associated with energy, strength, power, determination as well as passion, desire, and love.

Red brings text and images to the foreground. Use it as an accent color to stimulate people to make quick decisions; it is a perfect color for ‘Buy Now’ or ‘Click Here’ buttons on Internet banners and websites. In advertising, red is often used to evoke erotic feelings (red lips, red nails, red-light districts, ‘Lady in Red’, etc). This color is also commonly associated with energy, so you can use it when promoting energy drinks, games, cars, items related to sports and high physical activity.

Light red represents joy, sexuality, passion, sensitivity, and love.
Pink signifies romance, love, and friendship. It denotes feminine qualities and passiveness.
Brown suggests stability and denotes masculine qualities.
Reddish-brown is associated with harvest and fall.

Orange

Orange combines the energy of red and the happiness of yellow. It is associated with joy, sunshine, and the tropics. Orange represents enthusiasm, fascination, happiness, creativity, determination, attraction, success, encouragement, and stimulation.

To the human eye, orange is a very hot color, so it gives the sensation of heat. Nevertheless, orange is not as aggressive as red. Orange increases oxygen supply to the brain, produces an invigorating effect, and stimulates mental activity. It is highly accepted among young people. As a citrus color, orange is associated with healthy food and stimulates appetite. Orange is the color of fall and harvest. In heraldry, orange is symbolic of strength and endurance.

Orange has very high visibility, so you can use it to catch attention and highlight the most important elements of your design. Orange is very effective for promoting food products and toys.

Gold evokes the feeling of prestige. The meaning of gold is illumination, wisdom, and wealth. Gold often symbolizes high quality.

Yellow

Yellow is the color of sunshine. It’s associated with joy, happiness, intellect, and energy.

Yellow produces a warming effect, arouses cheerfulness, stimulates mental activity, and generates muscle energy. Yellow is often associated with food. Bright, pure yellow is an attention getter, which is the reason taxicabs are painted this color. Yellow is seen before other colors when placed against black; this combination is often used to issue a warning. In heraldry, yellow indicates honor and loyalty.

Use yellow to evoke pleasant, cheerful feelings. You can choose yellow to promote children’s products and items related to leisure. Yellow is very effective for attracting attention, so use it to highlight the most important elements of your design.

Light yellow is associated with intellect, freshness, and joy.

Green

Green is the color of nature. It symbolizes growth, harmony, freshness, and fertility. Green has strong emotional correspondence with safety. Dark green is also commonly associated with money.

Green has great healing power. It is the most restful color for the human eye; it can improve vision. Green suggests stability and endurance. Green, as opposed to red, means safety; it is the color of free passage in road traffic.

Use green to indicate safety when advertising drugs and medical products. Green is directly related to nature, so you can use it to promote ‘green’ products. Dull, darker green is commonly associated with money, the financial world, banking, and Wall Street.

Aqua is associated with emotional healing and protection.
Olive green is the traditional color of peace.

Blue

Blue is the color of the sky and sea. It is often associated with depth and stability. It symbolizes trust, loyalty, wisdom, confidence, intelligence, faith, truth, and heaven.

Blue is considered beneficial to the mind and body. It slows human metabolism and produces a calming effect. Blue is strongly associated with tranquility and calmness.

You can use blue to promote products and services related to cleanliness (water purification filters, cleaning liquids, vodka), air and sky (airlines, airports, air conditioners), water and sea (sea voyages, mineral water). As opposed to emotionally warm colors like red, orange, and yellow; blue is linked to consciousness and intellect. Use blue to suggest precision when promoting high-tech products.

Blue is a masculine color; according to studies, it is highly accepted among males. Dark blue is associated with depth, expertise, and stability.

Light blue is associated with health, healing, tranquility, understanding, and softness.
Dark blue represents knowledge, power, integrity, and seriousness.

Purple

Purple combines the stability of blue and the energy of red. Purple is associated with royalty. It symbolizes power, nobility, luxury, and ambition. It conveys wealth and extravagance. Purple is associated with wisdom, dignity, independence, creativity, mystery, and magic.

According to surveys, almost 75 percent of pre-adolescent children prefer purple to all other colors. Purple is a very rare color in nature; some people consider it to be artificial.

Light purple is a good choice for a feminine design. You can use bright purple when promoting children’s products.

Light purple evokes romantic and nostalgic feelings.

]]>
http://blog.zurka.us/color-meaning/feed/ 4