Tech Thought

Tech tips, hints, and general musings. PHP, Perl, Mysql, Javascript, AJAX, JSON, Linux, Mac OSX

Entries for March, 2008

ModalBox: Modal Dialog Boxes Based on Prototype.js

If you’ve ever used the Sustainability Victoria calculator, Administered Joomla or poked someone on Facebook, then you might wonder how they create those nice modal dialog boxes that have replaced the ugly javascript confirm() in most modern web applications:

Well, thanks to prototype.js and ModalBox now you can. ModalBox is a javascript library that helps you [...]

Leave a Comment

How-To: Speed up page loading - compressed prototype.js

To help speed up the load time of your prototype.js and scriptaculous pages, you can now download fully compressed versions of all the required files from the ‘prototype-core’ group on google thanks to John David-Dalton (original post on Ajaxian):
http://groups.google.com/group/prototype-core
This reduces the size of prototype and scriptaculous to 64k total! Be sure to [...]

Leave a Comment

Javascript OO: Scope of ‘this’ variable when using prototype.js

If you write a fair bit of OO javascript and also utilise AJAX through one of the many frameworks (I personally use prototype.js most of the time) you may have come across the following issue:

var myobj = new Object();

myobj.Methods = {
result: 0,
callAjax: function() {
[...]

Comments (2)

How-To: Install a Scanner on Mac OSX with SANE

Recently we found that the drivers for our Scanner (Epson LP-A500) are either not supported on Leopard or don’t work. So we set about trying to work out how we could scan directly from our Mac (instead of running a windows server/VM to do the job).
The answer is SANE - Scanner Access Now Easy. [...]

Comments (2)

Upgrading PHP on Fedora Core 5 (or other distro)

Download the RPMs you require for your new PHP installation from the following URLs. If you have RPMs that aren’t listed, use the search function:

php-5.2.5

pcre-6.6
php-cli-5.2.5
php-common-5.2.5
php-pear-1.7.1
php-gd-5.2.5
php-pd-5.2.5
php-mysql-5.2.5
sqllite

Or if you are upgrading another distrobution, search for the equivalents here.
Check which PHP RPMs you currently have installed:
rpm -qa | grep phpphp-5.1.6-1.6
Output should be something like:
php-pear-1.4.9-1.2

php-pdo-5.1.6-1.6

php-gd-5.1.6-1.6

php-mysql-5.1.6-1.6
** Do The Following [...]

Comments (3)

What redhat/fedora distribution am I running?

To determine which version of Fedora or Redhat you are running, simply type:
cat /etc/redhat-release
This will then display something like:
Fedora Core release 5 (Bordeaux)

Leave a Comment

How-To: Remote Desktop Between Windows & Mac

Sometimes it’s really useful to be able to have direct access to a remote computer.  Particularly if you are helping someone who isn’t technical (and its a nightmare trying to help them over the phone).  However accessing a remote computer can be a fiddly exercise if you are trying to negotiate corporate or home [...]

Leave a Comment