Salagir's Blog

Bon le blog est devenu tout simple tout moche, mais j’ai passé 24h à le mettre à jour. Il a peu de visites. Son ancien design n’était pas foufou. On va en rester là, hein. C’est surtout du texte après tout.

Catégorie : English Posts

  • Time Functions: Displaying rounded and international

    Be careful, this is the translation of two French articles and it’s long. Today we will be writing time in a way that is comfortable for a human reader. Who want to read, « Only 0h 00mn 18s left » at the end of a count that began an hour ago? Before, strftime() was enough. Now, time…

  • Translation SQL table and translation system

    This is a short, non-interesting article about a translation system. Nothing new or original here. I put here because my next article will use it and it’ll be a very long one. I a few month, I’m gonna talk a lot about translation. I’ve made many things about it, especially for automatic translations. Here, it’s…

  • List all 404 errors from a Apache server

    This is not the only solution to know if your website got dead links. For example, Awstats will tell you them too, but only from on site at the time. Also, online dead link finders are you friends, like W3C Link Checker. My solution works directly on the server, and also find the errors that…

  • Url rewriting is your friend

    Url rewriting, is to have a link to a webpage that a human can read, and a search engine can interpret as keywords. Many blogs use this, they use the title of the post in the url. Example : Good: http://toto.com/articles/eat-creme-brulee.html Bad: http://toto.com/2007/article.php?id=684 You english reader may not care about this, but the main problem…

  • Delete backslashs : death to magic_quotes_gpc

    Even in PHP 5, this old security params is activated by default, and I hate it. It’s Magic Quote. When this flag is On, then vars in cookies, from a form or a url, are automatically « escaped ». It means that backslashes are added before some special characters. Primary: the simple quote. Example : my script…

  • The 1468456th PHP class that overloads mysql

    My first code is totally uninteresting for real developers, but I will use this class often in my next scripts, so you need to know a little about this class. Plus, it’s certainly a rip-off of PHP 5 mysql class, but well, I still use 4. It still can do a few good things. Good…

  • English version

    English blog, opened ! And it’s post number 42, which is cool. My blog needed an english version, because I put my scripts here, and it would be too sad if only french people used them. I won’t translate my others posts thought, for the most part because I’m lazy. Anticipate about one post every…