In our last session, we showed how to list the ad banner data and client data. In this session, we will examine the form that allows administrators to enter ad banner data. First, we include the class_ads.php file and instantiate the ads class: <?php require_once("class.ads.php"); // instantiate ads class $oAds = new ads; Next, we assign a value for the $id variable by suing the setID function in the ads class: // check for id if ($id) { // assign unique id $oAds->setId($id); } If the form has posted...
Today, I'm proud to start a series of posts that will focus on LESS, the dynamic language that takes your CSS and puts it on steroids. LESS let's you use variables, mixins, nested rules, and even functions within your CSS. It's extremely powerful and can dramatically speed up your development. There is a little bit of a learning curve to it, but once you wrap your head around it, you won't type CSS again without using LESS. Blog Series Roadmap ... An Introduction Using Variables Using Mixins Using Nested...
One of the main reasons the emergence of CSS3 has been so hotly anticipated is the fact that, in combination with HTML5, it will pose a genuine alternative to technologies such as Flash. With CSS3 and HTML5, you will ultimately be able to create animated, interactive multimedia applications that will be accessible to users regardless of whether Flash is supported in their environment - great news if you're developing Web apps for iOS or for mobile users in general. In this tutorial we will create a simple...
Lots of excitement surrounds HTML5's native audio element. It promises cross browser standardized support for playing audio clips embedded directly in our web pages. With this new element, gone are the days of including a third party plug-in like Flash, QuickTime, or Silverlight. Of course, we're not quite there yet. Currently, the <audio> element is supported in these browsers: iOS 4+, Android 2.3+, Opera Mobile 11+, and As web developers, we must be careful to include fallback support...
If you have read any of the other posts in this series you know that we have done quite a bit with our PHP ad tracker. In this session, we will look at the HTML form that calls these actions. First, we create the HTML table that will hold the form header: <table border="0" cellpadding="0" cellspacing="0"> <tr> <td><b>Developer Drive Advertisements Administration</b></td> </tr> Next, we specify the operation (add/edit/delete/deactivate) for this...
Custom attributes are among the most significant additions for HTML5, and can play a major role in semantic Web development. In this tutorial we'll go through a practical example of creating and accessing HTML5 custom data attributes, including the necessary JavaScript functions. It was possible before HTML5 to add your own attributes to HTML elements and access them using JavaScript, but if you've ever tried it you'll know you can forget about getting your markup to validate. HTML5 provides the...
CSS3 allows developers to implement a variety of visual and interactive functions most of us would previously have turned to JavaScript for. In this tutorial we will implement a drop-down menu, with background images featuring a gradient and rounded corners, all defined purely in CSS3 code. Our list will be structured using embedded lists in the HTML code, with top-level menu options appearing above their sub-menus, which we will display when users hover the mouse over the top level item. Here is...
Recursion is an age old concept used in mathematics when an object is defined by other objects of the same type. A real life example would be the mirrors in a department store dressing room. If you look in the right spot, you can see both reflections repeating themselves in each other. Each iteration of your image grows smaller and smaller into infinity. In computer science recursion happens when a solution to a problem is resolved by computing smaller instances of the same problem. In JavaScript,...