Submitted by Massimiliano on 02/04/2013
In this post, for large projects I am referring to those projects that have grown over time adding features that did not exist in the first release of project, with a structure for a little application, and of course: a complete refactoring of the application is not possible.
Submitted by Massimiliano on 16/02/2013
Submitted by Massimiliano on 23/09/2012
This is a CodeIgniter Helper that I use in my web application to highlight the active link, like a link in a menu bar or everywhere a link must be active.
How it works
The active_link() function simply accept the name of a controller as parameter and then check if is equal to the controller we are really in, taking it from $CI->router->fetch_class();.
Submitted by Massimiliano on 22/08/2012
In this tutorial I will show you how to download a file whose content is the result of a database query, thanks to jQuery without reload the page.
The final result is very simple: we have a page with a button, we click on button and we are prompted to download a file, remember we are not reloading page, awesome.
In my example we are downloading a CSV file with a list of users.
Submitted by Massimiliano on 12/04/2012
ntpdate is a client that allows you to keep both system date and time synchronized, by connecting to an NTP server.
The use of ntpdate is very useful in server systems, so you have always date and time in your time zone.
To select the NTP server in your time zone check out this site http://www.pool.ntp.org
Install ntpdate
on shell, as root user, type apt-get install ntpdate
Submitted by Massimiliano on 04/02/2012
My need was to share a directory with a chrooted user, and with Pure-FTPd doing it is very easy.
The FAQ is very exhaustive, I recommend you read it, here in my case I go directly to the point.
From the official FAQ http://download.pureftpd.org/pub/pure-ftpd/doc/FAQ
Making a symbolic link won't work, because when you are chrooted, it means that everything outside a base directory (your user's home directory) won't be reachable, even though a symbolic link.
Submitted by Massimiliano on 10/09/2011
In this article, I will show you how to transfer files to a remote server, using the ftp command - line - directly from the Windows Command Prompt.
Prerequisites are: remote server must have FTP Server up and running and accept FTP connection.
Let's create the file scripts.txt, fill it with the necessary instructions to login, transfer mode, destination, files list, end connection.
file: script.txt
Submitted by Massimiliano on 16/08/2011
By default Drupal 7 does not enable the email field and homepage field in comment form for anonymous posts: so, enable them is very simple.
In your admin area, go to:
Structure -> Content types -> Article ( choose the content type you want, in my case Article and click on edit ) -> Comment settings -> Anonymous commenting (choose one of: Anonymous posters may/must leave their contact information) -> Save content type
Submitted by Massimiliano on 04/07/2011

For those working with NetBeans on a Windows ( for sure XP and Vista ) machine this error is well known.
Do not worry, fix is very simple, just add an extra option in the configuration file.
You can find netbeans.conf under
C:\Program Files\NetBeans\etc
This is the original conf row
Submitted by Massimiliano on 28/06/2011
In this article I will show you how to create an array of months, where the first element is the current month, and the other elements are the following months.
This code is very useful when you need to handle events that have an expiration date.
Pages