0 comments - Saturday the 14th of January, 2012 at 7:22pm
* * * * * command to be executed
┬ ┬ ┬ ┬ ┬
│ │ │ │ │
│ │ │ │ │
│ │ │ │ └───── day of week (0 - 6) (Sunday=0 )
│ │ │ └────────── month (1 - 12)
│ │ └─────────────── day of month (1 - 31)
│ └──────────────────── hour (0 - 23)
└───────────────────────── min (0 - 59)
0 comments - Tuesday the 5th of July, 2011 at 9:57pm
Do you know how much memory those loops are using ?
Why is this page taking so long to load ?
Well with this simple PHP code you can daily benchmark different versions of your script to use the least possible amount of Memory.
< ?php echo "Memory Usage: ". (function_exists('memory_get_usage') ? round(memory_get_usage()/1024/1024, 2) : 'Unknown') .'MB'."\n"; ?>
An example of this can be seen by visiting the Precision Badges New Zealand site, and viewing the page source, right down the bottom.
0 comments - Tuesday the 26th of April, 2011 at 7:25am
Start of simple, start off clean.
I am going to assume a few things in these posts,
PHP 5.2 or above. ( 5.3 is better )
mySQL is our database of choice.
You understand the basics of setting up a virtual host/development area, and setting up your database.
Setting up your index file.
The 'index.php' is going to handle all requests. We will define the necessary contacts and then call out bootstrap file which starts and loads all of our needed classes.
from there, we load our bootstrap file that loads all needed classes.
The Core::Router() function does the routing.…
0 comments - Sunday the 24th of April, 2011 at 10:15am
Lately I have been seeing some nastiness being taught to a group of Junior web developers.
It comprises of maxing all sorts of nasty combinations of mixing your PHP, HTML, classes, queries and stand alone functions into an unorganised pile of mess.
Developing any project, simple of complex in this manor will very quickly become a nightmare, to me, and more so to those student developers.
I am going to put together a series of quick and simple posts to make a clean, simple and effective PHP based framework to act as a learning step for these students.
1 comments - Thursday the 3rd of February, 2011 at 8:08pm
Ever use PHP's var_dump() or print_r() to debug what is going wrong with that $data you have ?
Well, this simple script acts as the above functions, yours first parameter is your data, and the second optional parameter is stoping the script or continuing on.
The 'debug_backtrace()' function will return which file call's the dump function so you can easily track where your errors are coming from.
function dump($data = array(), $finish = TRUE) {
list($referrer) = debug_backtrace();
$total = count($data);
echo '';
echo ''.$referrer['file'].' @ line: '.$referrer['line'].'';
echo '';
$l = 0;
if($data) {
foreach($data as $line => $value)…
0 comments - Thursday the 3rd of February, 2011 at 7:54pm
Webkit browsers such as Safari and Chrome support some superb CSS3 styling.
They are ( even thought I use firefox as my primary browser ) the most advanced browsers.
For a while now I have created custom scroll bars using a Javascript library called Mootools, other libraries such as jQuery and Prototype can do this too, but here is one easy way to do it with CSS alone;
here is the simple code, if you know CSS it will be self explanatory, else I have added some commenting
/* were a webkit browser, lets style our scroll bar */
@media…
0 comments - Monday the 29th of November, 2010 at 10:42am
I needed a simple lightweight Mootools Gallery Lightbox, and after a few googles, I found nothing that suited my needs with out all the extra 'captions' and grouping and bloat.
This is a simple zoom from start position type lightbox that uses only the Mootools Core version 1.2.4 at this time but should work with 1.3.x
I have used it on the Glass Effects web page which you can view for a demo.
You will notice on my class, I am adding a CSS class 'shadow' to the large image, this is used for basic styling and you can do…
2 comments - Tuesday the 26th of October, 2010 at 7:07pm
After around 19 months of inactive development I have updated my Mootools BounceBox class to support The current selector method and fix an Event issue in some browsers when opening the Box.
Try out the demo at http://bouncebox.lendrum.co.nz and download it on the original BounceBox post.
[caption id="attachment_383" align="aligncenter" width="300" caption="BouceBox Preview"][/caption]
0 comments - Monday the 11th of January, 2010 at 5:43pm
I have made an update to my search rank checker for http://sheldon.lendrum.co.nz to paginate the results. With over 4500 records, the list was getting a bit long.
I have paginated it by rank's rather than equal pages.
Check it out - http://sheldon.lendrum.co.nz/search-rank-for-sheldonlendrumconz/,
3 comments - Monday the 11th of January, 2010 at 3:56pm
I needed a quick way to include different files based on the if the visitor to a site is on a mobile device or a regular browser/computer.
Every browser has a user agent depending on the operating system, browser and system.
below are some common use agents, they can be found by echoing the server variable HTTP_USER_AGENT
< ?php echo $_SERVER['HTTP_USER_AGENT']; ?>
FireFox
Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.1.7) Gecko/20091221 Firefox/3.5.7
Safari Mac
Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-en) AppleWebKit/523.10.3 (KHTML, like Gecko) Version/3.0.4 Safari/523.10
Safari Windows
Mozilla/5.0 (Windows; U; Windows NT 6.0; en)…
0 comments - Sunday the 10th of January, 2010 at 5:48am
First rotisserie on the BBQ
http://yfrog.com/4iltwvj http://yfrog.com/4ikn7j #
RT @SheldonNesdale: Can you help me give my free ebook away? "How to Optimise Your NZ Website For Search Engines": http://bit.ly/84fQAh #
RT @textmator: Amy Editor http://www.amyeditor.com/ #
RT @keesfransen: RT @TylorSkory: Go to http://google.com and click "I'm Feeling Lucky" without typing anything to see a surprise. #
Just created some lighting lines for fun http://yfrog.com/3nasiuj
from http://bit.ly/3m4cM0 #
The DL link is broken :(
RT @smashingmag: Jellyfish-CSS 1.2: a free powerful CSS editor for Mac - http://bit.ly/70qlIK #
hey @telecomnz, I'm not happy with my BB speeds of late ! Whats…
0 comments - Sunday the 3rd of January, 2010 at 5:48am
I just learned that the 1st known recording of Led Zeppelin happened @ Gonzaga University in Spokane on 12/30/1968. (@biggreenape @Klymacks) #
Some one didn't make it to midnight http://yfrog.com/4fxjjpj #
Hey @TelecomNZ my interwebs are SLOW today !
:(
http://www.speedtest.net/result/668331951.png in reply to TelecomNZ #
Just got back from spotty fishing, got a good couple bits of cat food down that the Tauranga jetty's. #
@SheldonNesdale Thanks, will check it out tomorrow. That site really needs a lot of work, mostly it is there for the customer account area. in reply to SheldonNesdale #
@telecomnz WTF is wrong with…
0 comments - Sunday the 27th of December, 2009 at 5:48am
Help Please, #CodeIgniter and #fpdf pdf generation http://codeigniter.com/forums/viewthread/45365/P15/#685785 #
RT @mike9r: HP is going to learn how social media can kill you: their webcams are racist http://idek.net/p0i (via @iA) #
I just successfully restored a files from 2 weeks ago #thanks #apple #timemachine ! #
RESOLVED: RT: @sheldonlendrum: Help Please, #CodeIgniter and #fpdf pdf generation http://codeigniter.com/forums/viewthread/139181/ #
pretty - firefox 4 windows screenshots
http://blog.stephenhorlander.com/2009/12/21/windows-themeui-update/ #
RT @vodafoneNZ: RT @SitaMitaBita and others: RT @flyairnz: from our friends @grabaseat wildlife - The Cougar - http://bit.ly/6bqBFQ #
Sweet mac Growl theme #mono http://fixedgear.ca/ #
I just saw the #trademe guy in http://www.trademe.co.nz/Community/OfficeCam.aspx picking…
0 comments - Sunday the 20th of December, 2009 at 5:48am
I took it and so should you—The Survey For People Who Make Websites, 2009: http://aneventapart.com/survey2009 #
Sequel Pro, can you import a 120mg mySQL database ? #
Yes, yes you can ! I remember when you would crash with a 2mg import :) Happy times ! #
RT @iPhonewzealand: For those of you with a US iTunes account, check out the free 20-track iTunes Holiday Sampler . http://bit.ly/5ZC9Uo #
@rowanbeentje Thanks, yeah, worked well, Great App BTW ! in reply to rowanbeentje #
@rowanbeentje I have SP 0.9.6, checked for updates, there is no 0.9.7 ? in reply to rowanbeentje…
0 comments - Tuesday the 15th of December, 2009 at 6:47pm
How do I rank number 1 for 'torrent.com' ?
I found this out on here!! http://sheldon.lendrum.co.nz/search-rank-for-sheldonlendrumconz/ - God I have to post more !
0 comments - Tuesday the 15th of December, 2009 at 6:39pm
I use the great CodeIgniter, PHP Framework a lot, Most site's now days I create use it. One of the many good things is that way it handles pages request's and PHP $_SERVER['REQUEST_URI'] to find which page we are on.
Here is how it works;
http://www.sheldon.lendrum.co.nz/posts/my-segment/my-page/15/2009/12
Now the way we do things, is break the site up, based on the 'segments or the URI.
EG:
I am in the 'posts ( segment 1 )' part of the site. from ther directs to to the particular post I am on.
Here is some VERY simple javascript to find out any segment…
0 comments - Monday the 9th of November, 2009 at 6:50am
In preparation to a major overhaul of this site, I have moved my RSS feeds to Google's FeedBurner.
Please alter your RSS subscription links to ;
http://feeds.feedburner.com/sheldonlendrum
0 comments - Thursday the 8th of October, 2009 at 12:05pm
I came across some neat free Icons a couple of day's ago. I found 178 free icons by WooThemes.
They suited my needs for some navigation icons I was after, so after a quick download, I have them all. Great.
Now, when I code, I'm all about speed of page loads with our reducing quality of course. So more and more and with that I have been using CSS sprites for images, the Less requests, the faster a page loads. there are hundreds of articles explaining this sort of thing, like only use 1 CSS file, putting your Javascript at…
0 comments - Thursday the 8th of October, 2009 at 10:08am
Over the last year or so, I have used a PHP Framework Code Igniter, Amongst many of its good features is its built in Form Validation Library.
Every now and then I either write a a small site out of Code Ignite, or help others to write or develop sections of their site, I constantly get MSN/IM messages asking for help which I am happy to help.
More recently I have started compiling a list of the little help functions I have written to generate my own 'Form Validation' Class, I hope to post it here soon.
Today though I…
0 comments - Wednesday the 7th of October, 2009 at 11:01am
Javascript frameworks are great, no matter which one you use their all built to do more, quickly.
I use Mootools for most of my JS needs, and something is I often use is the AJAX request functionality.
Today I needed to send not only HTML back, but Javascript.
Here are the steps I needed to follow to not only return my Javascript, but to attach it to my response with the Mootools function '$exec'
My HTML
Update
My Mootoold Javascript
Our Request Handler PHP script
< ?php
/* QUERY OUR RECORDS FROM OUR GET DATA */
$response = mysql_get_data_function($_GET);
echo($response);…
0 comments - Tuesday the 22nd of September, 2009 at 10:17am
Recently the firm I work for got a job to rewrite the Online Quotation calculator for a local tauranga Painted Glass company called GlassArt.
We took the existing design and completely recoded the site, the original company had done such a job that it was easier to start over than try and use the mess that it was currently written in. We then started the Online Glass Splashback calculator which allows both registered wholesalers and retail customers to generate a quote for the various options that they can get a painted glass splashback for their kitchen or bathroom.
The system…
12 comments - Monday the 10th of August, 2009 at 12:05pm
A few months ago, I updated a great SPAW editor plug-in for CodeIgniter to use the most recent version of SPAW at the time, that included Safari Browser fixes and some CSS tweeks.
Well over the weekend I look at getting multiple tabs working.
It was pretty easy, with a couple of modifications to the SPAW wrapper class, I have create some sample usage, and examples for you to download.
I have made the CSS fixes from my previous post, and included some sample usage.
[caption id="attachment_412" align="aligncenter" width="300" caption="SPAW and CodeIgniter"][/caption]
I am only going to explain how to…
0 comments - Wednesday the 5th of August, 2009 at 12:49pm
In work, we often output a section of content and don't always either want the whole content, or want a quick summary;
Below is a quick piece of code that will create a quick clean summary of a full HTML page from our ( or any ) content Management System.
This doesnt actually use PHP's substr function, but has the same effect.
function summary($content, $length = 20, $finish = '…') {
// Clean and explode our content, Strip all HTML tags, and special charactors.
$words = explode(' ', strip_tags(preg_replace('/[^(\x20-\x7F)]*/','', $content)));
// Get a count of all words, and check we…
0 comments - Tuesday the 30th of June, 2009 at 10:47pm
spacious, modern, well known pirate bay, for sale, only 60 million SEK ! That's 7.8 million USD.
The Pirate Bay, one of the best torrent sites has been sold to the Swedish software company Global Gaming Factory X AB. I didn't even know it was for sale ?
1 comments - Thursday the 25th of June, 2009 at 8:51pm
I guess this is weeks old, but it shows how often I visit Facebook lately.
http://www.facebook.com/sheldonlendrum
0 comments - Wednesday the 3rd of June, 2009 at 9:29pm
So I am now a Comic Character, Shawn has made the team comic characters, There is Ryan, Deanna, Kate and Me - Sheldon
Check out Shawns Big Green Comic !
0 comments - Friday the 29th of May, 2009 at 8:47am
Today Ryan sent me this youtube video, It is a comical clip showing how some times Clients want work done above and beyond the spec, without expecting to pay extra for it.
Watch the clip and see if any of these ring a bell, I know I have heard this before..
0 comments - Thursday the 30th of April, 2009 at 8:26pm
I often want to know my IP address from when I am not, when I am not at Home/Work.
I know that there are Lots of sites out there that will sett it to you, but I wanted to set my own up.
http://ip.sheldon.lendrum.co.nz/
And Even!
http://ip.lendrum.co.nz/
0 comments - Wednesday the 29th of April, 2009 at 7:00am
I have a couple of Apple Mac's and with each of them, I have a Mighty Mouse.
I have one I carry with my with my Mac Book Pro, this is getting quite old now, It was the first release of the Wireless model, I pre-ordered it as soon as they were announced and have used it on almost a daily basis since.
I also have one on my iMac which gets a daily use also.
These mice are Great ! there are 5 buttons, the 5th is the 360 degree scroll ball. The wired model is very light and…
2 comments - Wednesday the 29th of April, 2009 at 6:08am
I use Apple's Mail App as my primary mail client on both my personal and work mac's, and for both machines I have various RSS Feeds subscribed.
I use apple mail as an RSS Client for a couple of reasons,
1) I just like how it works
2) its not just one more application I have to have open.
Recently though, I have found that none of the 30 or so feeds I am subscribed to were pulling any new posts.
I found this Odd, espically I know that multiple of them update daily. I did a bit of digging…
1 comments - Tuesday the 28th of April, 2009 at 11:07pm
With the Millions of users on Facebook, there is a need for lots of different langauges, but did you know that you can view your facebook in Pirate English! It will change the whole site in to Pirate English, even the notification emails you receive.
[caption id="attachment_396" align="aligncenter" width="300" caption="Facebook in Pirate English"][/caption]
It is Easy to turn on, and easy to turn off once the novelty has worn out.
Enable Pirate English on your Facebook Profile
Log in to your Facebook account, Click the Settings Link in the top Right, Click the Langauge tab, and from the drop down…
0 comments - Tuesday the 28th of April, 2009 at 9:40pm
A while ago, I co-wrote a large site with Ryan while I was working at Zipline Interactive, this site uses Mootools 0.98 as we found to be getting a lot of �������� all through the JAX requested response code.
For the life of US, we couldn't figure out why? it's not in the output if we called the data via a normal http request, so I looked for a fix.
Upgrade the Mootools to version 1.2.2
Add an enc type to the AJAX functions
new Request.HTML({
method: 'get',
url: '/examples/ajax.php',
data: { 'example': 'ajax-ascii' },
encoding: 'iso-8859-1',
onRequest: function() {…
6 comments - Wednesday the 22nd of April, 2009 at 9:38pm
On a project that I was recently working on, I had a series of text input boxes that I wanted to be numeric only fields. I have my PHP form validation to check that the data is numeric before entering any information in to the database, and I always use mysql_real_escape_string() on the data I am saving. But to save loat time and page refreshed, I decided to add some extra validation with the Mootools javascript library which I am using trough out the site already.
View Example
Update to Numbers Array
I have updated the Numbers array to include…
0 comments - Saturday the 21st of March, 2009 at 7:23pm
I was using an implementation of my BounceBox mootools javascript class on a site I am working on at the moment, and made a couple of additions to the Class that I hope other will enjoy.
The new version1.1 demo can be viewed at http://bouncebox.lendrum.co.nz/ and the change log with a new version 1.1 demo link at the bottom of that page to show full screen positioning that is now supported.
The Demo page has full links to download this free Mootools Javascript effects class.
0 comments - Wednesday the 11th of March, 2009 at 7:26am
Safari (by default) will open certain links (e.g. target=”_blank”) in a new browser window instead of a new tab even if you have your preferences set no too. Fortunately, there is a hidden preference you can set to force Safari to behave.
If you run this command in Terminal /Applications/Utilities/Terminal.app
defaults write com.apple.Safari TargetedClicksCreateTabs -bool true
to disable this afterwards, change the true on the end to false.
I have tested this on Safari Mac 2, 3 and 4 Beta.
6 comments - Monday the 9th of March, 2009 at 4:42pm
I am working on adding some features to the MiniShowCase Administration, like better user management, better image scaling options and better description management.
If anyone has any ideas or enhancement requests, please post a comment below, or to be notified via email when the next version is released, send me an email to: sheldon[at]lendrum.co.nz
0 comments - Thursday the 5th of March, 2009 at 12:59pm
I am writing a list that outputs a large amount of data in a vertical structure, with many rows the list gets hard to tell which entry is which.
Now, normally I would do this via PHP, something like
< ?php $messages = SQL('QUERY TO GET MY MESSAGES'); ?>
< ?php $style = "on"; ?>
< ?php if($messages): ?>
Messages
< ?php foreach($messages as $message): ?>
< ?=$message->firstname?> < ?=$message->lastname?>
< ?=$message->message?>
< ?=$message->status?>
< ?php if($style=='on') { $style = 'off' } else { $style = 'on'} ?>
< ?php endforeach; ?>
< ?php endif; ?>
But I decided today…
2 comments - Wednesday the 4th of March, 2009 at 12:48pm
I have been working a lot lately using SubVersion 's to maintain all the projects that I and some times others are all working on.
A firm that I contract to has recently set up a SVN Server on a dedicated machine with ActiveCollab and Versions to manage our projects. This means that we have versions and versions of manageable projects.
Today, I pulled down a part of a project to use inside another project, but the directories still contained the .svn data from the original project.
So here is a quick command to strip out all the .svn data…
2 comments - Wednesday the 18th of February, 2009 at 1:10pm
Today I had to help a friend force eject a stuck DVD in his iBook, there are a couple of methods we tried and I thought that hey may be helpful for others.
I would recommend trying to eject your stuck CD/DVD in this order;
1) Hold the 'Eject' Key for up to 30 seconds.
2) Stop the CD/DVD spinning
Stop the CD/DVD from spinning by gentle pushing in a thin piece of cardboard ( not to soft, nor hard ), thin packaging cardboard from like a battery or toy packet.
This will stop the CD as it is always…
2 comments - Tuesday the 17th of February, 2009 at 11:48am
I sat down to further my Javascript skills a couple of weeks ago and re-wrote a small peice of code that I used on DreamCatcher, A School Careers Application to create 'Slide Down' boxes for the Contact Form, Login Form and an Introduction Movie.
I rewrote it using less code and working out heights and sizes more dynamically, but yesterday I decided that I wanted to write a Mootools Javascript Class, something I have never attempted. So here is the first version 1.0. A simple Javascript class for Mootools 1.2+ to display a sliding box with a nice tranisiton and…
0 comments - Monday the 16th of February, 2009 at 8:54am
I was browsing just now and fond something pretty interesting, Safari supports multiple background image declarations for the same style tag.
.box {
background:
/* Upper-left */ url(./corners_01.png),
/* Upper-right */ url(./corners_02.png),
/* Lower-left */ url(./corners_03.png),
/* Lower-right */ url(./corners_04.png),
/* Icon */ url(./icon.png),
/* Gradient */ url(./gradient.png);
background-position:
/* Upper-left */ 0% 0%,
/* Upper-right */ 100% 0%,
/* Lower-left */ 0% 100%,
/* Lower-right */ 100% 100%,
/* Icon */ 0.6em 0.6em,
/* Gradient */ 0% 100%;
background-repeat:
/* Upper-left */ no-repeat,
/* Upper-right */ no-repeat,
/* Lower-left */ no-repeat,
/* Lower-right */ no-repeat,
/* Icon */ no-repeat,…
0 comments - Wednesday the 11th of February, 2009 at 9:00am
I use Adium for Chatting on my Mac. It is a great little App that allows you to connected with multiple Account types like MSN, Yahoo, Google Chat ( or gmail ), MySpace, Facebook and more... all in the one cool customisable messenger.
Today I looked at writing my own Message Theme as a quick learning exercise.
I have released the theme for free and you can download both Adium and any themes at Adium Extras.
[caption id="attachment_379" align="aligncenter" width="200" caption="Kermit the Frog Adium Theme"][/caption]
.
[caption id="attachment_380" align="aligncenter" width="300" caption="Kermit the Frog Theme Preview"][/caption]
2 comments - Monday the 9th of February, 2009 at 12:06pm
If you download anything via torrents, you should read this article. It is a pretty clear explanation of the upcoming Torrent Laws for ISP's and users here in New Zealand including the '3 Strike' policy.
http://torrentfreak.com/code-aims-to-quell-new-zealand-3-strikes-fears-090204/
The thing about torrents is that not every one uses them to download Copyright Application, music or movies.
I use Torrents and A Torrent Application called Vuze to download FREE content such as video tutorials, TV Adverts, HomeMade or Festival Movie Releases, Music Video Clips and all sorts of content that people have released openly.
I have even worked with a multiple office/location firm…
1 comments - Saturday the 7th of February, 2009 at 11:06am
Recently I brought a new iMac for my home development, music, movies, games and general play things. For work I develop Web Applications and with my ISP I have a static IP address, so I decided to set up a small testing webserver. Since Apple has built in PHP and Apache2, this was pretty much a couple simple steps.
I used my post about Installing PHP5 and mySQL on Mac OSX Leopard to recompile PHP and mySQL, then I started setting up my Virtual Hosts.
Heres what I did from a fresh Install of Leopard;
Step One: Enable Apache Web…
0 comments - Saturday the 7th of February, 2009 at 9:13am
As I was browsing the web today on a completly unrelated matter I can across Alex King's blog and a couple of interesting mySQL Queries that can show some useful stats on your blog.
The Article is http://alexking.org/blog/2007/01/01/sql-for-blog-stats.
Here is my Stats for 2008 and 2009 to date...
0 comments - Monday the 2nd of February, 2009 at 6:10pm
I noticed when installing the SPAW Editow recently that on the Design tab in SPAW, the HTML was showing as converted HTML Symbols like < and > rather than < and >.
After a bit of playing, i found this hidden piece of information on the SPAW FAQ's.
You should use getHtml() method instead of show(). It returns the code which you can store into variable and use whenever you need it.
[caption id="attachment_367" align="aligncenter" width="300" caption="SPAW getHTML() Rather than show()"][/caption]
0 comments - Sunday the 1st of February, 2009 at 7:31pm
When I looked at Ryan Stemkoski's technology blog about 11.26 javascript frameworks I though oh yeah, I have used a couple of those, and there was a couple there that I havn't.
But today I came across this site, Zazzle.com, this site uses some AMAZING javascript ideas, you can create your own mouse pad and when you hover over portfolio or gallery images, there is some great interactivity.
I think for fun I will be trying to reproduce some of these effects, it will be a fun task as I am not going to look at their source code, nor…
1 comments - Thursday the 29th of January, 2009 at 6:56am
This morning, much like every morning, I wake, prepare for the day, walk my partner to work, get home and read through my emails and RSS subscriptions before I start my working day.
This morning I came across a post from Ryan Stemkoski about How IE 6 is Dead and a comment from that post how Ryan gets 23% and Thomas J Brown gets ~2% of IE 6 visitors. I checked out my statistics and I get 37.7% of my visitors using IE 6.
[caption id="attachment_361" align="aligncenter" width="300" caption="Top 6 Browsers to visit my Blog."][/caption]
The top 6 browsers to…
1 comments - Thursday the 22nd of January, 2009 at 12:26pm
Over the last couple of years I have used the SPAW WYSIWYG Editor for my site management and clients sites CMS systems.
Ryan Stemkoski and I used it in our Zipline ZLCMS Package that is now in use in over 300 sites and have found it to be a great editor, and now I am using SPAW 2.0.8.1 for CodeIgniter in a CodeIngiter CMS Site.
How ever I have found that SPAW doesnt really fit in the Safari Frame, and all the toolbars span on one line causing usability and scrolling issue.
Today when implementing it for a MAC Safari…
17 comments - Thursday the 22nd of January, 2009 at 11:21am
I have released an updated version at http://sheldon.lendrum.co.nz/codeigniter-spaw-editor-tabs_411/10/. This new version allows CodeIgniter and SPAW TABS !
Recently I have been working on a large project for a National Sporting team, It has been a process and it is almost finished.
As part of this system, we have developed an extended custom content management system.
Finding a WYSIWYG Editor for these types of sites is a tricky thing. Your editor of choice needs to be complex enough to let the user Manage their site, but not too hard that they can't and don't manage it, yet not give them so…
0 comments - Sunday the 28th of December, 2008 at 6:43am
When printing in Leopard, the print queue application remains open after the print job is done. In Tiger and all previous versions of OS X, the application would quit automatically as soon as the print job was finished. I find it very irritating to have to go and quit the application after every print job.
To stop this, after a print job, or if/when you have a printer open in the dock, right click it in the dock and choose auto quit. I did this with one printer and it changed the settings on all of mine.
0 comments - Tuesday the 23rd of December, 2008 at 8:57am
Anytime you visit a website or do any other kind of DNS (Domain Name System) lookup, the IP address conveniently gets cached. Well today a Graphic Designer I was working with to finish up a site, just couldn't access the site to see that changes.
He could access every other domain on ether of our servers, just not our staging domain. I remote connected to his computer, and ping'd first our primary domain and got the expected IP in return, then I ping'd our staging domain and got '10.1.1.3' which was the machine I was using. I reset the DHCP,…
0 comments - Sunday the 23rd of November, 2008 at 8:53am
I recently found this great article about best coding practices for Speeding Up Your Web Site http://developer.yahoo.com/performance/rules.html
1 comments - Wednesday the 5th of November, 2008 at 1:56pm
I have been working on a template for an iPhone Library Application today, its pretty simple stuff, A search, Asynchonous paginated results with the full details on each result. It will be using FileMaker for its database, but currently I am searching a large PHP array for testing.
When displaying the full result, when your phone is help upright, the results look good, but when you roll the phone over, the display is crap so after a fair amount of googling and multiple sources linking to Apple, and a missing page http://developer.apple.com/samplecode/iPhoneOrientation/index.html I found this post @ DevPhone.com.
Its exactly…
0 comments - Wednesday the 5th of November, 2008 at 10:10am
While working on an online school application I came across the need to users to be able to change their passwords, I wrote a quick and dirty random pass script, then decided to see if I could figure out how hard it would be to test the strength of the entered password.
Ryan Stemkoski found Phiras's blog post about a jQuery strength tester. Which I used and modified to reduce all need for any external libraries. (jQuery or Mootools, etc...)
I have a Demo @ http://dev.lendrum.co.nz/passwords/
and you can download the code here.
[download#5]
1 comments - Sunday the 26th of October, 2008 at 10:07am
I came accross this sweet Wordpress Plugin called 'WPTouch today and have just installed it on this blog.
What it does, is create an iPhone friendly version of your blog. It has some sweet customisable features, like using Advanced jQuery Javascript Effects (ajax entries, ajax comments, smooth effects), Enable Gravatars in Comments.
When Advanced Javascript Is Disabled:
Your site loads faster on EDGE and 3G connections
Ajax & jQuery are not loaded & used for comments, entries, excerpts etc.
*Fixes javascript conflict issues where the WPtouch menu drop-down doesn't work
When Gravatars Are Disabled:
Gravatar.com images are not shown beside…
0 comments - Thursday the 23rd of October, 2008 at 8:57am
Inquisitor... it's like Spotlight for the web.
Start typing and websites pop up immediately, along with suggestions to refine your search.
It'll autocomplete your words and you can add more search engines with customized keyboard shortcuts.
Inquisitor is a Great Safari & now Firefox search add-on and it's free.
Inquisitor for Safari
Inquisitor for Firefox
0 comments - Wednesday the 22nd of October, 2008 at 7:45am
The other day i wrote about the great site Audiko in my post about iPhone ringtones, but today I read this article on
0 comments - Tuesday the 21st of October, 2008 at 8:45am
Ryan Stemkoski shares his thoughts, which I agree with on the Search Engine Optomisation validity and success based on 'Clean' URL's compared to query string based urls.
http://www.stemkoski.com/static-urls-or-dynamic-urls-vs-which-is-better/
0 comments - Monday the 20th of October, 2008 at 7:25am
So, Its the weekend, It has been a busy yet unproductive weekend, and thats just how I like it.
I started my weekend in style, I took Jen out for a nice Indian Curry for dinner ( Butter Chicken ). That was YUM. We went to a local bar for a drink afterwards called 'The Budda Lounge' here in Tauranga, which is actually where we go for Salsa on thursdays.
After Dinner we watched ''.
On saturday, after weeks of promising I cooked Jen breakfast in bed, well it turned out to be lunch, outside in the sun by the…
0 comments - Friday the 17th of October, 2008 at 1:15pm
While doing some iPhone web Dev research, I came across this IE 6 CSS PNG Fix.
I am yet to try it, but could be pretty helpful ! :)
/*Fix the PNG background image so that the contents can still be clicked*/
/* http://gist.github.com/9180 */
* html .png-fix-box {
background: none;
_azimuth: expression(this.bgd = this.bgd || 'bgd:'+this.insertAdjacentHTML('afterBegin',''),'inherit');
}
* html .png-fix-box .bg {
display:inline;
position: absolute;
top: 0px;
left: 0px;
height: 100%;
width: 100%;
filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='/media/images/global/discuss-box_top.png', sizingMethod='image');
}
0 comments - Friday the 17th of October, 2008 at 1:12pm
Friday,
Today, I am working in the office, Cleaning up a site I wrote yesterday, validating, design tweaks and that sort of stuff.
Also today I started really playing with an iPhone Web Framework WebApp.
I have a web app to build over the next month, and am really liking how easy, yet functional this frame work is.
basically its a structure, using basic ( pre written ) CSS classes and ID's for the formatting/functionality. XML, AJAX.
Heading out to dinner with Jen tonight, not sure where or what... Suggestions are welcome.
Lunch, Yes that is Marmite & Boiled egg…
0 comments - Friday the 17th of October, 2008 at 10:47am
SALSA, Last night was Salsa at the budda lounge. It was a good night, spent lots of money, but hey, thats what it is all about.
Only one pic, and not very good, this was early, but left around Midnight ish.
0 comments - Wednesday the 15th of October, 2008 at 8:13pm
I missed Yesterday, was both busy, and slack.
Today I started building out a got it probably 80% functional, which I am pretty happy about.
Yesterday I was working in the office, and all this week I have been trying to get my phone sorted out.
Over a week ago I moved my Telecom number to vodafone so I can use an iPhone.
After a mess around from Vodafone, I am now connected, same number, new service provider, and no text messages! Vodafone are having 'Issues' with ported numbers not being able to send text's, I can receive but it…
0 comments - Monday the 13th of October, 2008 at 12:37pm
Its Monday, Today I have to Ring Vodafone who are being useless about transfering my o27 telecom number to Vodafone.
I also have some general work, and to follow up with work from fri / sat / sun.
1 comments - Monday the 13th of October, 2008 at 11:57am
With the Apple iPhone, Apple have reduced the availability of the end user to easily add free custom ringtones. You have the standard tones, and the 30 second snippets from the Apple Store, but you have no control on where the snippets start and stop.
I started looking in to how I could generate my own ringtones and add them.
I first found and downloaded 'Audacity and started to hack in to a mp3 song from my iTunes library.
When looking around to find the best format to export the new ringtone snippet (which is '.m4r'), I came across 'Audiko'.…
3 comments - Monday the 13th of October, 2008 at 11:41am
I didnt get a chance to Post yesterday as I was out all day to watch Bathurst Car Racing.
It is a Holden vs Ford Race in Bathurst, Australia. Which is always a great day of V8 car racing, sun and beer drinking. I like Holden better, Ford won this year with Holden second, but at lease it was a Kiwi driver 1st & 2nd.
I got pretty sunburnt. :(
0 comments - Saturday the 11th of October, 2008 at 11:33am
Its Saturday, I got back from Auckland around 1 this morning.
Pretty Relaxing today, No work planned and am going to see Jen in a while and go out for dinner so that should be fun.
Bathurst tomorrow, Go Holden !
0 comments - Friday the 10th of October, 2008 at 9:09am
Its Friday, I am in Auckland, well Albany to be exact. I for some stupid reason, left my laptop power supply down at the mount, so have like 5 minutes of power left.
Agenda for today is work, lunch, work, catch back up with arron, catch up with my friend Dave at my old flat where he lives now and I used to like 5 years ago for a few beers, he is having a 'end of time'/'birthday' few drinks so that will be good to catch up. Then back to TGA and hopefully see Jen.
Thought of the day:…
0 comments - Thursday the 9th of October, 2008 at 9:05am
Lots to do today, Work on an Administration System, Format and Style another project that I am help with for The Busy Geek.
Plan a trip to Auckland, pack some clean clothes and head up later tonight and most importantly, Go out for lunch with Jen. mmmm Turkish !
0 comments - Thursday the 9th of October, 2008 at 9:01am
So for the Lack of posting lately, I am going to post a picture and a brief summary of my day online for 30 days. It may not be very interesting, nor attractive to see my mugshot each day but at will hopefully achieve two things;
1: Organise my day, If i summarise it first thing, I know what I am doing.
2: Share the light on a month of some one else's boring routines.
0 comments - Friday the 3rd of October, 2008 at 8:16am
A couple of weeks ago I posted about setting up a web gallery for my friend Jessye Thompson.
Well after me being really busy, slack and all of the above, It is now up and running smoothly and you can visit the site at www.jessthompsonphotography.com. If you live in the North West USA, and are looking for a good photographer for any event, Contact Jess.
The site uses valid xhtml and CSS plus some pretty Mootools effects including Slimbox lightbox by Christophe Beyls.
I have tried using lots of bright colours on a dark background to give it a clean…
0 comments - Monday the 15th of September, 2008 at 10:29pm
For the last few days I have been down in Mount Maunganui for the last few days, it has been really nice to be some where different that kaukapakapa for a few days + I have been flat out busy which is always great.
Shit its nice here.
[gallery]
1 comments - Monday the 15th of September, 2008 at 10:07pm
The last few days I have started coding with a PHP Framework. I am using an opensource framework Code Igniter by Ellislab.
I have never used a framework for coding before so this is quite a change from my normal way of doing things. I have been working with this since Friday last week, but have been pretty busy with other things so it has been an interrupted learning process.
Views | Models | Controllers
This is the part that is slowing sinking in to my brain. It is hugely different from my normal style, essentially everything you write is…
0 comments - Tuesday the 9th of September, 2008 at 2:05pm
Top of the Hill, Kaukapakapa
5:53pm, August 28th 2008.
Taken by Sheldon Lendrum within 20 seconds start to finish.
Comments,
Download
0 comments - Tuesday the 9th of September, 2008 at 1:26pm
As a Web Designer/Developer, when talking to new, potential or existing clients there is always that lingering question, "Why Choose Me?". I think it is because I take pride in what I do, love doing it, and do it just because I can.
I have though about this over time and here are a couple points to ponder.
Do they understand the Scope of work?
Selecting the right web developer is a task that needs careful consideration. It is essential that you seek a reputed web developer who is skilled adequately and equipped with all the necessary facilities. Any developer…
29 comments - Monday the 8th of September, 2008 at 10:39pm
As I mentioned in a previous post about Jess Thompson Photography http://www.jessthompsonphotography.com, I have recently found this great AJAX|PHP Gallery system Minishowcase.
I have written an administration system to extend the already smooth system.
The Administration system plugs in and works pretty seamlessly with the front end.
Some features are;
» plug and play
» no editing original 'minishowcase' files.» adding galleries,» editing gallery text/html files in a WYSIWYG editor» adding images to each gallery» moving images between galleries» previewing,resizing,rotating images ( while keeping their transparencies (gif|png)).» multiple users
[gallery]
It is free to any one who wants it,
I…
2 comments - Monday the 8th of September, 2008 at 10:03am
On friday afternoon I was online chatting with a friend who I have recently converted in to getting a mac, now she has one she is busy letting other people now the benefits of a mac. We often talk, and we were talking about some pretty neat photos she had taken lately and said that she wanted a website for them, but didn't know how and asked for my help.
5 minutes later, she decided on a domain name and it was brought at Go Daddy, 5 minutes after that I set up space on my server and we now…
0 comments - Monday the 1st of September, 2008 at 10:21pm
As a regular internet explorer, I visit a lot of different sites, as a web designer/programmer I am always looking and learning from every half decent site i see.
One thing that I really dont understand, is a holding page that says "Under Construction". I went to a design site the other day that I have bookmarked. This site, made and maintained by web designers/developers which a good amount of google rank and traffic, have pulled down the complete site, and replaced with;
Under Construction
We are currently redesigning our site, check back on October 25th!
Email: xxxxx@xxxxxx.com
This page…
1 comments - Monday the 1st of September, 2008 at 10:01pm
So, you who know me, know I am pretty darn lazy. So in Saturday I got a call from my sister at 7:30am wanting me to go riding with her, as her friend was sick. I was like "Hell No !", but she managed some how to talk me in to it.
We headed over to Woodhill Bike Park on to a bike, and 5 minutes later my thighs were burning, 10 minutes they were killing, and 15 minutes later every seconds breath contained a concoction of swear words.
It was hard work, but fun, I didn't go over any…
1 comments - Friday the 29th of August, 2008 at 9:07am
Robert Kern of www.robertkern.com has found this great article about Project Management and the view from a web developer written by Brandon Ching. I think it is a great article.
0 comments - Monday the 25th of August, 2008 at 7:51pm
2008 Olympix
Now, I didn't watch that much of the Olympics, I watched a few events NZ were in, the Evers-Swindell sisters win gold and that about it.
Its not that i don't support NZ, or any other country, but i'm just not that much in to sport or the olympics that I could sit and watch that much TV.
New Zealand did quite well for such as small country, New Zealand got nine medals - our best since Seoul 20 years ago.
How ever, of the few sports I did watch and the 3 minutes max of the beach…
1 comments - Sunday the 24th of August, 2008 at 10:17am
Today it was wet, wet and horrible. There was Thunder, lightening and heavy rain. It was Yuck! Not as bad as it has been many times this winter, but Yuck!
So, being bored out of my mind, and trying to give me internet a break over the weekends, I decided to go for a walk. As part of my plan to get myself fit, loose the beginning of my beer gut and build up a little muscle in my lazy self I am going to walk, the occasional push-up and/or sit-up, and eat the less occasional healthy meal.
I dressed…
2 comments - Sunday the 24th of August, 2008 at 9:15am
Backing up your site and files is a Must, and many servers have back-up options available to them. But one thing that is forgotten far too often when backing up your site, is backing up your database.
With a blog, like this and most wordpress blogs, the only part of the site to regularly change is the database. The site itself rarely changes other than the few uploaded photos.
Every Post, Comment, Trackback, registration all modifies the database. I like to take mywordpress DB from this online Blog, and dump in to my local copy so I have content, and…
1 comments - Wednesday the 20th of August, 2008 at 6:04am
This is a free WordPress theme available for download.
Is it a Clean, 2 Column Layout with a Left side Navigation / Sub Navigation. The Sub navigation uses Mootools to appear, and will display Posts under their Categories.
It has support for Gravatars and Widgets, includes the Header PSD and is fully xHTML and CSS Valid all for free!
Download: [download#3]
1 comments - Wednesday the 20th of August, 2008 at 2:50am
Configuring my new Thomson TG8585v7
thanks to lightning on friday night that fried my previous modem ( DLink 604t ( No big loss)), My ISP Telescum sent me a replacement. Thanks you Telescum!
Contents
First Impressions
Digging Deeper
Account Connection
Port Settings
First Impressions:
Pretty
In the box: Modem 4-port 10/100, WiFi b/g, 2m Cat5 Cable, 3m RJ11 x RJ11 Telephone Cable, 2x inline ADSL spliters
Child-like Interface
Navigation structure is confusing.
Digging Deeper:
There is no default User/Password, So once I found out my default router IP from my Network Preferences I access the interface via Safari, http://192.168.1.254
The…
0 comments - Tuesday the 19th of August, 2008 at 1:28am
I have just launched my site with a theme that I have made myself completely from scratch.
It uses multiple colour sets and some 'grunge' style imagery. Let me know how you like it, and if you come across any bits and pieces that aren't working.
The site uses CSS 2/3 and xHTML code, with a heavily modified version of Wordpress 2.6.02.6.1
I have made all hacks to Wordpress 99.9% upgradable so should be good to go with upgrading to the newly released WP 2.6.1. was simple.
I hide all CSS and JS with some simple PHP code and have…
1 comments - Thursday the 7th of August, 2008 at 4:05am
I have had a concern brought to me that using .inc files is a security issue, people can access the xxx.inc file directly and read the full file contents.
While I agree, this can be fixed with a rule in your .htaccess file that will send a 403 Forbidden response to all requests .inc files. I personally like using .inc file extensions for include files rather than .php as there files do not and should not be run directly. To use .php over .inc this section explains what to change.
Download an update from the main SimpleSite post ~ http://sheldon.lendrum.co.nz/building-a-completely-dynamic-site-using-text-files-php-and-no-mysql_187/03/…
1 comments - Tuesday the 5th of August, 2008 at 7:32am
This is a follow up to a previous post http://sheldon.lendrum.co.nz/clean-dynamic-directory-listing-with-php_206/04/ that will Dynamically display the files in a set directory.
In this version the files can be ordered by the date that they were last modified. I will also explain how to order both Ascending and Descending by the date the file was created also.
Example Usages:
< ?php
// EAMPLE USAGE
// SHOWS THE 10 NEWEST .php FILES IN A UNORDERED LIST
echo("". direcotryList("10","./",".php","","\n") ."");
// SHOWS ALL JPG IMAGES AS THUMBNAILS
echo(direcotryList("","./images/",".jpg","\n"));
?>
< ?php
// DIRECTORY DISPLAY USING GLOB SORTNG BY LAST MIDIFIED FILE DATE.
// IF…
19 comments - Monday the 4th of August, 2008 at 11:10am
When writing a post, I don't often write it all in one go, then before I publish it, I save it and preview it, generally more than once.
WordPress has 2 Great ( or not ) features, Auto-Save, and Revisions.
When writing my last post Clean Dynamic Directory Listing with PHP I have some example code wrapped in <pre> tags and WordPress auto-validates code, which is a handy feature, but not here where I was trying to enter my example.So after several saves, and eventually getting in to my mySQL database to fix it and seeing that for hat this…
6 comments - Monday the 4th of August, 2008 at 8:40am
This here is a quick couple of functions to dynamically display files from any given directory.
It allows you to display it is a nice format with/out the files extension.
Pretty simple, but comments/suggestions/ bugs are very much welcome!!
< ?php
// DIRECTORY DISPLAY USING GLOB AND A CLEAN PATH OUTPUT.
// IF ALL PERIMATORS ARE EMPTY WILL SCNA DEFAULT DIRECTORY
// '$path' => PATH TO DIRECOTRY TO SCAN
// '$ext' => FILES EXT, IF YOU WANT OT ECLUDE IT, OR ONLY SCAN FOR ONE TYPE OF FILE
// '$start' => APPEND TO START OF OUTPUT LINE EG: '' OR…
1 comments - Sunday the 3rd of August, 2008 at 9:13pm
Do you have an image or images that people are using on their site, Not giving you the credit for your artwork and using your bandwidth?
With a simple .htaccess on your Apache server you can prevent Image HotLinking.
In your Images Directory, or in your mail web root if you have multiple image areas create a .htaccess file. If you already have one, we can just append the following code in to that.
Insert this in to your file.
RewriteEngine On
# REPLACE lendrum\.co.nz WITH YOUR DOMAIN NAME
RewriteCond %{HTTP_REFERER} !^http://(.+\.)?lendrum\.co\.nz/ [NC]
RewriteCond %{HTTP_REFERER} !^$
RewriteRule .*\.(jpe?g|gif|bmp|png)$ - [F]…
1 comments - Sunday the 3rd of August, 2008 at 12:00pm
This is a cool tip that will work on and OSX Computer.
You can get your mac to sing and swear and talk anything via a simple Shell Script.
You can even get my mac to talk... I will be able to hear what you type ( But you can't :( )
Alex
Cellos
If you are on a mac, try this at home....
osascript -e 'say "Sheldon is Awesome!" using "Cellos"'
1 comments - Sunday the 3rd of August, 2008 at 10:31am
I spent a fair amount of time trying to help people on PHP forums such as webdeveloper.com : Sheldon and one thing I see on a regular basis is over complex systems for basic site structures with people who at this stage don't have enough knowledge of PHP to build a secure structure.
Now don't get me wrong, their not stupid, and I'm for sure not the greatest !
So, tonight, a sunday evening, nothing on the tele, and less of a social life lately it seams. I have spent 2 hours building a completely dynamic flat file web structure.…
0 comments - Friday the 1st of August, 2008 at 9:58am
I live now in greater Auckland. Kauakapakapa. its about 1 hour/ 1 1/2 hours north from the CDB ( Central Business District) I grew up in Kaukapakapa, Went to school in Helensville, Moved to Auckland City for 2~3 years, Moved back to kauakapakapa, Got married, brought a house in Helensville, marriage broke up, whore ran off, moved back to kaukapakapa. Spent 8 months in the USA, came back to Kaukapakapa.
Did you catch all that ? Thats a lot of moving backwards and forwards to kapkauakapa!
My Plan.
6 years ago: Become a Qualified Carpenter, create websites as a side…
0 comments - Friday the 1st of August, 2008 at 9:20am
Wellington... I have only been there once. It was a flying weekend once, oh maybe... God... 5 years ago. and really its wasn't a flying weekend, so much as a fucking boozy weekend - partly landing in Wellington...
For a one way town, I am looking to go head down there...
2 comments - Friday the 1st of August, 2008 at 6:59am
IPv6.
Internet Protocol Version 6, The next internet lookout word.
So with a side WordPress project I have been working on ( More info and links to come ) I have been looking at IP addresses, and with this, looking in tho the SHIT state the Internet, not only New Zealand, but everywhere, These is stuff thats needs to be sorted, and only few counties are doing it.
While the speed of internet access is a problem. The other issue is overpopulation. The growing number of people connecting more and more PCs and other gadgets is fast using up the…
1 comments - Friday the 1st of August, 2008 at 1:00am
Tremor the Free Wordpress Theme by Quake Media.
0 comments - Wednesday the 30th of July, 2008 at 8:37pm
Photos of the wet & wild winter rain!
7 comments - Saturday the 26th of July, 2008 at 5:52am
A step-by-step Guide to installing PHP, mySQL and getting them both running together on Apples OSX Leopard. This requires root access and a little Terminal usage.
2 comments - Saturday the 26th of July, 2008 at 1:11am
Its wet, cold and worst - there is No power. But thanks to an old UPS, I am online when there was nothing else to be doing.
1 comments - Wednesday the 23rd of July, 2008 at 11:07am
Installing Windows on a Non-Intel Mac ? You can, and it is pretty easy thank you to Q, A Mac port to run virtual OS's on your older mac. I now run Leopard 10.5.4 and Windows XP SP3 on my iBook G4.
3 comments - Sunday the 20th of July, 2008 at 6:06am
With my favorite FTP Client, Cyberduck becoming unstable, I'm moving to Transmit. I am loyal to Cyberduck for it is a great application, but with its recent upgrade to version 3+ it has become incredibly unstable and frustrating. Transmit sure is different...
0 comments - Sunday the 20th of July, 2008 at 5:16am
Mac fans are increasing, as they should! and man that makes me happy.
0 comments - Saturday the 19th of July, 2008 at 10:16am
This CAPTCHA is a PHP script that protects websites against spam bots by dynamically generating a random string of text that humans can read but current computer programs cannot. For example, humans can read the randomized text as the one shown below, but automatic spam systems ca not read the random image text.
0 comments - Saturday the 19th of July, 2008 at 8:18am
The wonders of VoIP and customizing the experience. How we can talk in New Zealand and the US on one phone and making that phone look the part. Can we make it sound cool?
1 comments - Friday the 18th of July, 2008 at 8:56pm
I really hate spam, So why did I write a dirty spam script to flood my friends mailbox? To prove a point that its not fun!