Posts filed under “Web Programming”
How to keep nbproject out of your subversion repository
Netbeans users, if your using netbeans with SVN, you may have had the problem that the nbproject directory tries to get included into your subversion repository. This is fine if you are the only developer, but it’s best to just keep that folder from getting included in your repository.
iprange Consolidation Tool Version 2.0
I’ve updated my iprange tool with some new features. Given a list of IP addresses, it reduces them to a set of CIDR ranges rather than just a single CIDR. How many CIDRs it creates is determined dynamically. You can also specify the threshold subnet bits. If for example, you specify 24, it will only consolidate networks [...]
The 256M VPS
There are a few cloud web hosting services offering 256Mb servers. But there is a lot of talk about whether 256Mb of memory is enough to run a web server. Well, of course, that entirely depends on what you are trying to do with it and how much traffic your website gets. However, if you prefer to have control over your server and only have a few small websites that don’t see much traffic, I believe that you can do fairly well with a 256Mb server.
A mysqli wrapper
There are plenty of packages out there that will hide the SQL, but I prefer to write it out. The mysqli interface allows for easy object oriented programming. However, it is missing a couple of things that could make accessing data a bit easier so I use a wrapper class. My class, the function naming, is loosely based off of Ultimate MySQL by Jeff Williams.
Most of the functions in my class take variable arguments and take advantage of the vsprintf function. A call might look like this:
Configure nginx for WordPress
Being relatively new to nginx, I went looking on the web for a good example of how to configure nginx for wordpress, unfortunately none of the ones I found actually even worked. So after playing around a bunch, I finally got it setup fairly well.
nginx (Engine X)
I’ve been using the web server software nginx instead of Apache for the past month and I must say I am quite impressed. It is much leaner and feels snappier. It provides all the features that are normally used without all the bloat that comes with Apache. I think the configuration files are a lot simpler too. Someone once said “Apache is like Microsoft Word, it has a million options, but you only need 6. nginx does 5 of these better and faster.”
Cloud Servers and Spam Blacklists
In the past couple of months I’ve discovered the joy of cloud computing using both of the big services Amazon EC2 and Rackspace Cloud. I’ve setup and configured several virtual servers to act as web servers on both services. So far I’m finding Rackspace cloud to be much more user friendly and easier to use. Amazon EC2 has a strange internal IP setup and they do not allow you to use a password for SSH, they use a key file instead, which makes some things I think more difficult than necessary.