Monday, December 11, 2006

Underwater In Photoshop (Great Video Tutorial)

This is a sped-up demo of how to create an underwater scene using Photoshop without the aid of any images from the net.

read more | digg story

Add Text Bubbles To Videos (YouTube, MetaCafe, GoogleVideo and others..)

Brand new Israeli startup BubblePLY has created an easy tool for adding text or link comic-book style bubbles to videos from popular video sharing sites. Tell it the link to a video on YouTube, Google Video, Metacafe and others, and then add your own content. The video is saved and can be shared via a link or embedding on a web page.

read more | digg story

Monday, December 04, 2006

Methods for Downloading Google Video as FLV, AVI, or MP4

Article showing how you can query Google for RSS, and extract information on FLV, API, and MP4 files to download. Use it to create your own Google Video download site.

read more | digg story

Test drive Beryl on a Live DVD. Works with most video cards

There have been several post showing off Beryl recently, but a lot of people have been having a hard time getting it to work. Just pop in this DVD, and reboot your system. You will have a fully functional Operating System with accelerated graphics and Beryl running live. Works with ATI,Nvidia, and Intel integrated video cards. Nothing to install

read more | digg story

Good Ubuntu Networking Tutorial for Beginners and advanced users

This is step by step tutorial how to configure networking in Ubuntu this includes Configure your network card using GUI tool for beginners and from command line for advanced users.this will also explains how to troubleshoot your network related problems

read more | digg story

Friday, October 06, 2006

Monday, August 07, 2006

Gallery of stunning digital photography with tutorials

This guy uses a very scientific approach to photography with wonderful results. The site is packed with technical data and tutorials which provide practical "how to" information for any digital photographer, but a visit to the gallery is worthwhile for anyone.

read more | digg story

How To Crack 128-bit Wireless Networks In 60 Seconds [inc Video]

128 bit WEP encryption secure? Think again! KisMAC + standard dictionary cracks two keys in under 60 seconds. "I'm not even sure if I want to run a wireless network anymore to be honest..."

read more | digg story

Thursday, July 06, 2006

Basic journey of a packet

" The purpose of this introductory article is to take a basic look at the journey of a packet across the Internet, from packet creation to switches, routers, NAT, and the packet's traverse across the Internet. This topic is recommended for those who are new to the networking and security field."

read more | digg story

Tuesday, July 04, 2006

How To: Create your own game company, Part One

Posted Nov 28th 2005 4:40PM by Victor Agreda, Jr.

While it's a little cost prohibitive to start developing Xbox 360 or PS3 games from your bedroom, let's not forget games like Roller Coaster Tycoon and Alien Hominid went from humble beginnings to financially successful franchises. Although you'd have to spend hundreds of hours developing AAA titles, there are some ways to get slick games up and running quickly. I'm going to show you a few ways to do just that.

In this installation we're going to look at the beginnings of your company. Starting with a great idea, creating all the necessary assets, and developing the prototype. Next time, we'll look at further development, building your team, and expanding your empire... And wherever possible, we're going to use free or shareware tools. If you're interested in the business end of things, and a good overall setup to the crazy business of games, read Gregg Man's article here. A little dated, but still topical.

Of course, nothing beats a great idea. Unfortunately, good ideas are everywhere. What you need to do is make sure your amazing idea is developed properly. My suggestion is to read Chris Crawford's classic "The Art of Computer Game Design" (it's a PDF link at the bottom of the page). Honing a great story into amazing gameplay is step one. Crawford's book is only the beginning, and you'd do well to rad some informative articles at Gamasutra for more insider tips. A great story with lousy gameplay will get you nowhere, while a great game with minimal story could be the next Marble Madness. Now let's get to making our fantasy reality by creating our graphics and wiring the game engine together... Big list of apps for developing your game after the jump...


The choices in platforms for a game makes a big difference in the tools you'll need to create everything. Using Flash, for instance, often means never having to touch a 3D modeling application. Something like Java could draw images on-screen in realtime, all through code.

But if you're a hobbyist game creator, I'm assuming you're going to need graphics for your game, and a somewhat simplified game engine. The tools I've selected won't do what months of time in C++ and 3ds max will do for you, but they're perfect for creating a usable game in a decent amount of time.

The general workflow I'm assuming here is 1) create graphics and models, 2) create game code, 3) distribute. This is a gross oversimplification of the process, as you often will be testing small bits of code while creating visual assets, and game-testing constantly. I also take for granted your idea for game story and game play has been developed. Check out the VRML narrative storytelling page for ideas on interactive storytelling if you need more inspiration.

Graphics
You'll need to create two-dimensional graphics for textures on 3D models, and to paint a background world. A quick rundown of image editors usually pits the free Gimp versus the industry-standard Photoshop. I'll agree those are the top of the game (you can make Gimp look like Photoshop using GimpShop). But when working in small teams you sometimes have to just grab pre-made textures for scenery and levels. Check out the collection of links to textures at 3DLinks and the tons of excellent freebies at Mayang's.

I wrapped up a boatload of free 3D apps here earlier, but for my money Blender is still the best. There's a huge online user group with tons of help, and a script for creating humanoids (one of the most laborious parts of the process). Blender has it's own game engine inside, and uses Python for scripting. Technically you could create an entire game in Blender, but with the web plug-in in developer limbo, and no real documentation for the game engine any more, it's a little risky... Still, looks like CrystalBlend, a combo of Crystal Space 3D (an open-source 3d game engine) and Blender could be promising...
gameco

Engines
If you want to get started really quickly, there are tons of options out there. Obviously you want a step up from just modding a game (although some mods almost qualify as totally new games). Some apps are an in-between of a real engine and a mod. Case in point: FPSCreator. It's a pretty simple FPS engine, with scripting support for more customization. Most everything can be done using drag-and-drop, and it comes with an assortment of pre-made models and characters. It's like Poser for games, really.

What I tend to think of for prototyping games are the BASIC-derived engines, like DarkBASIC and BlitzBASIC. Both are geared towards beginning game programmers, and both languages are geared towards rapid game development. Dark comes in regular and Pro versions (Pro adds more developer-friendly tools and better mapping). Blitz comes in a number of varieties, with one geared for 2D games, and another for 3D. Blitz also offers a free app called Maplet, designed to help build game levels quickly.

I know discussions of tools like this can get religious very quickly, so I want to point out I'm pretty neutral when it comes to these things. I have a particular way of programming, as do others. I recommend anyone sit down and look at the documentation and support communities before picking any pony... You're going to have to ride this one decision for a while, so choose carefully.

Some other tools include: GLBasic, and excellent choice for those with programming skills; Unity is Mac-only for development, but will export Windows games; and Cube looks cool, but I haven't had a chance to tinker with it. There's also Adventure Game Studio, Coldstone, and RealBASIC out there.

For those of you way ahead of the game, and willing to tinker with C++ you can check out Crystal Space 3D, Genesis 3D (both are open source), or industry veteran Torque. Project managers like Torque because it's a known quantity. GarageGames provides an indie license for $100 (and a free demo download), which is pretty reasonable for what you're getting... For a thorough list of realtime 3D engines (not necessarily suited to gaming) check out this list.

What tends to distinguish the game engines versus a simple graphics engine is the inclusion of interactivity wiring (like triggers for actions) and a physics system. Unity has an excellent physics engine, as does Torque. As I said, you'll want to test these or read the forums for each product to see if it fits the type of game you're making. Who knows, you might just need Flash. That's not a bad idea, considering you can desploy swf's to a broad audience (PC's, cell phones, PDA's).

And speaking of distribution, next time we'll look at finishing up your game and deploying it to the world. Most often this is online (especially for server-based games), but I'll take a peek at some physical means of distribution too. We'll also examine methods of payment for your hard work. If anyone uses a tool that can't live without, be sure to post in the comments below.

Sunday, June 11, 2006

How to delete an undeletable file.

Here is a tip to get rid of these undeletable files.Lot's of times many files in your pc are undeletable.
Well,here is a tip to delete anything You want!

Open a Command Prompt window and leave it open. Close all open programs

Click Start, Run and enter TASKMGR.EXE

Go to the Processes tab and End Process on Explorer.exe. Leave
Task Manager open

Go back to the Command Prompt window and change to the directory the AVI (or other undeletable file) is located in

At the command prompt type DEL where is the file you wish to delete

Go back to Task Manager, click File, New Task and enter EXPLORER.EXE to restart the GUI shell

Close Task Manager

Ok no problem again with these awful undeletable files

read more | digg story

Saturday, May 20, 2006

How to create your own game company

How To: Create your own game company,

Posted May 19th 2006 8:00AM by Victor Agreda, Jr.
Filed under: Business, Design, Developer, Finance, Games, Internet, Utilities, Features, Windows, Macintosh, Linux, Windows Mobile, Symbian, Palm, Productivity, Web services, Shareware
how to create your own game company part twoIn part one I talked about a lot of the production tools: 3d apps, game engines, and so on. This time I want to tie that in to the business end. How do you run the company, and how do you make money?

First of all, I discovered PopCap Games offers their engine to developers for free. The license agreement spells out the details, but primarily all you need to do is acknowledge using the PopCap Games Framework. The practical upshot of using PopCap's engine? They might publish it. The practical upshot of getting an engine and look by a successful publisher? You can make money. You still have to file taxes, and do all the other business stuff you'd normally have to, but you get to skip the part where you worry about marketing, payment, etc.

One other development is the rather old Torque Exporter Plugin for Blender is now up to version .91. Since Torque is $100 puny bucks for an indie license, and Blender is free, that also seems like a reasonable choice for budget game developers. If you're still thinking 2D (or very limited 3D, like an isometric game), another option is the Arcade Engine for Runtime Revolution.

So lesson #1 in business: keep your costs low. I don't want to get into a lot of business advice, but if you want some great tips on what NOT to do, check out Ten Easy Ways to Screw Up Your Game Company, and Part 2 of the same. If you're really looking to make a company, and can get investors, there's a lot of funny and valuable lessons to be learned in those few pages...

And not to be redundant (which I'm good at), but Lesson #2? Pick the right product. I know, the author of Ten Easy Ways says the same thing, but this lesson is too important to miss. You can spend thousands on the Unreal engine if you like, but trying to make another Halo? Good luck. It's not impossible, but unlikely. Shoot for realistic early goals and clean up with original, playable content. Now, on to the software!
Building your team

So you've got an engine, you've got an idea, now what? Unless you're some kind of modern-day Da Vinci, you're going to need people to help out. I'm no HR expert, but I can safely say this might be the worst, most challenging, yet potentially most rewarding part of the process. For one thing, a great staff member can elevate the team to new heights. A bad worker can literally bring a project to its knees.

hiring peopleWhat to do? Be very honest with candidates. And force them to be candid with you. One of the coolest approaches I've seen to hiring involves a test in the form of a game from Procter and Gamble. You can start asking friends if they know anyone with the skills you need, and move outward that way. If you're lucky enough to live in a place with a major university nearby (as I do), another opportunity is offered in the form of student workers. And lastly, there's always online recruiting. Online is tough, even with the breadth of choices. It's just very difficult to gauge someone from a distance (kinda like it's hard to convey sarcasm in an email). The first place I usually look or post is Craigslist, and there's probably one in your area. If you're really desperate, there's always a professional solution like Elance.com. Mine those forums and consider targeted markets like GamesIndustry.biz and GameDev.net for talent with experience.

Personally, I've always been a fan of testing personnel. And since you're looking for people with a passion for games, why not host a LAN party, put them all on the block, and have a quick deathmatch? This won't necessarily tell you how well someone can allocate memory or manage UV texturing, but it'll tell you who the griefers are. Don't hire the griefers!

At the end of the day you need to at least have leads in the major development areas: Programming (or tech lead), Art, and Design. Programmers need to be drilled on their skills pertaining to your particular platform. If you need a Python programmer for Blender, don't quiz them on ActionScript. Artists should have a portfolio, and the ability to whip up some artwork on the spot. As for design, I'm referring to the game design. Chances are the game designer, or "vision keeper" is you. I'd still recommend bringing in someone with game design education or experience, even if they are only an advisor. Make sure to check this person's credentials though. Playing Kingdom Hearts for a week without sleep doesn't make you a game design expert.

Documentation

Game documents, who needs 'em? Everyone. Every TV show has what's called a Show Bible. This is the law and lay of the land. Is the main character a pedophile? That little detail might never be revealed on the show, but the actors and directors need to know it, as it would influence the characters and stories on the show.

The same applies to games, only more so. You'll need a Game Design Document first. The Design Document is essentially the vision, point, and basic rules, setup, and look of your game. It is truly the "bible" for your game. Extending out, you'll need an Art Bible, with examples of the look and feel of the game, the design of characters, basically any art in the game. And you'll want a Technical Design Document. This spells out things like your target platform, tools to use, and the potential problems with programming your game. If you're making a Flash game, how are your programmers going to simulate 3 dimensions?

The reason for these documents? Whenever there's an argument over what to do, consult the bibles. An Art Bible ensures a unified look for all the art assets, and makes your game look more professional. The Tech docs make sure the programmers know what to expect. And the vision absolutely must be spelled out. Listing everything you need for a game is an exhaustive process, but one you're going to have to do if you expect to ever finish the thing.

Project management and communications

Project management, in the simplest sense, is very simple. Take the end result desired (make a playable game), and start breaking this down into actual tasks, then plan those tasks across a realistic timeline. Check every day, week, month at different levels (big picture vs. details) to make sure those "milestones" are getting done as appropriate. Looking for an alternative to Microsoft Project? Personally I use a meatspace tool called a legal pad, but those of you wanting software should check out Open Workbench.

communicationsAs for communication with the team, the usual stuff works wonders. Instant messaging with Meebo allows you to be protocol-agnostic. Jotspot offers a pretty good wiki service. And Google's Calendar and Notebook might be just what you need to push dates and talking points. Although I personally think Basecamp is the bees knees. And then there's that old standby: email. I think Gmail has a pretty good advantage here too, due to Calendar and chat integration, plus a powerful search ability.

Each department is going to have specific needs however. Artists need a place to store and log graphics. Programmers need a CVS for managing code. Let's look at each department to see what they need.

Design: I consider design the actual game design, not art assets. Consider an all-purpose CMS like Drupal (which I'm a big fan of), or Typo3, which is actually used by some Blender nerds. What you're wanting to do is have a central repository for "the vision" of the game. A CMS is a good place to put those design documents.

Programming: these guys need a CVS! Essentially this is a way to check in or out code, without messing other stuff up. Managing code is a tough process, and I'm a hack myself. Besides, coders tend to be religious about ways to do this, so to avoid a holy war, I'll just point you to a great book on the subject-Open Source Development with CVS by Karl Fogel and Moshe Bar. Almost everything else is dependent on your platform of choice. Flash, as an example, has its own IDE for ActionScript inside the app.

Art: ultimately these are the guys with a need for a good filing system. This could be as simple as a file server, set up with a very strict nested folder system. For example, a folder with "Characters" could include subfolders of "NPC's," "Heroes," "Bosses," and so on. Inside those would be the model folders, texture folders, and perhaps backup folders for previous versions. You can also use CMS's like Drupal to set this up, as the nature of the CMS versatile enough to handle art assets.

Finally, there's another good ebook to check out: Producing Open Source Software, also by Karl Fogel. Karl's book is a wonderful introduction to the problems (and rewards) of working with a large group of squirrels, each one with their own agenda. If you're looking for more workflow ideas, check out this post.

Testing and marketing: mutually exclusive?

The QA portion of game development is generally a time when the time grows very large. Bug testing can be really expensive, but I don't think there's a need for all that. At least, not when you're the underdog! Years ago I read the book Guerilla Marketing, and it's had a profound influence on my view of marketing. This might be sacrilege, but I suggest you release the game as a limited public beta, and somehow reward bug finders. That's not a new idea (Google I'm looking in your direction), but might take some of the bug hunt pressure off your programming team. The key is to be very open about the stage your game is at. If it's really, really rough, maybe only test with some friends. Once you can more or less successfully navigate every level, that's a good time to open it to the world. If you're really wanting to spend the cash on QA, and I'm not denouncing that approach, Game Instict offers QA-for-hire services.

The bottom line is QA must be done. There are no shortcuts. During the development of Jak X: Combat Racing, the Naughty Dog team tested the online play every Friday night. They'd go home, dial in to a private server, and play against each other. Not only did this uncover code issues, it allowed them to collaboratively discuss gameplay issues. If you're really passionate, this won't even seem like work.

Making your money

So you chose a reasonable target platform that doesn't cost too much to develop for, you have a great team, and you've managed to test the game until the play is just perfect. The next step is to sell your game.

making moneyYou can find a myriad of advice columns on how to approach a video game publisher to sell your game. Some publishers come from a development background (like PopCap and now Gamelab) and might appreciate you more. Maybe not. The advantage of a publisher is that you get an expert in sales and marketing. That's the theory. As any musician will point out, whether or not that expertise is used is another matter... But the big point is to have a complete, playable game, free from licensing issues (like music). It helps to have an idea of how to sell your game too, especially if it is very unique. Publishers tend to be a little conservative...

So I say strike out on your own. Between guerilla marketing and online payment systems, I don't see why you couldn't at least generate a little cash yourself. This might even be enough to woo a tough publisher. So how do you sell online? I mean, aside from PayPal.

Unfortunately, Regshare.com isn't around any more (they're selling the domain, ugh), as they used to do comparisons of online payment systems. But probably the most recognized name in the business is Kagi. If you've ever bought a 3rd part Palm app, you might recognize them. MacDevCenter has a comparison of Kagi vs. DigiBuy and eSellerate, for those still looking to shop around.

You could also implement your own payment system, but that is as varied as the mechanism and platform you're developing on. My own company just uses Paymentech for processing credit cards, but I've found that's overkill for an indie shop. If you're just moving bits around, Kagi works well. If you're selling physical units, consider just setting up shop on ebay (or wherever you like) and go nuts.

Other resources

I am a regular reader of Gamasutra, and you should be too. Sloperama's advice pages are chock full of great industry info, on everything from game programming to the actual gameplay design. You might want to read and check out the blogroll on Greg's blog on Games, Design, Art, and Culture. If you have some time and want to have a little fun, check out GameGame, a card game about designing and pitching games.

If anyone has any other great sites (I know I've left out a ton), please post 'em in the comments. There's no easy solution to making your own game company, let alone a truly saleable game. But hopefully with enough understanding of the process you'll be a little closer to realizing the Next Big Thing on your own.
read more | digg story

Thursday, May 18, 2006

Streaming MythTV to your cell phone

Streaming MythTV to your cell phone

Electrical tape wearing thin holding together my old cell phone (Samsung i500), I decided it was time to give in and upgrade to a new phone. I drank the kool-aid on a 2 year Sprint contract given the discounts both on the phone and in my monthly service, and in the end settled on the Samsung a920. It's an EVDO enabled phone with Sprint's $15 unlimited monthly data service. Playing around with the mobile TV functionality (that's an extra $10/month but I was enjoying the first month free), I had one of those lightning bolt moments.

Why not stream my own video to the phone? Better yet, why not just automate my MythTV to convert my recorded programs and automatically have them ready to be streamed whenever I care to watch them on the phone?

A bit of research later, I discovered SlingBox can stream your tv to your phone, but it needs to be a Windows mobile phone and then there's the monthly service fees and the box to buy. I also found random mythtv devotees with similar ideas at least as far back as January 2005, but couldn't otherwise find a concise guide or more information. Inspired by ZooVision, I knew it was possible for users to stream their own content to their phone, it was just a matter of putting the pieces all together. A couple hours of tinkering later, and I've got a working solution... my "tivo" on my cell phone wherever there's sprint evdo access. So here are the steps:

1. Get MythTV up and running. I won't go into that, but it's worth the hassle even if I couldn't stream it to my cell phone.

2. Follow these directions which will get you an updated version of ffmpeg (named ffmpeg3gp) and a myth3gp script which, in combination, allow you to take Myth recorded video and convert it to 3gp, a mobile video format standard that most multimedia phones support. However, instead of using the myth3gp script from there, you'll likely want to use this myth3gp script as I've included a couple of necessary changes. Save that txt file as /usr/local/bin/myth3gp on your Myth box.

3. Create a directory to hold your 3gp videos on your Myth system. Open up the myth3gp script from the previous step and change the line that says:

out="/mnt/drive2/myth3gp"

to:

out="/directory/for/saving/your/3gp/videos"

4. Install gpac. Once you've compiled and installed gpac, it will provide you with an executable called MP4Box which is used to convert the 3gp file from step two into a 3gp file that is streaming enabled. The myth3gp script calls MP4Box to take care of this for us.

5. Find an internet connected server which can house your 3gp videos and be available to stream them at will to your phone. On said server you'll need to install Apple's Darwin Streaming Server. Installing it can be a bit of pain, but just be sure to have port 554 open so that it can handle the rtsp streaming protocol. For me, getting Darwin to work took the most effort. If your MythTV box has a static IP and is internet accessible, that should work fine, but in my case I'm uploading the videos to another server.

6. We're in the homestretch. We've got programs to convert Myth recorded video to a phone friendly format, and we've got a server that can stream them to our phone. We just now need an automated process to convert the video and upload it to the server running Darwin and we'll be in phone tv nirvana. Myth can do this automation for us. You'll need to exit out of Myth and run:

mythtv-setup

From there, choose the "General" menu item and hit enter until you get to the "Job Queue" screen. Put a checkmark in "Allow User Job #1 jobs and continue to the next screen until you get the page with label "User Job #1 description". Give it a description like "Myth 3GP" and for the command, use (note the quotes):

/usr/local/bin/myth3gp %DIR%/%FILE%

"%STARTTIME%~~~%TITLE~~~%SUBTITLE%"

Save your changes, exit, restart the mythbackend and restart Myth.

7. With Myth restarted, go into Utilities / Setup -> Setup -> TV Settings -> General and click through until you get the "General (Jobs)" page. On this page, put a check in the checkbox next "Run User Job #1 On New Recordings". This will ensure that our process gets run after each new recording. Important Note: For all existing recurring recordings that you had prior to setting up Myth3GP, you'll need to manually edit the recording options and in "Post Recording Processing", you'll need to switch its setting so that it says "Run 'Myth3GP'".

8. If your using your local Myth system for Darwin streaming, just be sure that Darwin knows where to find the 3gp files on your system. Otherwise, edit the myth3gp script from step number two and set the darwin_username, darwin_hostname and darwin_dir as appropriate for your external server. At the bottom of the script, it uses scp to transfer the file from your Myth system to your Darwin server. Though, for everything to be automated, you'll need to set up scp to not require a password. Directions for password free ssh/scp are short and sweet. Once you can transfer files between systems sans password, you are good to go.

9. The final step. On your Darwin machine, make sure you have a web server running (apache), php installed and place this php script somewhere in a web accessible folder. It's job is to scan your 3gp movie folder for movies and generate a webpage with rtsp:// links so that you can access your recordings from your phone. Edit the php script and change $directory to the directory path for your 3gp videos and set $hostname to your hostname. With that installed, you're done. You can manually convert your old recordings by starting the "Myth3GP" job on them and any new recording will automatically get the mobile treatment. Fire up the URL for the mythmobile php script and start streaming.

Triumph. Indeed some beautiful uses of fair use. Fair use to record the tv program to my hard drive... Fair use to convert the video format to one viewable by my cell phone... Fair use to stream it to my cell phone for my own personal enjoyment. Now imagine trying to do any of this with the broadcast flag in place.
read more | digg story

Monday, May 08, 2006

Dark Side of the Moon celebrates 1500th anniversary

1500 weeks on the Billboard Charts that is, making it the longest selling album of all time. Do YOU have your copy?

read more | digg story

Friday, May 05, 2006

The Night Sky on Your Desktop

What is Stellarium?

Stellarium is an open source desktop planetarium for Linux/Unix, Windows and MacOSX. It renders the skies in realtime using OpenGL, which means the skies will look exactly like what you see with your eyes, binoculars, or a small telescope. Stellarium is very simple to use, which is one of its biggest advantages: it can easily be used by beginners.

read more | digg story

Tuesday, May 02, 2006

A parade of stars at Wednesday's 'Prairie Home' premiere

StarTribune.com

Last update: May 02, 2006 – 3:29 PM


Lindsay Lohan, Meryl Streep and Lily Tomlin will be on parade in downtown St. Paul Wednesday evening. Those are just three of the actors in "A Prairie Home Companion" who will ride to the movie's premiere at the Fitzgerald Theater in horse-drawn carriages.

In all, 10 carriages will carry cast and crew, including director Robert Altman (of "M*A*S*H" fame) and of course Garrison Keillor, who wrote and co-starred in the film, based on his radio show. Kevin Kline, Virginia Madsen and John C. Reilly also are expected to attend, along with "PHC" regulars Tim Russell and Sue Scott.

The carriages will leave from Rice Park at 6:10 p.m. The best star-gazing spots will be on Wabasha Street between 5th and Exchange Sts. The carriages are scheduled to reach the theater at 6:25, at which point the occupants will walk down a 100-foot-long red carpet to the private, invitation-only screening, which is scheduled for 7 p.m. A private party will follow at Landmark Center.

The movie, filmed primarily at the Fitzgerald (with a couple of additional scenes at Mickey's Diner), opens nationwide June 9.

JEFF STRICKLER

read more | digg story

Monday, May 01, 2006

A Prairie Home Companion

A Prairie Home Companion
Gala Movie Premiere Parade
May 3rd, 2006 6:00 pm

The Highland Park Senior High marching band will lead 10 horse-drawn carriages carrying the stars. (Garrison Keillor, Robert Altman, Kevin Kline, Lindsay Lohan, Virginia Madsen, John C Reilly, Meryl Streep and Lily Tomlin are expected to attend.)

The public is encouraged to line Wabasha Street between 5th Street and Exchange Street for best viewing and a chance to help welcome the stars back to St. Paul.

6:10 pm: Depart Rice Park

6:15–6:25 pm: Travel on Wabasha Street

6:25 pm: Arrive on Exchange Street in front of the Fitzgerald Theater for red carpet.


read more | digg story

HOW TO - Set Up Your Own Personal Wikipedia

Gina writes: "The software that runs Wikipedia, called MediaWiki, is freely available for anyone to install. Today we�ll set up MediaWiki on your Windows PC and get started with a video demonstration on how to add, edit and compare page revisions in your new, local personalpedia."

read more | digg story

T-Mobile's 20Mbps 3G service to replace home broadband

By Tony Glover Technology Editor
30 April 2006

GERMAN-owned mobile operator T-Mobile is planning to enter the broadband price war launched by Carphone Warehouse two weeks ago, The Business has learned.

T-Mobile intends to take on the UK operators by using its mobile network to offer internet access over a souped-up 3G system at speeds equivalent to fixed-line broadband. This will dispense with the need for a fixed line in the home.

Although mobile phone customers will pay £8.50 (E12.33, $15.22) for unlimited data use, T-Mobile believes it can still undercut UK operators as customers will not need to pay a fixed phone line rental, although they will still be able to retain the sort of phone number currently used for fixed line.

A T-mobile spokesman told The Business: “A key opportunity for mobile is to displace the fixed line phone. If you have a fixed line phone, you’re typically paying over £300 for line rental and broadband access, before you make a single call. Say, over £400 a year with relatively modest call volumes. Customers have a choice whether to continue paying this or to redeploy the money on to mobile. It has always to be their choice; but providing high-speed mobile broadband clearly removes one big reason for ‘having to have’ a fixed line.”

According to T-Mobile, more than 12% of UK households do not have a fixed line phone. So far the trend is mostly among the young, who have grown up with a mobile and see no reason to have one.

Earlier this year, T-Mobile, which is owned by European telecoms giant Deutsche Telekom launched its T-Mobile@home service enabling contract customers to have a fixed line number that can be reached via a mobile phone while in their home. T-Mobile has plans to launch a similar service in the UK together with a high-speed broadband connection. UK customers will be able to have an extra number which has the same suffix as a fixed-line number on a designated mobile that will be able to transfer calls to mobile phones owned by other household members.

UK fixed line operators such as BT believed they had cornered the broadband internet market when they developed DSL software to turn copper telephone wires into broadband pipes. But T-Mobile believes a new technology, high-speed downlink packet access (HSDPA), a souped-up version of 3G, will enable it to leapfrog the fixed-line operators. HSDPA can be used with a wireless box to allow PCs to access the internet.

read more | digg story

Tuesday, April 18, 2006

Add thumbnail pictures to Google searches

Add thumbnail pictures to Google searches

Use a free add-on for Google that shows miniature web pages alongside Google's summaries
Scott Colvey, Computeract!ve 18 Apr 2006

Google is great for searching the web – that's why nearly everybody uses it – but there's always room for improvement.

In this case it's a neat little add-on for Internet Explorer called Lost Goggles (users of the Firefox web browser need not apply). What it does is change the way Google searches are presented so that in addition to a list of all the pages found, you also see a thumbnail picture of each page.

Near each picture a tiny icon is displayed, and if you click on this the chosen page opens in a new window. Those who like to browse this way are saved the trouble of right-clicking and selecting the Open in New Window command, but for those who prefer to use one window at a time, Lost Goggles is worth installing for the thumbnails feature alone.

So, refer to the workshop in issue 215 of Computeractive and then transfer to the Lost Goggles download page.


read more | digg story

Friday, April 14, 2006

$25 Check + $20 Coupon, If you own a Qualifying Epson Printer

There is a class action lawsuit against Epson that was settled. If you purchased a qualifying Epson printer from April 8, 1999 to May 8, 2006 , you can register to receive a $45 ecoupon for Epson's estore. There is an alternative to receive a $25 check and $20 estore coupon but you must file the claim form.

http://www.epsonsettlement.com/

read more | digg story

Force windows to load the kernel in memory(Windows XP tweak)

This is a very small tutorial, that will help you make your windows XP much faster, by loading the windows kernel in memory. This is a very effective tweak for windows XP.


Here is what you have to do :

1) Open the regedit tool (Start -> Run -> regedit.exe )

2) Use the navigation in the left and go to HKEY LOCAL MACHINESYSTEMCurrentControlSetControlSession ManagerMemory Management

3) Double click the DisablePagingExecutive attribute, and put 1 in the decimal value field
This will make the drivers and the XP kernel run in memory.

4) Double click the LargeSystemCache attribute, and put 1 in the decimal value field
This will improve performance of the kernel

5) Double click the IOPageLockLimit attribute. On some later versions of windows XP that doesn't exists, so if this is the case you're done Otherwise you have to put to the hex value : 4000 for pcs with 128 mb ram, 10000 for 256 mb ram and if you have more put 40000. This value specifies how many bytes can be used for I/O operations in your system.

That's it, enjoy

read more | digg story

Hacking the Mac OSX Login Window

Not only does this hack let you change the text of the login screen, but gives you a step-by-step to change the general appearance.

read more | digg story

Saturday, April 01, 2006

Last.FM your iPod.

If you don't listen to music alot on your computer but have an iPod and would like to keep track... well, here you go.

read more | digg story

Last.FM your iPod.

If you don't listen to music alot on your computer but have an iPod and would like to keep track... well, here you go.

read more | digg story

Last.FM your iPod.

If you don't listen to music alot on your computer but have an iPod and would like to keep track... well, here you go.

read more | digg story

Monday, March 27, 2006

To download Mozilla Firefox




read more | digg story

Beatles taking Apple to court over theft of trademark

It is the ultimate battle of the generations.

This week the Apple Corps goes to the High Court seeking multimillion-pound damages against Apple Computer, the creators of the iPod, over their hugely successful iTunes Music Store.

In one corner Sir Paul McCartney and Ringo Starr, the ultimate stars of vinyl who defined music in the 1960s. In the other, the creators of a small white box that has revolutionised the way we buy and listen to music.

Apple Corps, owned by the former Beatles and their heirs, still owns the licensing rights to Beatles’ products. It is claiming that the introduction of iTunes broke a $26 million settlement under which Apple Computer agreed to steer clear of the music business, for which the Beatles’ company retains the famous trademark. It is the latest clash in one of Britain’s longest-running corporate legal battles.

Any damages for this latest clash could amount to tens of millions of pounds because it concerns Apple Computer’s hugely successful iTunes Music Store and iPod digital music players.

The court will be treated to a demonstation of an iPod, but it is unlikely to play a Beatles song, as they have not been licensed for download and it would therefore be illegal.

The Beatles first used a logo of a Granny Smith in 1968 when they founded the Apple Corps to distribute their records and those of other artists they signed to the Apple record label. The records had a ripe apple on one side and a neatly sliced half on the reverse.

The Apple Records subsidiary is still active as the licensing agent for Beatles products.

Steve Jobs, chief executive of Apple Computer, founded his company in 1976 with a logo of a rainbow-coloured apple with a bite taken out of it. Apple Corps sued him five years later, accepting an $80,000 settlement and a promise that the computer company would stay out of the music business.

The companies clashed again in 1989 after Apple Computer introduced a music-making program. The computer company settled in 1991, for $26 million. Apple Corps was awarded rights to the name on “creative works whose principal content is music” while Apple Computer was allowed “goods and services . . . used to reproduce, run, play or otherwise deliver such content”.

Critically, however, the agreement prevented Apple Computer from distributing content on physical media. This was designed to cover CDs and tapes, but it is unclear whether it included later inventions such as digital music files or devices used to play them.

Apple Computer will argue that its music service, which has sold more than a billion songs since 2002, is merely data transmission.

The case is scheduled to begin on Wednesday at the High Court before Mr Justice Mann, a self-professed fan of music and computers. He is no stranger to the iPod, having inquired of both sides some time ago if he should disqualify himself from hearing the case because he owned one.

The owners of Apple Corps — Sir Paul, Ringo Starr, Yoko Ono and Olivia Harrison — will not attend the hearing, but witnesses will include Neil Aspinall, the company’s managing director and the former Beatles road manager; and Eddy Cue, head of internet services at Apple Computer.


read more | digg story

Sunday, March 26, 2006

AJAX Site Design using Prototype 1

By now the entire World has heard about AJAX, even those who don’t care about Web-Development have seen the potential of this new technology. Everybody is tired of endless introductions on how cool AJAX is and those endless lists of good examples like Google Suggest, GMail and alike, so I decided to cut a long story short and jump right into the real tutorial.

Is this tutorial any different from the others? Well yes and no, it is different in being a tutorial on how to design and build a complete site and not just some fancy little details like how to turn caching in AJAX off or how to create a fancy widget. To keep the tutorial readable, and to avoid having to implement low level functionality, I’m using the dojo toolkit, I tried prototype too and really enjoyed working with being a really nice and easy to use Library, but dojo provides much more functionality bundled with it. For both frameworks one thing is true: documentation is scarse, and I spent alot time debugging and reading posts on the newsgroups.

For debugging I suggest using Firefox Venkman and the really nice Firebug extension, which make AJAX a lot easier to understand, especially FireBug’s "Log each Request" Feature.

In this tutorial we will try to design a community portal as it has a wide range of different components that give a good overview of what is archievable with AJAX, also it should provide you with the basic tools that will help you in more complex applications.

What we want

As developers we need to know where we want to go, before starting right away. The requirements analysis is not part of this tutorial so I’ll just write down the basic functionality for our Portal:
  • Pages: Load and show simple HTML Formatted content.
  • User: we want to be a community so the possibility for users to register themselfs, create a Profile and communicate with others is fundamental.
  • Messages: some sort of messaging center is nice too, and not too difficult to implement, it allows private communication between the users.
  • Forum: talking about communications, what could be better than a Forum to let the Users talk about whatever they want?
Many more things will be added later but for now this should be enough for some sleepless nights =D

The Layout

Although the focus should be on the development of the functionality, the layout is still as important as the application itself. It gets even more important because the application can be good but without an interface that is functional it is useless. We’ll use a layout that is easy yet functional:

  1. The content area.
  2. A sidebar for context related options.
  3. The main menu (basically this just selects between modules).
  4. The title, nothing fancy here
  5. A list with the online users.

Modules

Basically with AJAx we step away from the classic one page-at-a-time view of doing things, and we have to start talking about a more Event Driven architecture, or MVC-Model if you prefer.
We’ll define an API that abstracts from the actual page so that we can then create modules that do more complex tasks.

To get back to this tutorial we will have several small modules that represent parts on the site, along with real modules we will have some virtual modules that take care of some functionality, but more on this later. Modules in this tutorial include:

  • Page: this will be the first module we will be implementing, it allows to simply display the contents of a file in the contents area of the site, it does nothing fancy.
  • User: this module is used for several different tasks:
    • Register: register a new User
    • Login
    • Profile: show the profile of a User
  • Online: once we have users we can easily implement a component that allows us to show which users are online, and with AJAX this is possible almost in realtime. It is a nice effect and very easy to implement.
  • Forum: what would a community site be without a Forum?

The implementation

We will encapsulate all of our functionality in JavaScript variables, this is similar to static classes in Java and makes it possible to have some sort of clean namespace division between the modules. First of all we will have to create the engine. The engine is the part that handles loading of all the other modules and gives them abstract ways to interact with the page. The idea behind this is that the page interface (layout, stylesheet, …) and Engine build an abstraction layer so that it is easier to implement the functionality easier, without having to bother about representational issues. In other words we build an API.
The first and morst important thing the engine has to do is initialize everything.


var Engine = {
bootstrap: function(){
this.setStatus(“Loading…”);
dojo.require(“dojo.io.*”);
dojo.hostenv.writeIncludes();
if((“”+document.location).indexOf(‘#’) < 0){

Engine.loadPage(“#Page/Welcome”);
}else{
Engine.loadPage(“” + document.location);
}
},


This part is easy to understand it does nothing else than set the status to "Loading…", then include some dojo packages and then display a page using Engine.loadPage() as is shown later on. As you can see everything is bundled into a variable named "Engine" thus making it easy to reference it from outside. The bootstrap function is called by the following code in the page:

<body onload=“Engine.bootstrap()”></body>


The next thing to do is to give the Engine the ability to load modules, this is done by downloading a JavaScript file that contains the Module (again encapsulated in its own namespace) and then calling init() of the Module which will initialize the module:

  loadedModules: new Array(),
modules: new Array(),
 
loadModule: function(module){

if(Engine.loadedModules[module])
return;
dojo.io.bind({
url: “javascript/” + module + “.js”,
sync: true,
error: function(type, evaldObj){Engine.showError(“Error while loading module.”);},
load: function(type, data, evt){

eval(data);
Engine.modules[module].execute(uri);
}
});
},

For performance issues we don’t want to download the modules more than once, that’s why we use the two arrays in the first two lines: loadedModules[] is an array of booleans which to every modulename tells us if it was loaded or is yet to be loaded, the second array contains references to the Modules themselfs (being variables they can be referenced like this). loadModules() itself does nothing fancy, it just issues a Synchronous XMLHTTPRequest to download the Module’s source code. It’s synchronous because we don’t want anything to happen at this stage, a call to a function that is not yet loaded for example, this gives us a certain security. Notice that the code is evaluated using eval().
Now we move on to the real magic: loadPage(). It will get a URI as input and it will then load the correct module and pass control to the module, which will then take care of the rest:


  uri: &quot;/&quot;,
 
loadPage: function(url){
Engine.setStatus(“Loading…”);
if(!url)

url = “” + document.location;
var hashIndex = url.indexOf(‘#’);
if(hashIndex < 0 || hashIndex <= url.length-2)

return Engine.hideStatus;
uri = url.substring(hashIndex + 1);
var moduleLength;
if(uri.indexOf(‘/’) > 0)

moduleLength = uri.indexOf(‘/’);
else
moduleLength = uri.length;
var module = uri.substring(0,moduleLength);
uri = uri.substring(uri.indexOf(‘/’));
if(Engine.loadedModules[module] && ! dojo.lang.isUndefined(Engine.modules[module])){

Engine.modules[module].execute(uri);
}else{
Engine.loadModule(module);
}
},


The URI is there so other modules and function get work with it easily without having to parse it over again. As you can see loadPage() mainly interprets the URL. Determining the module to load is fairly easy being the first part of the Query string. Some may ask why we’re using URLs like "http://www.example.com/Page#This/is/a/long/string". This is because we don’t want to break the ability to bookmark the pages. AJAX itself does break the bookmarkability because everythin happens in a single page, whereas without AJAX every URL identified a single resource. We use the part behind the ‘#’ because the browser does not issue another request to the webserver, which would unload the entire AJAX application, yet we assign a resouce to a unique URL. bootstrap() also loads the requested page from the URL using loadPage(). Cutting a long story short: a user can browse through our site then copy&paste the URL somewhere and when he returns to the URL he will see exaclty the page he left.

The URL is interpreted in the following way:
  1. Everything in front of the ‘#’ is discarded as it is only the location of the application.
  2. The part between the ‘#’ and the first ‘/’ is the module name which will be loaded if it isn’t yet.
  3. Everything from the ‘/’ to the end of the URL is the argument that is passed to the Module’s execute() function (see the Page module below as an example).

All that is left now to do is implementing some helper functions that will later be used by the modules:

  setStatus: function(message){
if($(’status’) != null){
$(’status’).parentNode.removeChild($(’status’));
}

var body = document.getElementsByTagName(“body”)[0];
var div = document.createElement(“div”);
div.style.position = “absolute”;
div.style.top = “50%”;
div.style.left = “50%”;
div.style.width = “200px”;
div.style.margin = “-12px 0 0 -100px”;
div.style.border = “0px”;
div.style.padding = “20px”;
div.style.opacity = “0.85″;
div.style.backgroundColor = “#353555″;
div.style.border = “1px solid #CFCFFF”;
div.style.color = “#CFCFFF”;
div.style.fontSize = “25px”;
div.style.textAlign = “center”;
div.id = ’status’;
body.appendChild(div);
div.innerHTML = message;
},

 
hideStatus: function(){
Engine.opacityDown($(’status’));
},
 
opacityDown: function(theElement){

if(theElement == null)
return;
var opacity = parseFloat(theElement.style.opacity);
if (opacity < 0.08){

theElement.parentNode.removeChild(theElement);
}else{
opacity -= 0.07;
theElement.style.opacity = opacity;
setTimeout(function(){Engine.opacityDown(theElement);}, 50);
}

return true;
},
setContent: function(content){
$(‘content’).innerHTML = content;
},

 
showError: function(message){
Engine.setStatus(message);
setTimeout(“Engine.hideStatus()”,10000);
}
}


This completes the engine. You can find the full script here.

The first module

Now we’ll move on to implement our first real module. It’s task is to load an external resource (an HTML page in this specific case) asynchronously and then display it in the content area.

var Page = {
init: function(){

Engine.modules[“Page”] = Page;
Engine.loadedModules[“Page”] = true;
},
 
execute: function(uri){

try{
dojo.io.bind({
url: “resources” + uri + “.php”,
sync: false,
error: function(type, evaldObj){

Engine.showError(“Error while loading Content.”);},
load: function(type, data, evt){
Engine.setContent(data);
Engine.hideStatus();
});
}catch(e){

alert(e);
}
}
}
Page.init();
When the module is loaded it will register itself to the Engine (see the init() function) and the Engine will then call execute() which does nothing else than to load the page in the background and then display it in the content area. Easy isn’t it?
But you can already see that we can create really complex modules too as will be shown in a later part of this tutorial when we’ll create a Forum as a Module.
The source of the Page module can be found here.

Putting it all together

You can take a look at the running version of this application or download the entire source code and analyse it. I hope this tutorial was usefull and helped you understand how to design your application. See you all in the next part discussing an Online display.

read more | digg story

AJAX Site Design using Prototype

The internet is full of tutorials explaining those little tricks about AJAX, how to handle XHRequests and all that low level stuff, but nobody tells you how to design the entire application, nobody gives you the overview on how all these things should work together. What good is knowing all those fragments if the developer is unable to put them together to a real use? We have libraries to abstract from the Browser dependant things like actually doing XMLHTTPRequests, and we should concentrate on higher level design to give our clients (or visitors) good and usefull applications.

This is why in this tutorial I’ll try to give you an idea on how the actual design works. I’ll be heavily relying on my last tutorial for the layout of the final application, but we’ll go much more into detail about the decisions we take. Some parts may be applicable to non-Web-2.0 Web design and some even come in handy when designing completely non-web related applications
User Requirements

This step is as important as the coding itself, if I’d start right with the code without first clarifying where I want to go, I’d be wasting time! So there are three important questions that I have to answer:

1. What? What do I (or my boss) want the application to be, what functionality is a must, what is an optional, what are “nice to have” features?
2. Why? Does what I have found that I want to implement fit into the context or would it fit better if I’d change it a bit?
3. When? Do I have to implement everything right now, or may I add some new features one after another, possibly by releasing it before everything is implemented? But much more important: In what order will I have to implement the functionality?

There is not really a point that is more important than the others, take your time documenting and analysing the problems that you expect and fix some priorities, it will greatly speed up the implementation later.
What & Why

We plan to make a community site so the obvious things for a community is that it has to be attractive, easy to use and most important “feel alive”, nobody really wants to be part of a dead community where some casual visitor posts a new message to the forum every few days. To archieve the live feeling we use some little tricks like the regular updates of the list of users that are currently online. Remember that a community is not made up by two or three moderators posting some news from time to time, and filling the Forum with Junk messages nobody cares about.
When
It is important to understand that we’re not delivering a half finished product, it is fully functional, we plan to add more features in a second (and maybe third) step

1. Release
1. Main engine: the basic framework which will allow us to load and execute single modules at a later time.
2. Display some static content.
3. News System
4. User Registration and simple profiles.
2. Release
1. Advanced profiles
2. Private messaging
3. more to come…

This list is off course fairly superficial and does not cover the details of the implementation, it is an abstract planning step, that helps us get a general overview
Under the hood

As mentioned before we don’t want to reinvent the wheel for the millionth time again so we’ll use some libraries:

1. Prototype: probably the most flexible and intuitive AJAX Library on the internet, really lightweight and easy to use.
2. Behaviour: helps us to keep our pages downgradable for browser without JavaScript support (important also for indexing by search engine).
3. script.aculo.us: what would a Web-2.0 application be without nice effects?

This is what we’ll use for the client side. For the server side we’ll use PHP which is nice enough for our purpose, and is a reasonable tradeoff between control, speed and abstractness. For client-server communication we’ll use JSON which allows us to directly encapsulate the data into a JavaScript object, thus making the interpretation of the data much easier, in this tutorial we’ll use the JSON-PHP Library.

The Behaviour Library allows us to bind functionality right to the DOM-Elements without having to add onclick, onload, on[whatever] handlers right in the HTML, it allows us to define some CSS Classes, associate them with certain actions and then the library will take care of the rest for us, fully automagically.

Another main problem with AJAX pages are the “one-page-application” (applications that run entirely on one page) that have some problems with Bookmarking and the famous back button, I decided that the community page will be implemented as a one page application because it makes the whole process much easier, everything runs in one context and we don’t have to care aabout the rest. But we also want to make our pages bookmarkable so we use the hash ending of the URL to identify which page we are currently on.
Basic setup

Ok, so it’s time for us to gather all our libraries and put them into our Project Folder. Our project directory structure looks like this:

The Javascript folder will contain our three libraries (prototype, behaviour and script.aculo.us), the lib directory will contain all our PHP libraries (just the JSON-PHP for now) and static will contain our non dynamic content, such as some welcome textes and help pages.
Implementation

Now we’ll finally getting to see the actual code, it is important that we go one step after another, starting from the basic page layout and then building the functionality on top of that, it will keep us motivated throughout the process to implement a little thing and then test it to see if it works as we’d expected. The base Page is just a Page with the basic content, possibly a welcome message that tells where the user landed and what this is all about. We’ll use a pretty standard Layout for our application, the only requirement for AJAX is that we assign some ID’s to the main parts so that we can easily reference them later. Now we can insert links as we would normally have done, browsers without JavaScript will see a classic page that is completely served by our PHP-Scripts on the server side. For example the first thing we’ll do is display some static, non generated content, like the Welcome page normal links would look like this:

About

The PHP page would take the query string Page/About and would then serve the new page. Now we want to add the AJAX Magic, and this is magic indeed: we’ll use behaviour to catch the request before it is being sent and use AJAX methods from there on to download only the updated regions of the page. First we have to add a Class to all our internal links:

About

this allows us to distinguish the links we want to catch from the links to outside resources, for which AJAX is not applicable anyway.


var rules = {
‘a.link’ : function(el){
// We don’t want to have garbled links…
if(el.onclick)
return;
Engine.log(“Applying rule to “ + el.toString());
var target = el.href.substring(el.href.indexOf(‘?’) + 1);
el.href = “#”+target;
el.onclick = function(event){
var targ;
if (!event) var event = window.event;
if (event.target) targ = event.target;
else if (event.srcElement) targ = event.srcElement;
if (targ.nodeType == 3) // defeat Safari bug
targ = targ.parentNode;
Engine.log(“Clicked on internal Link “ + targ.toString());
Engine.loadPage(targ.href);
return false;
}
}
};
Behaviour.register(rules);

By doing this we have defined how the user interacts with the AJAX Engine, every element that fires up a certain event will have a class, and behaviour will then take care of the hooking up. Off course the loadPage example isn’t a really complex one but it’s the most common interaction on our page, and it shows the important parts.
See what’s going on

To test and see if all is going as we designed it we will have some way to get feedback from what we do on our Page. Using the alert() function is trivial, too trivial for us and it is really annoying too. Better would be some sort of textfield where our debugging messages are displayed without disturbing the site interaction (alert() opens a popup and focuses it…). We’ll use a popup that can be closed without interupting the application and it won’t try to get the focus for every message.

debug: true,
console: null,
log: function(message){
if(!Engine.debug)
return;
if(!Engine.console){
// Log window does not exist, try to open it.
consoleWnd = window.open(‘’,‘Debug Information’,‘width=350,height=250,menubar=0,toolbar=1,status=0,scrollbars=1,resizable=1′); consoleWnd.document.writeln(‘Console);
Engine.console = consoleWnd.document.body;
}
Engine.console.innerHTML += (message + "
n");
}


This makes it really easy to print debugging information on the running application: just use Engine.log(”Your message here…”); and Engine will take care of the rest. This is exactly what we need: the debugging information when needed but not always. This way of displaying debugging information is really simple, for more advanced features give Log4JS a try.
Modules design

Most AJAX applications in use right now load everything on startup, images, javascript and content. While this is surely an easy way to do things it’s not the best, because it takes a long time (sometimes too long) for the application to be ready, and much of the stuff that is loaded is never used, or used pretty late during execution. For exactly this reason we’ll divide the application into modules. Modules are independent parts of the application, like in our case these would be:

* Page: a simple module which will be implemented in this part of the tutorial. It will load an HTML file from the server and display it in the content area.
* Gallery: a gallery made of user pictures, the goal would also be to use Flickr as a backend for the pictures (e.g. take a group pool and display it, display pictures of a user, display pictures with a certain tag, …)
* News: simply an extension to the Page module this will allow administrators and moderators to post news. News are passed to the Javascript engine using XML. Its main purpose is to demonstrate how to use XML-Files.
* Messages: A module for sending and receiving private messages.
* Forum: the most complex module we’ll see during this tutorial.

First of all we’ll see how to load modules and register them into a module handler (the Engine) and then we’ll move on to actually design the modules.
Module handling

Basically the Engine does specify an API that the modules then may use to access the various parts of the Page, thus we create an abstraction layer between the actual interface and the application. Besides providing an easy to use interface to the Page, the Engine also takes care of loading and managing modules. First of all we’ll have know which modules have already been loaded and if they are not yet loaded we’ll have to load them upon request:


modules: array(),
registerModule: function(moduleName){

},
loadModule: function(moduleName, callback){

}

notice that we may provide a callback function so that will be executed as soon as the module is loaded. This is because we cannot use the following:


loadModule(“myModule”);
modules[“myModule”].execute();

because loadModule contains an asynchronous call which will immediately return. If we’re unlucky (and most likely we are) the second line is executed before the module has been downloaded and registered, thus generating some really nasty errors. The callback allows us to specify some actions that are to be executed when the module has been definitely loaded.

Modules can range from really easy ones, as the Page-Module is, to really complex things such as message boards, news system, live activity logs, to fully fledged Instant messaging application, there is absolutely no limit to the complexity. The only thing that we require is that the modules adhere to a certain format:


var moduleName = {
init: function(){
// Initialize the module
// Register the module Engine:
Engine.registerModule(moduleName);
},
// …
};
moduleName.init();

The last line is used to initialize the module. Since the module code will be eval()’d it must take care of registering itself to the module handler, the Engine.
The Page Module

The Page module is our first module. On execute it will get the static page via XHRequest from the Web server and display it in the content area. Being the simplest module it consists only of one function and one anonymous function, which will take care of loading the content into the content area. Don’t forget to re-apply the Bahaviours to the loaded code otherwise you might get some unexpected results.

So here it goes, without further ado the code of the Page-Module, by now you should be able to understand what it does.


var Page = {
init: function(){
Engine.log(“Page module loaded.”);
Engine.modules[‘Page’] = Page;
},
execute: function(url){
Engine.setStatus(“Loading content…”);
var myAjax = new Ajax.Request(“static” + url + “.html”,{
method: ‘get’,
// parameters: "?nocache=" + new Date(),
onFailure: function(){
Engine.showError(“Could not load content.”);
Engine.log(“Could not load page “ + url);
},
onSuccess: function(req){
Engine.log(“Loaded page “ + url);
Engine.setContent(req.responseText);
Engine.hideStatus();
}
});
}
};
Page.init();

The rest of the Engine

The engine still isn’t done by now, some functions from above are still missing but it is easy to guess what they do, we simply need some helper functions such as setContent, setStatus, showError and alike, so here goes the rest of the code:


setStatus: function(message){
if($(’status’) == null){
var body = document.getElementsByTagName(“body”)[0];
var div = document.createElement(“div”);
div.id = ’status’;
body.appendChild(div);
}
var node = $(’status’);
node.innerHTML = message;
new Effect.Appear(node);
},

hideStatus: function(){
new Effect.Fade($(’status’));
},

showError: function(message){
Engine.setStatus(message);
Engine.setTimeout(“Engine.hideStatus();”,15000);
},

setContent: function(content){
$(‘content’).innerHTML = content;
},

What’s next?

In the next part of this tutorial we will finally add some really new code that hasn’t yet been covered by my first tutorial, namely we will implement a signup form and some simple user management. For now take a look at the working copy of the application here, or download a snapshot of the code here.
Other resources

* Sergio Pereira’s really good introduction to Prototype
* My first AJAX tutorial
* Prototype Dissected: some really nice cheatsheets for prototype.js

Tools

* FireFox Venkman: the javascript debugger of FireFox (does not work with 1.5.0.1, but the guys over at GetAhead got a fix).
* FireBug Extension: FireBug is a new tool that aids with debugging Javascript, DHTML, and Ajax. It is like a combination of the Javascript Console, DOM Inspector, and a command line Javascript interpreter.
* Eclipse AJAX Toolkit Framework:AJAX Toolkit Framework (ATF) provides extensible tools for building IDEs for the many different AJAX (asynchronous JavaScript and XML) run-time environments (such as Dojo, Zimbra, etc.). This technology also contains features for developing, debugging, and testing AJAX applications. The framework provides enhanced JavaScript editing features such as edit-time syntax checking; an embedded Mozilla Web browser; an embedded DOM browser; and an embedded JavaScript debugger.




read more | digg story

Friday, March 24, 2006

How to create a torrent

How to create a torrent?

Posted in All, Clients, How to, Tutorial, Bitcomet, Azureus, µTorrent, Bittorrent on 03.23.06 15:23

Torrents are great, they are the best way to share large files with your friends, or even with people you don’t know at all. But surprisingly enough, not many people create torrents when they need to share something. I have “a lot of” friends who know how to download torrents, but when they need to send me their latest 200MB vacation picture collection, they ask me to “get on msn”.

It’s not that I have anything against msn (allthough the file transfer sucks), but why don’t just use bittorrent? Especially if you want to send something to more than one person because then you can share the bandwith.

So how do you do this? Well it’s very simple. Open your favorite bittorrent client and do the magic trick:

file > create torrent

…..

That’s all? Well almost. All you need to do now is put in the tracker info nad tick some boxes. This can differ somewhat from client to client but it all comes down to the same thing.

µTorrent

utorrent bit torrent

1. File > Create new Torrent (or CTRL + N)

2. Select the files and or directories

3. Trackers: This is probably the hard part for most people. But it’s pretty easy, just put in one of the popular public trackers. You can use one or more trackers, but in general one is enough.

Here are some of the most popular trackers at the moment:

http://tracker.prq.to/announce
http://inferno.demonoid.com:3389/announce
http://tracker.bt-chat.com/announce
http://tracker.zerotracker.com:2710/announce

Put one of these in the tracker box

4. Do NOT tick the private torrent box (unless you’re using a private tracker)

5. Save the torrent and send it to your friends

Bitcomet

bitcomet bit torrent

1. File > Create Torrent (or CTRL + M)

2. Select the files and or directories

3. Select “enable public DHT network” from the dropdown box
This way you can be your own tracker if the public tracker goes down.

4. Tracker server and DHT node list
Again, This is probably the hard part for most people. But it’s pretty easy, just put in one of the popular public trackers. You can use one or more trackers, but in general one is enough.

Here are some of the most popular trackers at the moment:

http://tracker.prq.to/announce
http://inferno.demonoid.com:3389/announce
http://tracker.bt-chat.com/announce
http://tracker.zerotracker.com:2710/announce

Put one of these in the tracker box

5. Save the torrent and send it to your friends

Azureus

azureus bit torrent

1. File > New Torrent (or CTRL + N)

2. Tick “use an external tracker”.
And again, This is probably the hard part for most people. But it’s pretty easy, just put in one of the popular public trackers.

Here are some of the most popular trackers at the moment:

http://tracker.prq.to/announce
http://inferno.demonoid.com:3389/announce
http://tracker.bt-chat.com/announce
http://tracker.zerotracker.com:2710/announce

Put one of these in the tracker box

3. Select single file or dicectory, click NEXT and point to the file or directory you want to share, and click NEXT

4. Do NOT tick “private torrent”

5. Do tick “allow decentralized tracking”

6. Save the torrent and send it to your friends.

read more | digg story