Announcing WordPress Automatic Installer

Good evening peoples.

I’d originally been planning on announcing/releasing this at another time, but plans have fallen through. So instead, Its happening now. This is a small preview video of whats to come, All in all, the  script (as you see it below) is ready to go, I have a few more things i want to add to it, but for now, its working quite nicely, Installing WordPress and configuring it all in one sweep, in under 65KB of code (Which might i add, Could be made much smaller, But I’m using WordPress Libraries – HTTP + Filesystem + WP DB + Various Functions for the ease of use they provide)

Now, Onto the video, Its a 1024x800px video, So i’m not sure how this is going to embed, I’m trying out Vimeo for this, But heres a direct link to the file anyway: WordPress Automatic Installer

I’ll be posting a link to download the script/App in the coming days, I’m not going to be very available in the next few days, So i’m delaying it until i’m available to answer questions/etc. If you’ve got any, ask away in the comments, and i’ll write a FAQ up based off them.

I fully expect this Vimeo video to be unwatachable due to the resolution.. So the above xvid may be the only way, Or wait till mid week for a post with images instead.. (I found clicking the full screen icon helps a lot)

Stats:
Over 14,000 lines of code (Much from the WordPrss Libararies)
520KB worth of code before my custom Builder/minimiser hits it
228KB worth of code after my custom minimiser hits it
65KB worth of code after Gzip’d and Base 64’d for distribution.
1 file installer – Yep, No need to upload 8MB of files, just a single 65KB file, and let your web browser do the rest.

Edit: I’ve promised people alpha’s of this, and never gotten around to it, Simple reason has been that i’ve been having less time available for WordPress, and i just need to get things out there rather than letting them be tested, So run a much, go make conspiracies about what  my code may bring, But return and review  the code when its released in a few days.

Oh one more thing, I need a name! So start suggesting names, “WordPress automatic Installer” it is for now, But i’ve got 3 others in mind, of course, the domains are taken on all of them, So if you’ve got something you think is a go-er, Send me a email via my contact page, I’m sick of people squating on good domain names..

Oh, One more thing! The Carrington Blog theme SUCKS ASS. Not only did i have to recode crap in it, but now i find out the content column is more than just fixed width, its damn scrollbar width…. I wish i had the time to actually code something decent for myself once in awhile instead of giving back to the community..

You know what sucks? Installing WordPress..

Yep. I’ve always hated installing WordPress, When i’m creating a new WordPress install, its because I want to play with it right NOW, not in 10 minutes, not in 30 minutes..

Many people will quote the “famous 5 minute WordPress install” but like nearly every other decent sized Web app. out there, This simply isnt true

I mean, Step back for a moment, and look at the steps that you have to do:

  1. Download the Install package from the website – 7MB ~1 minute on a 1.5Mbit connection
  2. Extract the Archive – 20 seconds
  3. Open your FTP Application, Upload the 10MB of files, ~30 minutes
  4. Visit the Location you installed it in, Run the install ~2 minutes
  5. Realise PHP cant create its config file automatically, Create it manually, ~5 minutes

Hooray! We have it installed!

..Now, that  “quick” install took nearly 40 minutes.. I dont know about you, But by that time I’ve usually nearly lost interest in what I was originally doing..

Luckily, Since we now have the Core Upgrades as part of WordPress,  We dont have to deal with a 30-minute FTP Upgrade.. Its more like a 1-2 minute upgrade..

Thankfully.. People like to automate things, And there are a few other alternative methods of installing,  For example, Some hosts now offer Auto-Installers such as Fantastico, Unfortunately these are not always 100% up-to-date when a new release comes out, and often only allows English installs.

(Side note: Yes, I now use SSH + SVN, so a new setup only takes me ~2 minutes via the Command line)

Remove WordPress 2.8’s Default Password Nag

WordPress 2.8 includes a Password Nag for when you’re using a default generated password. This was done intentionally to help forgetful people like myself who make new installs, and promptly forget the admin password.. You can find the Trac Ticket for it here:  #9710

I’ve been asked how to disable it, A fair enough request, and a very simple thing to achieve.

Simply put this code into a plugin, Or your theme’s functions.php:

[sourcecode lang=”php”]
remove_action(‘admin_notices’, ‘default_password_nag’);
[/sourcecode]

And you’ll never see that red box again..

Bet you weren’t expecting this…

The Carrington Theme.

I got fed up of my old theme which was breaking badly.. And came to the realisation, That i just don’t have the time to make myself a new theme; and to be honest, This was the first theme which i liked, which took the most minimal cleanup.

Yep. Cleanup.

I am SICK of themes and plugins which are  riddled with PHP Notices/Warnings, Now those of you who are programmers might be saying “Who cares, it works doesnt it?” Well the only answer i have for you is, Yes, It works, But only because PHP is guessing thats what you intended! You see, PHP is a very loosely typed language as we all know, Its it buigest (and buggiest) feature in my opinion. Its allowed plenty of generations of PHP Programmers to take shortcuts, and to not care about their code.

One such annoyance i’ve come  accross with Carrington was this:

[sourcecode lang=”php”]sprintf(__(‘Misc.’, ‘carrington’), $key)[/sourcecode]

Thats not too dodgy, But $key is undefined, Which issues a warning. But  wait, What was the point of sprintf() in the first place?

The major problem i have with themes and plugins (which i’ve not written mind you) is the lazy array index accessing. Let me ask you this: Do you see if theres a car in a Garage before you attempt to drive it out? Or do you just attempt to sit down in mid-air and then realise “Oh! There isn’t anything here!” Well thats exactly what lazy array index access is! Take this example:

[sourcecode lang=”php”]if ( $_GET[‘page’] == ‘carrington-settings’ ) {[/sourcecode]

Its attempting to drive the car out before checking to see if it exists, Thats going to cause a php notice as such:
( ! ) Notice: Undefined index: page in …..php on line x
The answer is VERY simple here… Just check to see if the car exists:

[sourcecode lang=”php”]if ( isset($_GET[‘page’]) && $_GET[‘page’] == ‘carrington-settings’ ) {[/sourcecode]

So there we have it.. Notification that I’ve started using the Carrington Theme, A Rant about horrible coding standards, And I haven’t even begun to explain why I hate “Theme  Frameworks” (In short: They contain a lot of rubbish. 1.5MB across 166 files for Carrington?! C’Mon!)

Oh. PS: Upcoming project – Any ideas?