Computer Programming

Yes, a bit specific, but I need to store some links!

Creating a Firewall Log Analysis Tool for a SonicWall DSL Router, Part 2

In the last entry, log lines were being "compressed" by placing them into a database table. There were a few bugs in that code that have been fixed, and features added to the new script, below, that save us from losing some log data. Explanation after the code:

Creating a Firewall Log Analysis Tool for a SonicWall DSL Router, Part 1

Network traffic was growing, and it was getting hard to really "see" what was sucking up the capacity. It could be spam, or YouTube, viruses, hack attempts, or anything.

PHP list and array....

One day, I wish I can write this in PHP

while( $filename = $files->next() )
   [ $a, $b, $c, $d ] = getimageinfo($filename);
   $sizes[] = [ $filename, $a, $b ];

Dusting Off Coroutines

Coroutines are back! They never really left, but, it looks like different languages are adding native support for coroutines.

Comments about PHP's New Lambda and Closure Features

I've been reading up on it, and, not being up-to-date on PHP development news, didn't know about the discussion about the design on PHP's new lambda and closure features in 5.3.

HTML: ID naming convention

if you have an ajaxy library that can edit divs in-place:

<div id="story.1234">
    <div id="story.1234:title">the title</div>
<div id="story.1235">

Javascript Functions and Closures for Private Properties

A JavaScript Module Pattern is a fantastic example of how to use closures.

Javascript Closures has more detailed information.

Douglas Crockford brought the style over to JS, and his site has a lot of important articles about Javascript hacking (as a functional language).

HTML CSS 3-column Layout with Content Above the Navigation

I was toying with some SEO ideas, and wanted a CSS-based layout that puts the content at the top.

An Argument Against the Traditional Iterator

Attached are two scripts that contain code for two styles of iterator. One is the traditional Iterator, and the other is what I'll call an IterObj.

Simple Templating Language in PHP

A few years back, there was a trend in the PHP community to make alternative templating languages that ran inside PHP.

MS Access: Address Cleanup Macros

Here are some Excel macros that help to clean up data. Once cleaned, it's easier to remove duplicates. (I used these to de-dupe a list exported from Outlook.)

HTML Forms and $_POST, a Simple Templating Script

This page will describe the difference between GET and POST, and the typical uses for each.

HTML Forms and $_GET[]

As clever as it is to alter the URL to pass values to your script, the normal way to pass values is through a web form.

Here's some HTML that will display a form with two fields.

Arrays, Passing Values, the $_GET[] Variable

In the previous chapter, we explored evaluation, evaluation order, variables, numbers and strings.

In this chapter, we explore how to send input to our short programs.

Syndicate content