Ajaxorized

Another creative way to prevent bots from stealing your email addresses

January 15, 2008

The following code (using prototype) prevents bots stealing the emailaddresses used on your website. Instead of including the emailaddress directly, use a div with a classname where the email-address needs to be placed:

Hi Bot! My email address is  <div class = "email_here"></div>!! Catch me if you can!

Then, use javascript to replace the email address after the page is loaded:

$$('.email_here').each( function(e) {
  e.update('willem'+'@'+'ajaxorized.com').observe('click', function() { window.location = 'mailto:willem'+'@'+'ajaxorized.com'; }).setStyle({cursor:'pointer'});
	});

Mind the concatenation that is used to prevent stealing from your javascript file. Include this piece of code in your body onload event and no bots will ever steal your email addresses again!

Add to: del.icio.us Reddit Slashdot Digg Facebook Technorati Google StumbleUpon Windows Live Yahoo
topFiled under: Uncategorized, Ajaxorized, Javascript, HTML | Willem @ 6:00 pm | Comments (3)

$happy = new Year();

January 4, 2008

I know we are a bit late, but all the best whishes and geekluck in the year 2008!

Add to: del.icio.us Reddit Slashdot Digg Facebook Technorati Google StumbleUpon Windows Live Yahoo
topFiled under: Uncategorized | Willem @ 12:04 pm | Comments (0)

3d image reflection with javascript

November 5, 2007

ReflectionAfter the image transisition manager we released last week, this week an image reflection script, using unobtrusive javascript. By adding a small piece of javascript to your code you can create this stunning effect. It offers a solution that is:

  • Not involved with Flash, or
  • with CSS, and
  • cross browser (Tested in Firefox, Opera and IE)
  • Preloading the images before reflection

Here is a demo on black and on white.
(more...)

Add to: del.icio.us Reddit Slashdot Digg Facebook Technorati Google StumbleUpon Windows Live Yahoo
topFiled under: Uncategorized, Scriptaculous, Javascript, HTML | Willem @ 10:42 pm | Comments (9)

Martijn joins the team!

October 18, 2007

From now, the number of ajaxorized team members is upgraded to 2, since Martijn joins the team. Martijn and I met in our universities masters program and share the same passion for informatics, web development, javascript, PHP and, of course, black coffee. So, a warm welcome to Martijn!

Add to: del.icio.us Reddit Slashdot Digg Facebook Technorati Google StumbleUpon Windows Live Yahoo
topFiled under: Uncategorized | Willem @ 11:52 am | Comments (0)

Top 5 HTML5 Resources

August 29, 2007

In a few years, we (as in web developers) will no longer be speaking the language of (X)HTML4(.01). We will no longer speak the language of <div>'s. No, in a few years, we will no longer be partying like it's 1999. HTML5 (or Web Applications 1.0 as people call it who use the Web 2.0 phrase as well) is on it's way. Since three major Browser vendors (Mozilla, Apple and Opera ) came together as the WhatWG (Web Hypertext Application Technology Working Group) to construct the new HTML standard, the basic thought of the extended HTML version becomes more and more clear. Backwards compatibility width HTML 4.01 and XHMTL 1.1, more specific elements to fulfill the needs of web applications (instead of using <div> for every single one of them), <audio> and <video> tag support, the <dialog> element to describe conversations and many more functionalities. Sounds promising, isn't it?

(more...)

Add to: del.icio.us Reddit Slashdot Digg Facebook Technorati Google StumbleUpon Windows Live Yahoo
topFiled under: Uncategorized, HTML | Willem @ 5:29 pm | Comments (0)

Include Google Analytics in your static HTML website

July 10, 2007

A few months ago I was assigned to a project where a company, while their new site was being developed, wanted to track the visitors on their website for marketing purposes. The only problem was that their current website was constructed with Frontpage a few years ago and consisted of hundreds of static HTML pages. Since I'm (very) lazy I was not planning to copy paste the whole thing, I figured out a way to include the GA code in every static html page.

First, I wrote a .htaccess file which rewrites all (including files in subdirs) .html and .htm pages to addgoogleanalytics.php:

RewriteEngine on
RewriteRule ^(.*).html?$ addgoogleanalytics.php?file=$0

Wow, it that all? Yes it is. So helloworld.html will be rewrited to addgoogleanalytics.php?file=helloworld.html, and the user won't even notice. Now, take a look at addgoogleanalytics.php:

<?php
/* Open the given file and add the google analytics code */
$sData = file_get_contents($_GET['file']);
$sData = str_replace("</body>", "
<script src=\"http://www.google-analytics.com/urchin.js\" type=\"text/javascript\">
</script>
<script type=\"text/javascript\">
_uacct = \"UA-1808705-3\";
urchinTracker();
</script>
 
</body>", $sData);
echo $sData;
?>

Enjoy.

Add to: del.icio.us Reddit Slashdot Digg Facebook Technorati Google StumbleUpon Windows Live Yahoo
topFiled under: Uncategorized, PHP, Apache, Code | Willem @ 12:10 pm | Comments (1)

ajaxorized.start();

July 5, 2007

Ignition, takeoff, we're started! Enjoy!

-Will

Add to: del.icio.us Reddit Slashdot Digg Facebook Technorati Google StumbleUpon Windows Live Yahoo
topFiled under: Uncategorized | Willem @ 1:11 pm | Comments (1)