Monthly Archive for February, 2008Page 2 of 6

Slightly More Expensive Labour

Sure, ASDA’s £3 jeans are cheap, but unfortunately there badly fitted. Well, what do you expect? However, whilst in Southampton yesterday, somebody showed me Primark. Cheap clothing with ok / good looking pattens. There jeans, £4 a pair, fit me perfectly.

This BBC report from 2006 about cheaply, mass-produced clothes from Bangladesh. Although cheap clothes are being produced in sweatshops as shown, since 2006 Primark has been putting work into their workers conditions.

I also found a t-shirt which features technical terms from a bygone age. Such as Magnetic Tape and PDP-11. Woo, Unix in fashion form. That plus jeans for only £7, bargain! I think I’ll head back there soon.

Stick To The Quo

I’ve discovered a new love. The music of Status Quo. Their like a poor British mans version of Guns N Roses, except with catchier songs. Think of your dad doing karioke on a drunk Xmas afternoon, except their good. Take a look…

PHP: Block IP From Site

This code checks to see the users IP. If the IP is then the site stops loading and displays an error message. Usefull if theres something you don’t want accessed somewhere, such as your blog at work.


$getip = $_SERVER['REMOTE_ADDR'];

if ($getip == “127.0.0.1″) {
echo “Sorry, no browsing from localhost!”;
exit();
};
};

But, if lets say you want to bypass this code. Simply add $_GET to it, such as below.


$getip = $_SERVER['REMOTE_ADDR'];

if ($_GET['pass'] != “true”) {

if ($getip == “127.0.0.1″) {
echo “Sorry, no browsing from localhost!”;
exit();
};
};
};

So you would goto www.site.com/index.php?pass=true

Quick Front Redesign

Apart from the new blog name and subtitle, I’ve spent today redoing the main page of dun4d.com.

I’ve given it a quick CSS makeover, and I’m pretty happy about it. Also added some PHP code to it which I will publish at a later date.

  • Checks to see if the user is accessing the site via my colleges connection, if so cancels their request.
  • Randomly generated tag-lines.
  • Displays a message if the users on a Linux system.
  • The CSS changes depending if its night or day (GMT Time).
  • Well, I’m pretty chuffed with it…

    [Update] Added the Block IP PHP code to Saucy.

    We are Soooo Anti-Hax0r

    You know that contract-like document you may have to sign before using a college / universitys computer network? I’ve just fully read mine.

    The College reserves the right to monitor any
    data stored on its equipment or transmitted to
    or from its site. Users should not attempt to
    password-protect or encrypt any data as it will
    be assumed to be suspect.

    Hang on, theres plenty of usage for that sort of thing. Company documents, surprise parties, “personal” photos. If its encrypted, then there is no reason you should be reading it. You don’t let use have full access to your documents so why should we let you into ours?

    Send or receive encrypted messages
    (except for secure transactions) without
    written permission from the Director
    of IT.

    Like above, its so the “Director” can have a perverse sense of control.

    Students must not download programs without
    explicit staff permission.

    Yet we have full access to a copy of Microsoft C++ Studio, it says nothing about the source code. So you can’t download programs but you can access the source code to programs and compile them on the system.

    Streaming of video or audio material that is not
    curriculum-related is prohibited as it may slow
    down Internet access for all other users of the
    system.

    Except the media server, and the college radio station, and iPlayer and blah blah blah.

    Although these restrictions are done for “our own good”, the network is full of holes easily accessable to anyone who knows basic command line options or the Search tool. Don’t worry kids, your admins here to protect you!


    Trust your sysad kids!