Toronto web design - 3magine Inc.

1 (866) 365 2407

Levitra online Vicodin Online Propecia online

Labs

Currently Viewing: Web Applications

Camel Case Spaces

Cialis online
Vicodin online
Cialis online

Web development is all about having fun, so let’s have some fun with camel case strings.

function camelCaseSpaces($s){
    return trim(preg_replace("/[A-Z]/",' ${0}',$s));
}

Using this custom function you can now convert strings such as “iAmSuperCamelCaseString” to “i Am Super Camel Case String”. One day while working on a CodeIgniter project, I needed a quick access to list links to all available methods in one specific controller where most of the methods where in a camelCase format.  To achieve my goal I came up with the above function and the following sneaky code within the “index” method of a controller named “Buildout”:

//Get all method names:
$m=get_class_methods($this);

//Unset the ones I do not need:
unset(
$m[array_search('index',$m)],
$m[array_search('__construct',$m)],
$m[array_search('get_instance',$m)]
);

//Print all links to my methods:
foreach($m as $n)
   print '<href="/buildout/'.$n.'">'.ucwords(camelCaseSpaces($n)).'</a><br />';

Thanks for reading and feel free to re-use this neat trick.

BattleBlasters for the iPhone

Vicodin online
Cialis online

Memorial day
Memorial day 2010

Instead of writing an in-depth review, let me just say that along with Zenonia and Inotia this is my new favorite iPhone game. Super addictive, and super fun. Here’s a video preview.


Get it on iTunes, http://itunes.apple.com/us/app/battle-blasters/id344610797?mt=8

Mootools wrapInner

Cialis online
Cialis online
Cialis

Adderall online
Cialis online
Viagra online

Today I worked on a project which was using jQuery and have encountered a nifty little function called wrapInnner. What it does is wraps the html contents of the element calling it with the element that is being passed to the function. Here’s a very simple jQuery example:

<div id="user">My name is Pedro</div>
$('user').wrapInner($("<span class='red'></span>"));

will produce:

<div id="user"><span class="red">My name is Pedro</span></div>

I’ve tried doing the same in mootools using Element.wraps but it doesn’t accept html, it only accepts the id of an element or an element itself. There was no other Element method that could accomplish this task so I decided to write one.  And here goes the implementation of wrapInner for Mootools:

Element.implement({
     wrapInner:function(e){
          this.clone(false,true).adopt(
               $(e).set('html',this.get('html'))
          ).replaces(this);
     }
});

and the same example using mootools wrapInner:

<div id="user">My name is Pedro</div>
$('t').wrapInner(new Element('span',{'class':'red'}));

will produce:

<div id="user"><span class="red">My name  is Pedro</span></div>

The above implementation is very simple, it does not accept function as a parameter but it does accept an id or element.

Google keyword tool. Search engine position tracking.

We’ve been working on a custom built application to track google search engine position over time. The application lets you enter any amount of keywords or phrases, set an interval time to scan, and graph keyword position changes over time. We think the application will be particularly interesting to those who wish to see the progress over time of their search engine campaigns, or search engine marketing. Here is a little teaser.

The application will be released to the public in a few weeks time. We’re still working out some kinks and trying to establish a competitive price plan. The application will also be extended to not only include Google, but other major search engines as well.

Tags: , ,

Thursday, March 12th, 2009 Web Applications 2 Comments

To-Do List web based application

A while ago we started working on a custom To-Do List web based application. We realize there is an abundance of these available online, however we find they are either too complex, too bloated, or not usable enough. We haven’t had a chance to work on this for some time, but we’ll be getting back to it, and hope to produce a very simple and usable To-Do List web based application. Here is a little teaser screenshot.

To-Do List Web Based Application teaser screenshot

Tags: , ,

Sunday, November 16th, 2008 Web Applications 3 Comments