Tag: tips Archives Not Just A Random Blog

08/15/2011

Google’s +1 Button In Detail

by Cyle — Categories: tools, Web Development — Tags: , , , , Leave a comment

A few months ago Google released its +1 button. It is much like Facebook’s “like” button. The button influences search results, mainly on your friends. If one of your friends +1′ed a site then you will likely see it in Google search results as “John Doe +1′ed page” and it will be a higher ranked result. I’ll go into more detail about it and its functions below.

The Basics

The easiest way to add the +1 button to your pages is to grab the code from Google’s plusone-button Page. Basically there are two ways of adding it:

1. Basic Source Code (slower)

Below is the basic way of using the +1 button. The script must be loaded once it is encountered in the page, and the rest of the page may not load until the script is done loading. Read More » »

08/09/2011

HTML Optgroup Tag

by Cyle — Categories: Web Development — Tags: , , Leave a comment

The optgroup tag is not known to many developers. Basically the tag adds a header or category title to your drop down lists. It is very helpful when used in forms and you need to categorize items in your drop down menus. The optgroup tags are not selectable themselves and only serve as a header or separation between items.

Example:
<select>
  <optgroup label="Swedish Cars">
    <option value="volvo">Volvo</option>
    <option value="saab">Saab</option>
  </optgroup>
  <optgroup label="German Cars">
    <option value="mercedes">Mercedes</option>
    <option value="audi">Audi</option>
  </optgroup>
  <optgroup label="---------------">
    <option value="other">Other</option>
  </optgroup>
</select>

Read More » »

08/09/2011

HTML Base Tag

by Cyle — Categories: Web Development — Tags: , , Leave a comment

The base tag in HTML is used to define the base or anchor of links and addresses on a web page. The base tag can be very beneficial, but can also cause many headaches. Check out the example below to get an idea of how to use it.

Example

Lets say I am located at http://www.cconoly.com/blog/ and below is a link on this page.

<a href="test.html">Click here</a>

Read More » »

08/09/2011

contentEditable Property

by Cyle — Categories: Web Development — Tags: , , , Leave a comment

When the contentEditable property is used, it makes your text editable in the user’s browser (IE, Firefox, and Safari). The contentEditable property has been around a while, but not a standard until recently under HTML5. It can be very fun and amusing to play with.

Example:
<div contenteditable="true">This text can be edited.
And this text can be edited.
Go ahead and play with it!</div>
Result:

Read More » »

06/22/2011

Speed Up Your PHP Webpages

by Cyle — Categories: php — Tags: , , , Leave a comment

PHP is great to use for dynamic websites, but the more you use, the more resources are required to execute the PHP script. Here is a list of tips to optimize your PHP and make it require less resources, and in turn execute your web pages faster. To see how long it takes to execute a PHP script see my post on Measuring Execution Time With PHP. Believe it or not, but all of the tips below will decrease the amount of resources required and speed up your PHP scripts. Read More » »

© 2013 Not Just A Random Blog All rights reserved - Theme by ([][]) TwoBeers