Welcome to Webmasterpage.net!
by webmasterpage.net

IP addresses in the database store properly

Author: Roger In: PHP
2 comments

localhost I wanted to write about it long time already, how IP addresses properly stored in the database. Unfortunately, I have moved it again and again and then ultimately forgotten (that's what happens when one does not write down;)). Today, as luck would have it, I've found a blog entry on entwicklerblog.net of this issue actually already pretty well describes, so I've decided you imagine this entry, rather than being one to publish.

[MySQL] save IP addresses

Markus von entwicklerblog.net describes exactly why it makes more sense to address in INT format to store IP and not make the mistake many in the (15) field in the database VARCHAR to save it. To my shame I must confess that I've done it a long time.



Smarty Dwoo the alternative

Author: Roger In: PHP
4 Comments

logodwoo Although PHP template engine really did not need any more developers continue to put many more on template systems like Smarty . Smarty is probably the most well-known template engines for PHP,. Until about a year ago was still officially on the Smarty PHP project. This is now part of the past.

Smarty has many advantages, such as for example its own syntax, or the easy expandability through their own or already existing plugins. But Smarty has a big disadvantage, namely the speed. This is not least a result of the many contaminated sites in order to continue to be compatible with PHP 4. However, developers need only PHP 5 programming no longer compatible with PHP 4.

Remedy is Dwoo . Dwoo according to the manufacturer offers the same flexibility and expandability, such as Smarty, and is almost fully compatible with existing Smarty templates. The big advantage is that Dwoo written entirely in PHP5 and is therefore something Contemporary.

Although the page appears somewhat anachronistic Dwoo, the software offered no less valuable. I think is well worth a look.



Regular Expressions Online Testing

Author: Roger In: PHP
3 Comments
Reguläre-Ausdrücke online testen

Regular expressions online for free

Who has not, one looks and looks for the error but can not find him and the end of the song is that it is not the script to the audited entity behaves wrong but somewhere else. That happened to me before quite often in the use of regular expressions happened.

In the meantime, I have but remedy found. Before the regular expression productively began my scripts in, I test them thoroughly before using an online evaluator. evaluator This helps me quickly when I once had an error in the expression.

The side -regexp evaluator.de also offers even more. In addition to the evaluator, the site offers a tutorial with the one explanation for simply getting what expressions are regulars, how you build and what errors there are. Of course there are still a couple more themes to which I now at this point would like to comment further.



Write with PHP's own log files

Author: Roger In: PHP
Add a comment

codesnippet2 The absolute worst case scenario. A script does not behave as it should, however, is already effectively in use. Debugging can be "no longer a simple" echo.

Something like would happen, of course not, but it can always happen again if they show problems until after the development and beta testing, we have not considered before.

This function helps the error_log . With this feature you can, I think, good debugging and also identify problems better. The versatility of error_log can be for example a log file or write an email to the administrator send.



«Older Entries |