Français English Español Italiano Português
User Login    
 + User Registration
Connexion

Webmaster » Articles


lotsofcode | 2008-02-27T14:31:36+01:00 | 1 reads

A nice little way of adding a header image to a fluid layout it to break the header images into two slices and then assign the headers to a div in the same container like so.<style type="text/css">#myContainerName{background: url('/path/to/images/header-back.jpg') repeat-x;height: 220px;}#myContainerName #leftBackground{background: url('/path/to/images/header-left.jpg') left no-repeat;height: 100%;width: 100%;}#myContainerName #rightBg{background: url('./path/to/images/header-right.jpg') right no-repeat;height: 100%;width: 100%;}</style>And the HTML will look like so ...<div id="myContainerName"><div id="rightBg"><div id="leftBg"><!-- Content Here -->&l...



lotsofcode | 2008-02-27T14:30:58+01:00 | 2 reads

This is a basic tutorial on how to create a basic css layout with three columns.So to start in your css you need four classes / containers to begin.Firsts your container for all the other containers becomes some what of a wrapper for all the other containers, in the class you will need assign the dimensions of the container - mainly the width and thenany other styles like borders can be added to make it your own. Our css and the html for the main container will look like this. <style type="text/css">#mainContainer{width: 760px;border: 1px outset red;}</style><div id="mainContainer"></div>So now we have the main container we can create the left and the right contain...



lotsofcode | 2008-03-16T23:21:07+01:00 | 15 reads

This is a little tutorial i put together to help people starting out with jQuery to learn the basics.So, first things first. Pop over to http://docs.jquery.com/Downloading_jQuery and download the latest version in whatever form you prefer, Minified, Packed or Uncompressed. If you are not fussed then i would suggest the packed version.No, the first thing you should do is create a specific testing area, for example c:\jquery. Then in that folder extract the jquery file into it, if the name of the js file isn't jquery then i would suggest you rename it to jquery.js to make the name of the file nice and easy to remember.Now, on to the html.Create a file, with whatever name you prefer, i will ...



lotsofcode | 2008-03-20T01:51:27+01:00 | 14 reads

Had enough of the same old operating system based select field style? Why not skin it up, this script allows you to apply a skin to a select box.This tutorial is based on the original code i wrote, however this version is less buggier and has support for non JS enabled browsers!Nice and simple to install, include the jQuery library and the select skin JS file and the CSS file like so.<style><!--@import url('./css/skinned-select.css');//--></style><script src="./js/jquery.js" type="text/javascript"></script><script src="./js/jquery.skinned-select.js" type="text/javascript"></script>Then just wrap a div with the class name of 'my-skinnable-select' a...



lotsofcode | 2008-02-27T14:29:59+01:00 | 3 reads

The simplest way to create a javascript popup is to create a function like so. <script language="javascript" type="text/javascript"><!--// I have called the popup showPopfunction showPop(url){// This is the part that opend the new window, we set the url, name and dimensions of the windownewwindow = window.open(url,'name','height=400,width=550');}// --></script>And then add the following to the anchor link you would like to popup. <a href="#" onclick="return showPop('http://www.google.co.uk')"> see my popup </a>



lotsofcode | 2008-02-28T14:14:47+01:00 | 3 reads

Please check out the demo page for examples on how to use the new functions available in this version.Some of the new features included in the new tag cloud script are:Link and URL AssignmentAdditional attribute assignment e.g. title etcAdd styles and colour options to each tagSet a limit to the amount of tags that are displayedExamples of intergrating with a MySQL DatabaseExamples of intergrating with a Flat Text FileString to cloud, parse a single string into a tag cloud instantlyIgnore list, to remove particular words from the cloud. e.g. and, the, it, iOrdering by a selective field. e.g. word, size, colourTutorial coming soon ...



lotsofcode | 2008-02-27T20:12:43+01:00 | 4 reads

Tag Cloud Script (Version 2) is now Available, with more customizable featuresIntroductionIn this tutorial i am going to show you how to create a basic word / tag cloud using php and utilizing php classes for easy inclusion. I am going to create a class based cloud, this is because it will be more convenient for you to adapt it on your own website(s), if you don't know much about class based programming then click here to take a look at the class tutorial.TutorialFirst we need to create the class and for this example i am going to call the class "wordCloud" this is just my personal naming preference, feel free to call your cloud whatever you like, we are also going to assign the first cla...



lotsofcode | 2008-02-27T14:32:09+01:00

Concatenating in SQL is pretty simple, it's purpose is to connect fields and string together as one string, like so.If you have a database table field called forename and you would like to have the word MR before each name, this is how it would be done. SELECT CONCAT('Mr. ', forename) FROM table;You can also pass as many arguments as you like through this function, for example. SELECT CONCAT('Mr. ', forename, ' ', surname, ' - ', jobTitle) FROM table;



lotsofcode | 2008-02-27T14:32:20+01:00

A very simple way of passing data from one table to another is by using the select insert statement in sql. INSERT INTO table (forename, dayphone, address1, address2, address3, postcode, country, email)select r.first_name r.phone_number, r.address1, r.address2, r.address3, r.post_code, r.country, r.email from table2 r;



lotsofcode | 2008-02-27T14:31:58+01:00 | 9 reads

You can use a case statement in SQL like so:SELECTid, `name`, title,CASE idWHEN 2 THEN 1WHEN 3 THEN 1ELSE 0END AS selectedCaseFROM table