Featured Post

First iPhone “Virus”

Interesting. Only affects jailbroken iPhones. I’m curious to see *how* it does this, but I’m taking an educated guess that the virus scans for iPhone’s with SSHD running, and then attempts to logon with the default username / password (which is root/alpine by the way), and then has...

Read More

Web Design Busy-ness

Posted by Ashley Knowles | Posted in Systems Administration | Posted on 05-02-2010

Tags:

0

After a LONG time of dissatisfaction with the design of Cruising Brisbane, I finally sat down and went, stuff this, I’m fixing it. Over the last weekend I planned out a new front page layout, and began putting the forum skin together.

I must say, I’m very happy with where it’s at. It’s no masterpiece, and it might break every rule in the web design handbook, but it looks the goods, and will do exactly what I want it to – attract more visitors, and KEEP them.

Check it out here – http://www.cruisingbrisbane.com

Watch this space.

PHP Templating

Posted by Ashley Knowles | Posted in Systems Administration | Posted on 11-12-2009

0

I’ve always wanted to create a CMS system using PHP. I currently have an opportunity through my work to develop a custom form webapp for one of our clients, which I’ve been working on non-stop for the past day or so.

I’ve got no idea how anyone else does templating, but I’ve devised my own little method to replace BBCode style tags embedded within HTML with little bits of code here and there. It really is nasty, but it does the job. At the moment, all it’s being used for is to create a form, which is dynamically updatable by our client so they can add new fields and new forms as required.

<?php
require_once('dbconnect.php');
 
if(isset($_POST['submit'])) {
 
	if (isset($_GET['formid'])) {
		$frmQry = mysql_query("SELECT * FROM dc_form WHERE id=".$_GET['formid']) or die(mysql_error());
		$frmData = mysql_fetch_assoc($frmQry);
		header("Location: index.php");
		echo "ok!";
		$body = print_r($_POST,true);
		mail($frmData['frmRecipient'],'customer Form Submittal',$body) or die ("Could not submit form!");
 
	} else {
 
		echo "Form ID not specified!!!";	
 
	}
 
} elseif(isset($_GET['formid'])) {	
 
	$frmQry = mysql_query("SELECT * FROM dc_form WHERE id=".$_GET['formid']) or die(mysql_error());
	$frmData = mysql_fetch_assoc($frmQry);
 
?>
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>company :: <? echo $frmData['frmName']; ?></title>
<link href="DC_CSS.css" rel="stylesheet" type="text/css" />
</head>
 
<body>
    <h1><? echo $frmData['frmName']; ?> </h1>
	<form action="formLoad.php?formid=<? echo $_GET['formid']; ?>" method="post">
<?
	$templateQry = mysql_query("SELECT * FROM dc_formTemplates WHERE frmid=".$_GET['formid']) or die(mysql_error());
	$templateData = mysql_fetch_assoc($templateQry);
 
	$templateHTML = $templateData['templateHTML'];
 
	$fieldQry = mysql_query("SELECT * FROM dc_formFields") or die(mysql_error());
	while ($fieldData = mysql_fetch_assoc($fieldQry)) {
		$fields[$fieldData['fieldName']]['label'] = $fieldData['fieldLabel'];
		$fields[$fieldData['fieldName']]['type'] = $fieldData['fieldType'];
	}
 
	preg_match_all("/\[([:\w]+)\]/",$templateHTML,$replace);
 
	foreach ($replace[0] as $value) {
		preg_match("/\[([:\w]+)\]/",$value,$fieldName);
		$replaceThis = $value;
		$fieldName = $fieldName[1];
		if ($fieldName == 'submit') {
			$replacement = "<input type='submit' name='submit' value='Submit'>";
		} elseif (preg_match("/\[label:(\w+)\]/",$replaceThis,$labelField)) {		
			$labelField = $labelField[1];
			$replacement = "<label for='{$labelField}'>{$fields[$labelField]['label']}</label>";
		} else {	
			switch($fields[$fieldName]['type']):
				case 'text':
					$replacement = "<input type='text' name='{$fieldName}'>";
					break;
				case 'textarea':
					$replacement = "<textarea name='{$fieldName}'></textarea>";
					break;
				default:
					$replacement = "<input name='{$fieldName}' type='text'>";
			endswitch;
		}
		$templateHTML = preg_replace('/\['.$fieldName.'\]/',$replacement,$templateHTML);
	}
 
	echo $templateHTML;	
 
} else { ?>
No form selected!
<? } ?>

The template data is actually stored in the database as follows:

<table>
<tr><td>[label:clientName][clientName]</td></tr>
<tr><td>[label:zone][zone]</td></tr>
<tr><td>[label:cssc][cssc]</td></tr>
<tr><td>[label:cso][cso]</td></tr>
<tr><td>[label:date][date]</td></tr>
<tr><td>[label:behaviours][behaviours]</td></tr>
<tr><td>[label:stability][stability]</td></tr>
<tr><td>[label:selfcareskills][selfcareskills]</td></tr>
<tr><td>[label:academics][academics]</td></tr>
<tr><td>[label:intellect][intellect]</td></tr>
<tr><td>[label:familycontact][familycontact]</td></tr>
<tr><td>[label:substances][substances]</td></tr>
<tr><td>[label:health][health]</td></tr>
<tr><td>[submit]</td></tr>
</table>

SR20DET Machining Videos

Posted by Ashley Knowles | Posted in Systems Administration | Posted on 11-12-2009

0

This pretty much serves no purpose but to entertain me and anyone else interested in the SR20DET engine.

Outlook 2010 + Social Networks

Posted by Ashley Knowles | Posted in Systems Administration | Posted on 11-12-2009

0

I thought this was super massive awesome cool plus plus!!!!!1111oneoneone

I just installed the Office 2010 beta, and jumped in to my email quickly to grab a call. When I went to reply to an email, I noticed a little bar, similar to the “security” bar you get at the top of Internet Explorer, at the bottom of the email I was drafting, prompting me to install Windows Desktop Search. I clicked on that, and noticed another notification sitting there prompting me to add a social network for the contact who had sent me the email!

This looks pretty cool I must say. It looks like Outlook will have the functionality to look up your contacts Facebook status updates and what not when you receive an email from them. For home / personal use, this could be really cool. Don’t know how suitable it would be for corporate use however – I mean, who wants their boss seeing all their Facebook updates when they send an email?

http://officebeta.microsoft.com/en-us/outlook/connect-to-your-favorite-social-network-using-microsoft-outlook-HA101789909.aspx

First iPhone “Virus”

Posted by Ashley Knowles | Posted in Systems Administration | Posted on 10-11-2009

Tags: , , , , , , ,

0

Interesting. Only affects jailbroken iPhones. I’m curious to see *how* it does this, but I’m taking an educated guess that the virus scans for iPhone’s with SSHD running, and then attempts to logon with the default username / password (which is root/alpine by the way), and then has it’s way with the victim’s iPhone. Clever, yet so simple…

Suffice to say, my root password on my iPhone is now changed!

Oh and I love the Rick Roll effect. Personally, I would have set the ring tone to Rick Astley as well :P

Read more here: http://www.dailytelegraph.com.au/news/the-worm-turns-on-the-iphone-as-virus-hits/story-e6freuy9-1225795892928

INB352 Network Planning links

Posted by Ashley Knowles | Posted in Systems Administration | Posted on 10-11-2009

0

These are just for my study reference for a network design / planning subject I’m doing at Uni.

Routing Protocol Selection

Testking CCSP 642-515 Exam Questions

Network Planning and Design Guide

Introduction to WAN Architectures – very handy reference…

Mac Keyboard Shortcuts

Posted by Ashley Knowles | Posted in Systems Administration | Posted on 10-11-2009

Tags: , ,

0

I like to think I’m pretty good with the MacOS now, but let’s face it, there’s still a whole bunch of little things I’m still learning…

Take for example, how to boot up a CDROM or USB drive…

Turns out, a guy named Dan Rodney has compiled a list of frequently used keyboard shortcuts for the Mac, alot of which I seemed to figure out on my own, and then the rest..

Anyways, linky-dinkĀ  here – http://www.danrodney.com/mac/index.html

Still trying to find a way to send Page Up / Page Down / Home / End using VIM over SSH in Terminal… Instead, fn+Up Arrow (aka page up) scrolls the terminal window, and fn+Left Arrow (or maybe it’s right) mangles stuff up, instead of shooting to Home / End. Maybe Putty or something similar is the answer to this…

Remote KVM Cards & Modular Servers

Posted by Ashley Knowles | Posted in Systems Administration | Posted on 07-11-2009

Tags: , , ,

0

I had to install a PCI remote KVM card into a client’s server this afternoon. Oh how difficult that was!!!

So, servers these days, are 99% of the time modular in every single way… The problem I’m getting to here, is that, you no longer have separate cables for your power, reset, HDD, etc etc on the motherboard… Hey, that’s great 99% of the time, right?

Yeah… But what about that other 1%?

So I installed said KVM card, into a PCI slot, hurrah, no issues. KVM card in question has a pin header which you plug your old power switch and reset button onto, and then use the supplied “feature cable” to connect the KVM card to your motherboard’s pin header. In theory, that’s all just supposed to go like peaches and cream.

Here’s your 1%! The ribbon cable for the front panel’s pin header connection, firstly, was not long enough… But secondly, and more annoyingly, ALL of the pins are joined together in one “mega connector” encompassing all 16 odd pins in one connector to connect to the pins on the motherboard. UGH!

So we did a bit of a dodgey. The server in question now has no power button or reset switch, bar using the remote KVM software of course… In it’s replacement, we implemented the following:

  1. Power state when mains power restored was set to ON. Essentially, your new power switch is the mains power switch. The server, provided it doesn’t lose its BIOS settings, will turn on automatically when you turn the mains power on…
  2. We toyed with the idea of using the chassis intrusion switch as the new power switch, this failed, obviously, when you close the chassis, the switch is triggered, and 4 seconds later, it turns off. So chassis intrusion, I guess, could have just been reconnected as normal. No, we dodgied this up too. An old school (aka pre-SATA) IDE hard drive jumper was used to permanently short the chassis intrusion pins. Dodgy, yes, but the BIOS didn’t have any other option to turn it off… You do what ya gotta do, right?

Of note here, is the fact that ASUS servers, and chassis intrusion, REALLY SUCKS. We spent a good chunk of our time trying to actually get into a BIOS screen, but instead were told that the chassis had been intruded. It took multiple power draining exercises, battery removals, and generally changing everything back to how we had it to get anything to work. Suffice to say, if I never have to touch an ASUS server with chassis intrusion again, I would be the luckiest man in the world…

Unfortunately, that’s not going to happen, considering their higher spec servers are just awesome value…

Back to my rant…

If you end up having this same problem, I suggest this… Buy a DELL/IBM/HP server with remote management capability. I liked the features of this little card we used, but the stuff around has totally put me off it, especially for whitebox servers. In future, spend the money and do it properly…

TeamViewer $$^$&$##$!!!!

Posted by Ashley Knowles | Posted in Systems Administration | Posted on 07-11-2009

Tags: , , , , ,

0

TeamViewer really doesn’t work too well if your connecting to a remote client and you need to test out their VPN connection…

Trust me…

As soon as that VPN connection is established, you lose your TeamViewer connection and have to wait for the client to re-establish it’s connection, before you can reconnect.

Heck, if you really want to get annoyed, reconnect, then disconnect the VPN connection…

Good luck, and happy frustrations!!!

p.s. you need to close TeamViewer completely and run it up again after disconnecting from a VPN, it doesn’t appear to recognise that the VPN has been disconnected, so doesn’t bother to try updating it’s session data with the TeamViewer servers…. BOOOOOOO.

p.p.s. I’m not 100% sure if this only occurs using PPTP style VPN connections, if I recall correctly, it also occurred with a Cisco VPN client IPSec connection…

Interesting uses of Google?

Posted by Ashley Knowles | Posted in Systems Administration | Posted on 06-11-2009

Tags: , , ,

0

I love AWStats. I literally look at the stats for this website, and my other’s, multiple times every day… Stat’s junkie much?

I’ve become quite analystic with my stats, noticing trends and changing my content to suit common searches, which I believe lead people to believe they are going to find what they are looking for. You could say I’m doing my bit to make my search results “useful” to web users…

But one particular search keyword caught my eye today…”-intitle” shows up in my search keywords… I went to my search phrases stats, and found this baby:

intitle resume for | intitle resume-of | intitle curriculum-vitae | intitle s-resume @ lawson or sharepoint or microsoft dynamics erp -intitle example -intitle examples -intitle samples -intitle sample -intitle submit -inurl edu -intitle templates -intitle -resume-parsing -inurl fake -postjobfree-com -resumebucket-com -dice-com -trovit-com

Interesting…

I’m curious if this is a new method taken by recruitment agencies and employers alike, to seek out new employees? Heck, I think it’s an ingenious idea, the amount of resumes posted on the web would outnumber Monster, Seek, and any all those other job related sites ten fold!

I hope whoever searched for this found what they were looking for, in this case, they found me, someone who has barely delved into the joys of SharePoint… I hope my resume reflected that :P Perhaps resumes need to be indexed better, by recognising the relevance of “little experience with SharePoint” or SharePoint falling under the heading “beginner”, or something along those lines. Something to think about, Google…

2 visitors online now
2 guests, 0 members
Max visitors today: 6 at 12:06 am GMT-10
This month: 8 at 02-05-2010 09:30 am GMT-10
This year: 21 at 01-24-2010 04:28 am GMT-10
All time: 21 at 01-24-2010 04:28 am GMT-10