(99 replies, posted in Programming)

Frank H wrote:

I've now started to test out Eclipse, it feels pretty solid and it does what I searched for, and as a bonus I can use Consolas in cleartype smile


Feels like it could be a keeper smile

(I just saw that Xumix mentions it on page 2 ... I wonder if I missed it or just didn't figure out how it worked when I first went through this thread?)

Aye, Eclipse is a very nice IDE, if an IDE is what you're looking for.  You can get a version that's designed especially for LAMP development:


(0 replies, posted in Feature requests)

Not so much a feature request as a suggestion smile

I was looking through the database structure of PunBB and noticed that IP addresses are stored in VARCHAR fields as strings.  It would be more efficient (disc-space size-wise) to store them as unsigned 32-bit integers in decimal format, which would use only 4 bytes, rather than 15.  This can be done quite easily with the following two functions:

function encode_ip($ip_string)
    $ip_hex = '';
    $octets = explode($ip_string, '.');
    foreach ($octets as $octet)
        $ip_hex .= dechex($octet);
    return hexdec($ip_hex);

function decode_ip($ip_int)
    $ip_hex = dechex($ip_int);
    $octets = array();
    for ($i = 0; $i < strlen($ip_hex); $i += 2)
        $octets[] = hexdec(substr($ip_hex, $i, 2));
    return implode('.', $octets);

Just thought this would be a neater and smaller way of recording IP addresses smile

Another thing; I noticed that the migration tool doesn't carry IP addresses over from phpBB to PunBB.  phpBB actually uses a similar system for storing IP addresses, only it stores them as hexadecimal strings (e.g. is stored as FFFFFFFF) in VARCHAR fields.  It would therefore be pretty easy to adapt the migrator to convert these IP addresses.

edit: Sorry, my bad... seems the migrator carries the post IP addresses over, and the registration IPs aren't recorded in phpBB hmm