jQuery is not always as it appears. There’s a lot of cool stuff going on under the surface, and there are many methods just waiting to be discovered, and many potential usages of jQuery’s API that you may not have considered before. In this article I’ll be taking you through a few of the not-so-obvious [...]
Continue reading...onsdag, marts 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 [...]
Continue reading...onsdag, marts 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 [...]
Continue reading...torsdag, februar 25, 2010
Kommentarer slået fra
It has been a while since we’ve done a proper PHP & MySQL tutorial here, So today we are creating a simple, yet robust, file download tracker. Each file will have a corresponding row in the database, where the total number of downloads is saved. PHP will update the MySQL database and redirect the visitors to [...]
Continue reading...torsdag, februar 25, 2010
Kommentarer slået fra
This snippet presupposed an HTML form with and ID of “age-form” and three inputs (text or select) with the IDs “day”, “month”, and “year” respectively. $("#age-form").submit(function(){ var day = $("#day").val(); var month = $("#month").val(); var year = $("#year").val(); var age = 18; var mydate = new Date(); mydate.setFullYear(year, month-1, day); var currdate = new Date(); currdate.setFullYear(currdate.getFullYear() [...]
Continue reading...torsdag, februar 18, 2010
Kommentarer slået fra
It’s very important to secure your data in PHP correctly. Because if you don’t, your website is in risk of being harmed by SQL injections and other dangerous code injections, which you obviously don’t want. So to protect your website against these code attacks, this tutorial was written ;) This tutorial will explain the reasons to [...]
Continue reading...torsdag, februar 18, 2010
Kommentarer slået fra
We all are quite familiar with Adobe Illustrator and its User Interface. In our daily creative tasks we use a lot of features, such as: menu, pallets, colors, plug-ins and tools. We use these features in the form of a UI. These UI features are brought forward to us through various scripts and plug-ins. In a [...]
Continue reading...tirsdag, februar 16, 2010
Kommentarer slået fra
An unobtrusive login system is one that gets out of the user’s way. It will make your application nicer and more polished. This article will guide you through the process of setting up user logins, then ajaxifying the process by moving the form into a modal box that communicates with the server. Additionally, this article [...]
Continue reading...mandag, februar 15, 2010
Kommentarer slået fra
A couple of weeks back we went through the process of creating a gnarly snowboarding themed website design concept in Photoshop. The tutorial covered the process of designing our site concept from sketch to finished PSD design. Now, let’s take the design to the next step and code up a complete mockup in HTML and [...]
Continue reading...lørdag, februar 13, 2010
Kommentarer slået fra
This code is useful for multi environment setups (staging, production, etc.) it allows you to keep your htaccess files in sync while maintaining an htpasswd on your development environment or anything but the live environment. #allows a single uri through the .htaccess password protection SetEnvIf Request_URI "/testing_uri$" test_uri #allows everything if its on a certain host SetEnvIf HOST [...]
Continue reading...
tirsdag, marts 9, 2010
Kommentarer slået fra