My name is Edward Tanguay. I am a web developer in Berlin, Germany. I learn everything I can and record it on this site.
Other things you might be looking for:
My Ubuntu Tutorial
My Datapod Project
My Blog Feed:
More on SMIL:  wiki.en  wiki.de  wiki.fr  google  blogs  amazon.com  amazon.de  
SMIL
Most Recent Items
Do Session: Setup with Issues IV
3 D F L E X   D O   S E S S I O N  
Installed on another computer with Flex 2 and got the same flash problem as last time, found fix, but now have Papervision specific problems.
post comment or question
Tutorial: How to Create a Website with Datapod
DATAPOD TUTORIAL - updated on August 31, 2007
Datapod is a free PHP framework which helps you make quick databased-backed websites. 1. Download Datapod  2. Customize Your Site  3. Create a DataItem  4. Make Display Page for DataItem  5. To Be Continued 
Tutorial: Install Java on Windows XP and Learn the Basics of Java 6 using the NetBeans IDE
JAVA TUTORIAL - updated on August 4, 2007
This tutorial shows you how to install the Java 6 JDK on Windows XP and teaches you how to write a HelloWorld example in Java by using the NetBeans IDE. 1. Download Java  2. Install Java  3. HelloWorld at command prompt  4. Download and Install NetBeans  5. HelloWorld in NetBeans  6. Arrays  7. Multidimensional Arrays  8. ArrayLists with Generics  9. HashMaps with Generics 
Do Session: Setup with Issues
3 D F L E X   D O   S E S S I O N  
Got things set up but there were a number of issues that need to be cleared up.
post comment or question
Tutorial: Install OpenSuse 10.2 in VMWare on Windows XP and connect it to your network
LINUX TUTORIAL - updated on July 4, 2007
This tutorial shows you how to download a trial version of VMware, download the free OpenSuse DVD, install Suse on your VMWare machine, then download and install the free VMware Player and connect your virtual Linux machine in your network so that you always have a Linux machine in your network at your disposal, great if you are learning Linux. 1. Download VMware Workstation Trial  2. Install VMware on Windows XP  3. Download the OpenSuse DVD  4. Create an Empty Virtual Machine  5. Make your ISO file be the virtual machine's CD drive  6. Install Suse Linux on the virtual machine  7. Get Online  8. Set resolution to 1024 x 768  9. Make icons normal size  10. Deinstall VMware Workstation  11. Download and Install VMware Player 
Tutorial: Install a PHP Development Environment with Eclipse PDT, Apache 2.2, PHP 5, MySQL 5, and phpMyAdmin Using XAMPP Lite
PHP TUTORIAL - updated on February 9, 2011
This tutorial shows you how to get a PHP development environment set up on Windows in about 30 minutes including download time, all with free tools. This is the FAST, JUST-GET-IT-DONE way to get PHP and MYSQL working on your computer and get up to speed working with Eclipse so you can start developing PHP/MySQL sites. (You might also be interested in my more technical version of this tutorial where you install Apache, PHP, MySQL manually and make dozens of settings in the config files thus learning lots about how it all works, etc.) 1. Install 7-Zip  2. Install XAMPP Lite  3. Install Java  4. Install Eclipse  5. Make PHP Page  6. Use phpMyAdmin  7. Access MySQL from PHP  8. Make Font Smaller  9. Code Assist Features  10. Templates  11. Other Eclipse Features  12. Debugging  13. Make Your Development Environment Portable 
Tutorial: Install Perl 5 on Windows XP and Get a Perl Hello World Running
PERL TUTORIAL - updated on July 20, 2007
This tutorial shows you how to install Perl 5 on Windows XP and get a Hello World program going so you can start learning and trying out examples of Perl. 1. Download Perl  2. Install Perl  3. Create Hello World program  4. Learn More 
Tutorial: Install Fedora 6 in VMWare on Windows XP and connect it to your network
LINUX TUTORIAL - updated on June 21, 2007
This tutorial shows you how to download a trial version of VMware, download the free Fedora CDs, install Suse on your VMWare machine, then download and install the free VMware Player and connect your virtual Linux machine in your network so that you always have a Linux machine in your network at your disposal, great if you are learning Linux. 1. Download VMware Workstation Trial  2. Install VMware on Windows XP  3. Download the Fedora DVD 
Do Session: Setup with Issues II
3 D F L E X   D O   S E S S I O N  
Got right project this time but it can't find c:\Papervision.
post comment or question
Do Session: Setup with Issues III
3 D F L E X   D O   S E S S I O N  
Was able to download files with Tortoise but (a) I still get a black screen and (b) there seems to be something wrong with my flash player for debugging.
post comment or question
Code Example: File that shows how all PHP 5.2 input_filters work.
PHP CODE EXAMPLE - added on November 18, 2008
This file runs through the input filters codes and shows how e.g. filter_var($value, FILTER_SANITIZE_STRING) and filter_input($value, FILTER_SANITIZE_STRING) will alter strings. You can see an example this here..
SHOW CODE

post comment or question
Code Example: How to create a PHP Webservice with nusoap and consume it with nusoap and PHP5's SoapClient()
PHP CODE EXAMPLE - added on November 18, 2008
Nusoap is convenient because you don't have to make any changes on the server, just download and copy the library files to a sub-directory. Nusoap also creates a WSDL file automatically for you. These examples show how to return an array of values so that you could, e.g. return 20 fields of information about a user, for instance. Not that on the nusoap examples I turn the cache off since when you have it on while you are developing and add a method to your soap server, your client doesn't recognize the changes. First download nusoap, then copy the files to a sub-directory on your web called "nusoap".
SHOW CODE

post comment or question
Code Example: Use define() for tedious-to-type constants
PHP CODE EXAMPLE - added on November 13, 2008
Stumbled across this use of define() today, nice for HTML tag and newline shortcuts etc.
SHOW CODE

post comment or question
Code Example: Develop Flash Applications without Flash with free Flex SDK and free FlashDevelop editor
FLEX CODE EXAMPLE - added on November 8, 2008
The following instructions show you the exact steps to set up a free development environment on windows which allows you to develop Flex applications with ActionScript 3. You won't have the nice step-through debugging or the design view of Adobe's FlexBuilder but this code shows you how to create a two-line MXML file which allows you to do all your programming back in ActionScript 3 classes anyway so you just kind of use the MXML file as a tunnel to be able use the rich Flex libraries. FlashDevelop has very nice code-completion and other features, and with traces you can do decent debugging. The code helps you get up to speed with event handlers which are a bit different than web scripting if that is all you have been doing so far. You can view a running example of this appliction here.
SHOW CODE

post comment or question
Code Example: How to set up a Flex application in FlashDevelop (with code completion)
ACTIONSCRIPT 3.0 CODE EXAMPLE - added on October 23, 2008
This works much better than my previous example since it enables FlashDevelop to do its nice code-completion on Flex objects such as "button". In FlashDevelop, new project, Flex, Flex 3 Project, then replace MXML code, then create a class and put in the ActionScript3 code.
SHOW CODE

post comment or question
Code Example: How to set up a Flex application in FlashDevelop
ACTIONSCRIPT 3.0 CODE EXAMPLE - added on October 23, 2008
In FlashDevelop, new project, Flex, Flex 3 Project, then replace MXML code, then create a class and put in the ActionScript3 code. Unfortunately it doesn't seem to have the nice code complete completion for e.g. the button object.
SHOW CODE

post comment or question
Code Example: Text-Follow-Cursor example using simple sprite
ACTIONSCRIPT 3.0 CODE EXAMPLE - added on October 22, 2008
In FlashDevelop, New Project, AS3 Project, (check Create directory for project), (Project/Properties/Text Movie/Play in popup), then open up Main.as and replace it with this code.
SHOW CODE

post comment or question
Tip
tip
WINDOWS TIP - added on October 13, 2008
I wanted to install Visual C# 2008 Express but knew I wanted to try out the Visual Basic and Visual Web Developer as well, so instead of doing three downloads from the web, I downloaded the .ISO file with all four of them on it, then downloaded the free Virtual Clone Drive which after you install it looks like you added a DVD drive to your system, right-click it and select Virtual CloneDrive and Mount, then navigate to and select the .iso file and it is as if you are loading from a DVD, nice, much smoother solution then one I was using back in 2002 -- it just works.
Custom Images/item Types/tips/virtual Clone Drive.png
post comment or question
Tip
tip
ECLIPSE TIP - added on October 9, 2008
Create hotkey macros in Eclipse 
I've been using Eclipse for a long time and just found out that you can create a hotkey to perform all kinds of mundane tasks, e.g. if you find yourself committing a file every minute or so to check minute changes, go to Preferences | General | Keys and set up a e.g. CTRL-ALT-SHIFT-C to commit your file, explore this for awhile and save some time in the long run.
Custom Images/item Types/tips/key Combinations.png
post comment or question
Tip
tip
PHP TIP - added on September 19, 2008
Tired of editing long lines extending out to the right in Eclipse? This plugin solves the problem, install as any plugin in Eclipse, restart, then right click and word wrap, simple as that.
post comment or question
Code Example: A quick MySQL data layer class that makes read/writes one-liners
PHP CODE EXAMPLE - added on September 18, 2008
If you need to write a quick PHP script that accesses a MySQL database, just copy in or include this class and you can do all your reads and writes with one-line satements.
SHOW CODE

post comment or question
Tip
tip
GENERAL TIP - added on September 15, 2008
Stackoverflow just launched publically today after being in beta for about two months. Last week I posted about 8 questions about vim and Perl and each question was answered by multiple people within 10 minutes. The site has a system of badges and reputation points you can earn for various things which turns people into hungry dogs waiting to answer your question first. You get to read the answers and mark them up and down based on their helpfulness and then select one that best answers your question. This site is truly unique, new, fresh, ajaxy in the right places, and very efficient, try it out.
Custom Images/item Types/tips/stackoverflow.png
post comment or question
Tip
tip
PERL TIP - added on September 12, 2008
Always put "my" in front of variables inside functions 
In Perl, if you define a variable inside a function without the word "my" (e.g. @record = ...), then that variable is treated as a global variable (wow!). Hence, always define function variables thusly: "my @records = ...." inside a function so that they do not change values outside the function, e.g. if you have too recordsets and you use the same variable name "@records" to loop through them.
post comment or question
Code Example: Four Simple Perl database functions for MySQL
PERL CODE EXAMPLE - added on September 10, 2008
Was on a Perl project where the code had 5 lines of database connection code for each time it needed to get data from the database, so I wrote these functions which allow you to get records, record, value or execute a command with one-liners. Records are an array of hashes and included the code to call the functions since figuring out what syntax you need to access the objects through pointers/references can be time-consuming. End result is: if you just need to use Perl quick to read and write to a MySQL database, this code will get you up to speed fast.
SHOW CODE

post comment or question
Code Example: Basic database read and text file read/write code in Perl
PERL CODE EXAMPLE - added on September 2, 2008
If you need to do something quick and useful in Perl, this will get you reading and writing in databases and text files. If you are a PHP programmer getting into Perl then look up the "eq" operator first.
SHOW CODE

post comment or question
Code Example: Large button links with A elements
CSS CODE EXAMPLE - added on August 12, 2008
Many times you want to have a menu with A elements as the links instead of e.g. LI elements. Here is an example with large buttons. See example here.
SHOW CODE

post comment or question
Code Example: How to check if an IP-address is within the range of two IP-addresses
PHP CODE EXAMPLE - added on July 17, 2008
This function checks if an IP address is between two others, not that ip2long has a problem by itself so you need the sprintf("%u") function as well. Also it returns false if any of the IP addresses are invalid as to avoid tampering.
SHOW CODE

patryksharks: shouldn't it be preg matches? greetings
arrow pointing right
reply
post comment or question
Tip
tip
FIREFOX TIP - added on July 6, 2008
I installed Firefox 3 today and instantly found the search-history-in-the-URL-bar to be indispensible. All the more to my horror did I realize that Firebug was no longer installed because it was not compatible with Firefox 3. Luckily there is a beta being built that IS compatible and it works just like the old one. The SQLite Manager and Web Developer bar still work in Firefox 3 and so with these three, no reason not to upgrade! Enjoy.
Custom Images/item Types/tips/firebug.png
post comment or question
Code Example: Javascript photo-viewer that works in four browsers
JAVASCRIPT CODE EXAMPLE - added on July 6, 2008
This was a little experiment to get a useful base of cross-browser code that does some interactive stuff in Javascript. It is simple but handles mouseover, button highlight, and just has a nice, basic feel. The only issue is in Opera the text is at top of the buttons, but didn't have any nerves left for that one. At first I tried using :hover and :focus which brought me to the conclusion that this really isn't standard between the browsers so used onmouseover and onmouseout to deal with it. Also worked out a number of quirks that various browsers had, e.g. I removed the ugly dotted focus line in Firefox on the buttons, they left it there in Firefox 3 as well I noticed, I replaced it with a gradient background for the focussed button. So this code looks decent in Firefox 2/3, Internet Explorer 7 (probably 6 too), Opera 9.5 (in fact only after I upgraded from 8 did it show the background on the buttons), and Safari. The bad boy of the group is Opera, but since opera gets embedded in quite a number of devices these days (e.g. Philips TVs), you don't want to leave it out completely. You can view this example online here. Of course next step when implementing this is to make it read from a database or XML file, I just wanted to get the browser-compatibility as accurate as possible first.
SHOW CODE

post comment or question
Tip
tip
JAVASCRIPT TIP - added on July 3, 2008
If you are getting into AJAX and need a booster course on Javascript, this site has a nice concept/example format to get you up to speed fast without the make-the-background-color-blink examples you get on other sites. Note the "AJAX for N00bs" section as well.
post comment or question
Code Example: How to display random quotes with Javascript.
JAVASCRIPT CODE EXAMPLE - added on July 3, 2008
This code uses the setInterval method to call a showQuote() function every 7 seconds, check out the online example.
SHOW CODE

TooTall: just curious why the first set of quotation marks are covered by some letters...and if there is a way to fix this? reply
post comment or question
Code Example: How to set simple cross-browser Javascript event handlers
JAVASCRIPT CODE EXAMPLE - added on July 1, 2008
This code runs in Explorer, Firefox, Opera and Safari, simple code that enables you to attach Javascript functions to button clicks, etc.
SHOW CODE

post comment or question
Code Example: How to use an .ini file with constants for e.g. translations
PHP CODE EXAMPLE - added on June 30, 2008
If you have various translations of your website, a quick way to implement this is to have an .ini file with all the translations in it and read it out. This code shows you how to also use constants within the ini file.
SHOW CODE

post comment or question
Code Example: How to position text in a div with left and right areas
CSS CODE EXAMPLE - added on June 30, 2008
This CSS script give you absolute pixel-exact control of where to place text in a left and right area of a wide div, e.g. a header or footer. I was not able to get it to align automatically, e.g. left/center/right, so you have to know your font size and your text and position things exactly, but at least you have control, checked in Firefox and Explorer.
SHOW CODE

patryksharks321: nice code btw relative is according to the last element and absolute is towards the block it's in right? greetings
arrow pointing right
reply
post comment or question
Tip
tip
GENERAL TIP - added on June 25, 2008
I've been recently downloading and listening to some great IT talks from the Conversation Network, talks by e.g. Rasmus Lerdorf founder of PHP, Mark Shuttleworth, founder of Ubuntu, even things that are on the edge of technology such as stuff going on in Biology and other sciences, really interesting talks by some key people in the industry, I've listened to about 5 and they've all been good. They have a nice format: you sign up to their RSS feed and just download the ones you want straight onto your MP3 stick and go. The free MP3s have a plug to sign up at the beginning and the end but you can download and listen to anything you want. After you download one, you get an email to review it the next day and in one click you can say how you liked it, which I assume gives good feedback so the best float to the top. If you have a lot of listen/wait time in your daily life, this is a great way to stay up on the latest in the IT space.
post comment or question
Tip
tip
PHP TIP - added on June 19, 2008
EditPad Lite has been my text editor of choice for a long time since it is free and has an easy time-stamping feature (ALT-E-I) and you can set the time format. But it used to have a nasty habit of always writing a BOM to the beginning of UTF-8 files which PHP 5.2 can't deal with. I always had to go into jEdit and save the UTF-8Y file again as UTF-8. But just in March EditPad Lite came out with a new version that allows you edit UTF-8 files without the BOM characters at the beginning and and EditPadLite will *leave it this way*, very nice. This means that if I need to make a quick change to a PHP file, I don't have to fire up and wait the 15 long seconds for Eclipse to commence: I simply pop into EditPadLite and edit it without fear of adding a BOM (hmm, interesting that it sounds like "BOMB" since that is exactly what it does to your PHP file, nice). In any case, EditPad Lite is now an ideal free text editor to edit any kind of text file in any encoding and to convert to and fro between the various encodings (e.g. between Windows 1252, ISO-8859-1, and UTF-8). You have the option to simply change the encoding setting of a file but not translate the characters or you change the encoding setting of a file and translate the characters as well--just the tool you need when you find yourself in encoding hell.
Custom Images/item Types/tips/editpadlite2.png
post comment or question
Code Example: How to apply a simple filter to a label
FLEX CODE EXAMPLE - added on June 13, 2008
You can do a lot more with filters, e.g. dynamically change them in ActionScript but here is the syntax for a basic shadow filter on a text.
SHOW CODE

Johann: Hello, I'am very new to Flex 3 and programming but like it a lot. I've a ne question: i'am using multiple hsliders and the sum of the values of those sliders may not be over 100(%), so when the first slider value=60 the second slider is limited to value=40. What AS function do I need to achieve this?
arrow pointing right
reply
post comment or question
Code Example: Example of using CSS styles in Flex Builder
FLEX CODE EXAMPLE - added on June 13, 2008
Check out this example here. This shows you the basics of using styles in flex, I did all of this with the FlexBuilder in design mode, very easy to use, when you are in a CSS file just click on design. The alpha transparency is wonderfully easy and the background picture leaves behind all the problems you have with page backgrounds in HTML/CSS, namely, it constantly resizes it, etc.
SHOW CODE

post comment or question
Tip
tip
FLEX TIP - added on June 13, 2008
Flex Builder 3 has a design mode for CSS style sheets 
When you are in a CSS file in Flex Builder 3, you can click on the Design button and see your styles as they will appear. You can change them and the CSS code will change in the background, it gives a library/symbol feeling to CSS files, nice.
Custom Images/item Types/tips/css Design Mode.png
post comment or question
Tip
tip
ECLIPSE TIP - added on June 12, 2008
Code completion for PHP templates 
When you make a PHP tempalte (like a macro) with Windows|Preferences|search for "templates"|PHP Templates, and you include $$${variable} in your template text, you will be presented with a dropdown of all available variables in the context where you call your template, nice.
Custom Images/item Types/tips/template Code Completion.png
post comment or question
Code Example: How to use ActionScript to access file system in AIR
FLEX CODE EXAMPLE - added on June 11, 2008
This is another example of access filesystem this time with ActionScript. Did an expanding window in this example, but there are some scrolling issues on this window I need to work out, couldn't find a scrollable=false in the application element. To try this example, download adobe air and then you can install this application.
SHOW CODE

Pramod: Is it possible to access the File System in Flex web application, not AIR? If it is, how it is done? FileSystem type is not recognized in a Flex web application. I want to upload a file in Flex web application? Need Help. Thanks in advance...
arrow pointing right
reply
post comment or question
Tip
tip
FLEX TIP - added on June 10, 2008
Flex allows you to comment out attribute values 
Flex Builder is full of surprises, here is another uncommon but useful feature: two slashes in front of an attribute value comments it out. ...addendum: any variable after the line with the double-slash will not be recognized in code complete = bug. oh well, 1 point for ingenuity.
Custom Images/item Types/tips/uncomment Attributes.png
post comment or question
Code Example: Basic file access example in AIR
FLEX CODE EXAMPLE - added on June 10, 2008
This shows you the basics of getting access to files and directories with AIR using FileSystemTree and FileSystemDataGrid. Would be interesting to see how these work in Linux and Mac. To try this example, download adobe air and then you can install this application.
SHOW CODE

post comment or question
Code Example: Basic syntax for Windows in AIR
FLEX CODE EXAMPLE - added on June 10, 2008
Here's how to get started with windows in an AIR application.
SHOW CODE

post comment or question
Code Example: How to add a custom icon to a button
FLEX CODE EXAMPLE - added on June 7, 2008
View the example here. The graphic is png with transparency and you see that it lets the background of the button show through.
SHOW CODE

post comment or question
Code Example: How to handle a custom component with a custom event
FLEX CODE EXAMPLE - added on June 7, 2008
Check out the example here. This shows you how to make a custom component (LanguageSelector) that you call from your main MXML file. The component throws a custom event which you handle externally in your main MXML file as well.
SHOW CODE

Udayan: Can you please let me know, if the code for LanguageSelectedEvent.as you mistakenly put the code of LanguageSelector.mxml. As both LanguageSelector.mxml and LanguageSelectedEvent.as looks same.
arrow pointing right
reply
post comment or question
This site was made with Datapod.