17 Apr 2009
09:36

Javascript:number_format()

Here’s a little javascript to format numbers like the PHP function “number_format” :

function number_format (number, decimals, dec_point, thousands_sep){
var decimals = decimals ? decimals : 2,
dec_point = dec_point ? dec_point : ‘.’,
thousands_sep = thousands_sep ? thousands_sep : ‘ ‘;

var left = parseInt(number, 10),
right = parseInt(number.toString().replace(/^\d+\.?/, ”), 10) || 0;

left = left.toString().split(”).reverse().join(”)
.match(/\d{3}|\d{1,2}/g)
.join(thousands_sep)
.split(”).reverse().join(”);

right = right.toString().replace(new RegExp(’^(\\d{0,’+decimals+’})\\d*’), ‘$1′).toString().split(”);

if (right.length < decimals) for (var iRight=right.length; iRight<decimals; iRight++) right.push(’0′);
right = right.join(”);

return left+dec_point+right;
}


13 Sep 2008
21:01

A nice day

I was at Kilo café today programming and drawing for hours before noticing that I had spent more than 6 hours there, hehehe.

I was working on a small script for the new version of my blog (I hope I’ll finish it soon, I’m soo tired of my present design) and I got really into it (yes, I’m a geek and don’t mind it). After a while, I felt like I needed to draw and that’s exactly what I did. It was funny, because Daniel (a guy who works there) was really amazed by my tabletpc with the touch screen. He wants to work in 2D animation and really liked the idea of the touch screen (and I totally agree with him, I LOVE my laptop).

I think I only have 2 or 3 more little scripts I need to do and fix some bug with my new design and soon it will be online.

For my drawings, here’s the two I did today :

Me, Maxime LefrancoisCute doggy!


30 Jul 2008
15:26

New design coming up!

Soo, I’m almost finished with my new blog design. It’s going to be ….. orange! I might end up making more than one version of the site (you’ll be able to change the main color), but I’ll try to keep it as simple as I can.

I’m quite happy with what I came up, I just need to fix one or two things and then I can start integrating the design.

soon soon soon!! I can’t wait!!

After the new design is up, I’ll start adding content on a regular basis for real this time.


11 Jul 2008
08:27

Nouveau design à venir

Bon, je suis pas totalement content sur mon design présent, donc je vais complètement le changer. Ça va être beaucoup plus simpliste.

L’idée de base est d’utiliser une couleur principale (en l’occurence, ce sera l’orange) et de donner au contenu beaucoup d’espace. Déjà, les premières ébauches sont plutôt intéressantes et je crois que je vais être beaucoup plus satisfait avec le nouveau design que celui que j’ai pour l’instant.


16 Jun 2008
12:38

J’oublie tout le temps

Hier je suis allez à la plage du lac l’Achigant pour une belle journée entre amis. Nous avions rien oublié à emmener (costume de bain, frisbee, petit lunch, crème solaire, …) et la journée était parfaite.

En gros, il y a eu un peu de “shopping” aux Wallmart (bon j’avoue, j’avais oublié mes sandales), un peu de soleil, un peu de baignade, un peu de frisbee, une bonne poutine à 4, du mini-pot et finalement une bonne crème glacé.

La seul chose que j’ai oublié dans tout ça (et que j’oublie tout le temps), c’est que comme je conduis la voiture et que j’accote mon bras sur le rebord de la fenêtre, je ne pense jamais à me mettre de la crème solaire! Donc, l’été est finalement arrivé et les coups de soleil aussi … malheureusement.

Du moins, j’espère que tout le monde a profité pleinement de leur fin de semaine!


7 Jun 2008
17:07

Some freelance work for a hair salon

Illusions new website

I’ve started working on a website for a hair salon here in Montréal. I’ve just finished the main draft and I have to say I’m quite happy with it, considering I’m a programmer and not a graphic designer (far from it).

Just to add a little wwwWOOOOW to the design, I’ve been searching for ideas on the web. I’ve check some other hair salon website in Montréal and I’ve got to say …. they look really bad. There’s this site that I used to get some ideas and I just ended laughing at most of the sites.

Finaly, I decided to use smashing magazine for this little wwwWOOOOW effect I want to add. Most of the showcase there are not about hair salon, but the design are really great. I hope to find real soon the little “plus” I trying to add.


31 May 2008
13:25

I’m in drawing mode

I’ve been drawing a lot since I got my new portable pc (it’s awesome!!!) and here’s 2 new drawings! Enjoy!

My friend Patricia I drew after we came back from a movieUs 3