Retrieving User Input Data

ons, mar 3, 2010

Kommentarer slået fra

In this tutorial we’ll be retrieving data from form fields. To do this we’ll first create an example form. We’re using the POST method to send the form data in the first example. Will later explain what this means, and how we can then retrieve the data from the form fields. Also the GET method will be explained in this tutorial later on. For the form we set the action to the file itself ( we call it ‘form_handle.php’, call it anything you like ).

The Form

File: form_handle.php

Tags: , , , , , , , , , , ,

Quick Tip: Learning jQuery 1.4’s $.proxy

ons, mar 3, 2010

Kommentarer slået fra

One of my favorite new features in jQuery 1.4 is the new $.proxy method. It allows us force a particular context when calling a method. In JavaScript, there can be times when it’s difficult to hold on to the this keyword. For example, when it’s bound to some event handler, this now refers to the target of the handler, rather than your desired object.

If this sounds a bit confusing, don’t worry; today’s four-minute video quick tip should clear things up.

 

Tags: , , , , , , ,

How We’ll be Building Websites in 5 years: HTML5 and CSS3 layout

ons, mar 3, 2010

Kommentarer slået fra

Graceful Degradation

Since HTML5 and CSS3 aren’t going to be supported in all the browsers, especially not older ones like IE6, we can try and make it work in everything, but it won’t look the same in all of the browsers. For instance, rounded corners wont work in IE or Opera, but it wont affect the usability of that web page. Likewise, the flexible box model only works in Firefox and Webkit.

Tags: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,

Set iPhone Bookmark Icon

ons, mar 3, 2010

Kommentarer slået fra

Place this in your <head> section, and set the href attribute to an image to a 57px x 57px PNG file.

<link rel="apple-touch-icon" href="iphone-icon.png"/>

Tags: , , , ,

Quick Tip: How to Use a Document Class in Flash

ons, mar 3, 2010

Kommentarer slået fra

Why Use Class Files?

I’ll admit it – sometimes, coding entirely on the timeline is useful. It’s a quick way to test out an effect, and the easiest way to sync actions to specific frames of an animation.

But for any project that relies more on code than on animation, there are serious disadvantages. All your ActionScript is trapped inside the FLA file; you can’t split the programming between different developers, you have to copy and paste code if you want to re-use it, and you’re forced to use Flash’s Actions Panel.

Tags: , , , , , , , , , , , , , , , , , ,

How To Create a Reusable, Dynamic Badge Effect in Illustrator CS4

ons, mar 3, 2010

Kommentarer slået fra

In this tutorial I will explain how to make a Shamrock Badge for St. Patrick’s Day using the Appearance Palette in combination with some simple effects. The result will be a reusable dynamic badge effect. You are welcome to try this with any shape or colors.

 

Final Image Preview

Below is the final Graphic Style we will be working towards.

Tutorial Details

  • Program: Illustrator CS4
  • Difficulty: Beginner
  • Estimated Completion Time: 30 minutes
Tags: , , , , , , , , , , ,

POST Validation Loop

ons, mar 3, 2010

Kommentarer slået fra

Assumptions

You have an HTML form with a variety of inputs. The action attribute of the form points to a PHP file that contains the code below.

Notes about code

This code starts by creating an array that holds the name of various inputs being submitted via a POST. getFormData() is then called, where the required fields are passed in. Inside the function an array is created to hold various pieces of data related to the form. $formData['valid'] is a boolean referencing if all data was provided and valid, $formData['fields'] is an array keyed by the name of the input with their respective value from the POST data, $formData['notValidFields'] is an array that will contain the names of any inputs that were not passed or that had non-valid data.

Tags: , , , , , , , , , , ,

Sanitize Database Inputs

ons, mar 3, 2010

Kommentarer slået fra

1) Function for stripping out malicious bits

<?php
function cleanInput($input) { $search = array( '@<script[^>]*?>.*?</script>@si', // Strip out javascript '@<[\/\!]*?[^<>]*?>@si', // Strip out HTML tags '@<style[^>]*?>.*?</style>@siU', // Strip style tags properly '@<![\s\S]*?--[ \t\n\r]*>@' // Strip multi-line comments ); $output = preg_replace($search, '', $input); return $output; }
?>

2) Sanitization function

Uses the function above, as well as adds slashes as to not screw up database functions.

Tags: , , , , , , , , , , , , ,

All About Transformation in Adobe Illustrator

ons, mar 3, 2010

Kommentarer slået fra

In this tutorial you will learn everything you ever wanted to know about one of the most powerful Adobe Illustrator Tools – Transformation. Discover how it works, learn multiple ways of transforming objects, study the tools of transformation, and many other useful techniques.

 

Tutorial Details

 

  • Program: Adobe Illustrator CS3
  • Difficulty: Beginner
  • Estimated Completion Time: 30 minutes

Introduction

Illustrator has plenty of tools, panels, and commands that make our work much easier. Among them, however, there are several outstanding ones that I personally consider the most important features of this program. They include brushes, the Appearance panel, Effects, and, of course, transformation.

Tags: , , , , , , , , , , , , , , , , , , , , , , , , ,

Displaced Text

ons, mar 3, 2010

Kommentarer slået fra

Displaced Text

In this Photoshop tutorial I would like to show you creative way how to displace the text and get an interesting effect on it.

 

To start create a new document sized 1000×500 pixels and fill it with color of #f4f4f4.

Displaced Text 01

After that add some dark line to divide the floor from the wall. Get out the Elliptical Marquee Tool and create selection as shown on the picture which you can see below. Then fill this selected area with black to transparent gradient.

Displaced Text 02

Tags: , , , , , , , , , , , , ,