Sunday, 31 August 2008

Adding a View Source Link to a Page

I'm creating some JQuery examples and I wanted to add a view source link to each HTML page. After a little Googling I found this article on how to do it. But this just loads the page into the current window. I think it would be better if it popped up into a new windows.


Here is the code I created to view the source in a new window.


   1:<a href="javascript:void(window.open('view-source:'+document.location,
2:'_blank'))">View Source</a>

Thursday, 28 August 2008

eee pc 1000 Pretty Cool


Well as you may have guessed from an earlier post, I splurged and got myself an eee PC 1000 last week. If you aren't familiar with the eee, its a line of ultra portable laptops from Asus. The machines generally weigh less than 3 pounds and can cost as little as $350. The more inexpensive models have a very small 7 inch screen, small keyboard, and limited disk storage.


The eee 1000 has a 10 inch screen with a 1024x600 resolution, a 40gig solid state hard drive (SSD), and a fairly good sized keyboard. In addition, the 1000 uses the new very power efficient Intel Atom processor. Although at $670, the 1000 isn't exactly cheap, it is a pretty good price considering what you get (the SSD being a prime example). And its really inexpensive if you compare it to the $1800 starting price of a Macbook Air.


First Impressions


Here are some of my first impressions after a week



  • The 1000 has a great screen, bright and colorful. Web surfing works well as most sites fit in the 1024 pixel width. You do end up running all your applications full screen, but the eee has a Windows like task switcher so that is not really an issue.

  • The built in speakers are amazingly good. You won't need a separate set of speakers with this laptop.

  • The Xandros Linux distro seems to be very stable and easy to use. Since its Debian based, its easy to install new applications. A much better experience than the one I had with the HP 2133 and its crappy SUSE distro.

  • Configuring the UI can be a little tough as discussed in my previous post. But just adding the Start menu solves most of those problems. I don't really plan to make many changes to the base setup.

  • Web surfing performance is quite good. I have tried the Wifi at a couple different places and sites load smoothly and quickly.


Overall I am quite impressed with this little machine. If you are interested in trying an ultra portable, but don't want to mortgage the house, give the eee pc 1000 a look.


Tuesday, 26 August 2008

iPhone Signal Complaints

I keep reading about the iPhone G3 and how it has a poor signal, etc... I have noted that the phone almost always shows only 1 or 2 bars of signal strength wherever I go. However, when I actually make calls, the actual signal is better.



I really wonder if there are real signal issues or this is merely a perceived problem because the phone doesn't show 5 bars all the time? My advice to Apple would be to just show more bars in there software and I bet that "fixes" the problem. :)

Android 0.9 SDK beta

Updated Android 0.9 SDK beta is available to download:
http://code.google.com/android/download.html

The Andoid 0.9 SDK beta includes:

  • Extensions, changes and improvements to the framework and library APIs
  • New developer tools
  • Enhancements to existing developer tools
  • Redesigns to the home screen, some applications and UI
  • Plus various other improvements throughout the system

To take advantage of these features, you need to install the new SDK and upgrade your existing Android applications. The sections below guide you through the process.

With updated Android Emulator

http://code.google.com/android/reference/emulator.html

The Android SDK includes a mobile device emulator -- a virtual mobile device that runs on your computer. The emulator lets you prototype, develop, and test Android applications without using a physical device.

The Android emulator mimics all of the typical hardware and software features of a typical mobile device, except that it can not receive or place actual phone calls. It provides a variety of navigation and control keys, which you can "press" using your mouse or keyboard to generate events for your application. It also provides a screen in which your application is displayed, together with any other Android applications running.

To help you model and test your application, the emulator lets your application use the services of the Android platform to invoke other applications, access the network, play audio and video, store and retrieve data, notify the user, and render graphical transitions and themes.

The emulator also includes a variety of debug capabilities, such as a console from which you can log kernel output, simulate application interrupts (such as arriving SMS messages or phone calls), and simulate latency effects and dropouts on the data channel.


Monday, 25 August 2008

Rockwell Turbo Incabulator Transmission

I think General Motors installed this in my 1999 Chevy Silverado Z71. It would explain the amber 'Check 4x4" light on my display panel.

Painless Acer Aspire One upgrade for wpa2-enterprise

I recently purchased an Acer Aspire One netbook running the Linpus (fedora) OS. Long story short I love it! At 1Kg it's the envy of my fellow geeks!

However I could not use it to connect to our corporate wireless network because the Linpus OS and Network Manager installed does not support WPA2-Enterprise. So starting with this conversation on the Acer Aspire One Forum here's what I did to upgrade the Network Manager:

NOTE: It would appear that the prior instructions, as of 2008-10-09, are no longer valid. Therefore a shell script and archive that contains all that I needed to update the default Network Manager to one that supports WPA2-Enterprise are stored on my google site page.

Reboot the Acer Asprie One after installing the new Network Manger and enjoy WPA2-Enterprise.

For more information about this and all things Aspire One checkout the very informative Acer Aspire One Forum.

Featured gadget: U.S. Senator Search and Contact



Name: U.S. Senator Search and Contact
Author: Rosie Ojo
Description: Search for U.S. senator information

More information | Download gadget

Each week this blog features a recently added Google Desktop gadget that looks promising. If you'd like to see all new Desktop gadgets as they're published, subscribe to the RSS feed.

Add an eee pc start menu


For geeks, the eee pc leaves off a couple vital utilities from its user interface. Namely a terminal and a text editor. Now you can get to a terminal by typing Cntl-Alt-t or by launching one from the eee File manager. But the built in terminal uses a very small font and does not seem to be configurable. The file manager uses KDE's konsole, which works great, but I need a quicker way to get to it.


After searching around I bit, I discovered you can add a start menu to the eee's user interface. This seems to be the easiest and most unobtrusive way to add some simple customization to the eee. The steps are described on the LinuxOSS blog. Basically they are



  1. Open a terminal by pressing Ctrl+Alt+T

  2. Type �sudo bash� to get root access

  3. Create a hidden folder by typing: mkdir /home/user/.icewm

  4. Copy a config file by typing: cp /etc/X11/icewm/preferences /home/user/.icewm/

  5. Copy a sample menu so you have something to start with: cp /etc/X11/icewm/menu /home/user/.icewm/

  6. Type: vi /home/user/.icewm/preferences to edit the file. If you don't know how to use vi, you should learn to. :)

  7. Scroll down until you find �TaskBarShowStartMenu,� and change the 0 to 1

  8. Next time you reboot or restart your X server by hitting Ctrl+Alt+Backspace you will have a shiny new start menu.


Now you can edit the /home/user/.icewm/menu file and customize the menu. The basic structure for each menu item is: prog �title� icon_name program_path. So to add the Konquerer text editor, I would add a line: prog �Text Editor� kwrite /usr/bin/kwrite. Voila! I know have a link to the kwrite editor on the start menu.


Icon Location


The first question I had after add a few test entries was, where do you get the icons for your applications? It must be getting a kwrite icon from somemplace? By default, the eee looks for icons in the /usr/share/pixmaps directory. If you navigate there you will see a number of icons. You can reuse these for most of your applications. In addition, more icons can be found at /opt/xandros/share/AsusLauncher, but you will need to put in the full path icons in this directory.

Thursday, 21 August 2008

Smultron Text Editor for OS X

What is Smultron you ask? A long forgotten transformer perhaps? No its actually a free open source programmer's text editor for OS X 10.5, Leopard. Although, there are a number of free open source Java IDEs and editors that work well on the Mac, it has always lacked a good free editor that was OS X native.


A friend at work tipped me off the to program. I haven't used it much yet, but from what I have seen, it is very nice. Check it out at:


http://smultron.sourceforge.net/



Tuesday, 19 August 2008

iPhone Review

A quick review of my iPhone g3 is in order, especially after all the negative press I have been reading. Complaints include poor battery life, bad reception, and the installation of apps from the app store bricking the phone. So far my experience has been this.


Speed


The new iPhone is faster than its predecessor. It renders web pages much faster. The g3 network has been only slightly faster than the edge network (a bit disappointing). From what I have read, the design of the 3g network simply does not scale well. But if you are running off Wifi you will notice a big improvement in performance.


Signal


For whatever reason, the iPhone g3 almost always shows 1 bar of signal strength, pretty much wherever you are. The actual signal is much improved. I talk to my parents once a week on my phone long distance. They have raved about the improved sound quality. In addition, we seem to have less trouble with dropped calls. So the signal quality is much better, even though it appears to be worse.


Battery Life


The stand by battery life is much better. You can leave your phone on for a couple of days and the battery hardly goes down. With the old iPhone, I had to keep it turned off as much as possible. Just leaving the phone on over night would run down the battery quite a bit.


The run time battery life seems to be worse. It looks like to me the phone will only last about 3 hrs if kept on constantly. That is not good for someone who uses their phone all the time. I think the screen, which seems much brighter, may be sucking up all the juice. But, I'm just guessing.


Apps


I have only installed a Disney Card game app and that is it so far. No problems. Leo Laporte suspects the bricking problems are caused by downloading applications directly to your iPhone. If you download to iTunes and then sync, there are no issues. I haven't found any apps that really interest me much. Thought about getting the AIM client, but it had bad reviews and Meebo seems like a better choice anyway.


Summary


In summary, my experience has been good. I don't talk on the phone all day so the run time is not a problem for me. A faster phone, better signal, no special headphone jack, and more capacity (16gig) all make for an improved phone.


Apple has to solve the battery life issues. People who use their cell phones a lot are not gonna be happy.



Monday, 18 August 2008

Featured gadget: Cat Clock



Name: Cat Clock
Author: nectar1964
Description: Analog clock of cat design

More information | Download gadget

Each week this blog features a recently added Google Desktop gadget that looks promising. If you'd like to see all new Desktop gadgets as they're published, subscribe to the RSS feed.

Thursday, 14 August 2008

Getting an Approximate File Count

A quick Unix tip I thought I should share. If you need to get an approximation of how many files are in a directory and its subdirectories, the du command is a great help. By default, to use the du command you would type something like this:


du .


This command lists all the subdirectories of the current directory and their size in 512 byte blocks.


The following is a more useful version of the command.


du -ak .


That command lists all the subdirectories and files in the current directory and lists their size in kilobytes. This command can be very useful when used with grep to do quick searches.


Finally, if I want to get a line count, I add the following:


du -ak . | wc -l


The wc -l command counts the number of lines in the output of the du command. Since there is one line per directory and file its not an exact file count, but it can be real useful for quick comparisons and the like.



Wednesday, 13 August 2008

Google Gadgets for Linux 0.10.1



To celebrate the opening of the Beijing 2008 Olympic Games, we've just released Google Gadgets for Linux 0.10.1. This version contains two new built-in gadgets:
  • Photos - Displays your favorite photos (from either the Web or a local directory) as a slideshow. This gadget is very simple to use. Just get it from the Add gadgets dialog, and add your favorite sources in the Options dialog.

  • Gadget Designer - Similar to the Gadget Designer application for Windows, except that this designer is itself a gadget. Currently it only supports editing existing gadgets. Please get it from the Add gadgets dialog, try it out, and give us feedback. (Sorry, this gadget isn't available yet for Windows.)


Besides adding these two new gadgets, we've fixed many serious bugs. Many popular gadgets are supported now, such as the Google Calendar gadget. This new version also supports the Google Summer Games gadget, which displays a live medal count and event schedules on your desktop.


Tuesday, 12 August 2008

Acer Aspire One - Intel Atom N270 - system information

I recently purchased an Acer Aspire One netbook. The system information is shown below.

The operating system is:

Linux version 2.6.23.9lw (gcc version 4.1.2 20070925 (Red Hat 4.1.2-33)) #105 SMP PREEMPT Fri Jun 27 18:56:59 EDT 2008
























Here are some of the statistics according to dmesg. It leads me to believe that there are two Intel Atom N270 CPUs inside the netbook.











However according to Intel:
Hyper-Threading Technology3 (two threads) provides high performance-per-watt efficiency in an in-order pipeline and increased system responsiveness in multi-tasking environments. One execution core is seen as two logical processors, and parallel threads are executed on a single core with shared resources.
The full dmesg out put is here.

Monday, 11 August 2008

Faster Web Pages

I found this story on Giga OM that points to this story on making web sites faster. A tool for FireBug called YSlow is covered in the story. Looks interesting, it is not something I have used, but I intend to give it a try.



VNC Built Into OS X 10.5 Leopard

I ran across this when searching for a VNC client for the Mac. It turns out OS X has one built in. To use it do the following:



  1. Give Finder the focus

  2. Type AppleKey-K. This opens up the Connect to Server dialog

  3. Type in a VNC URL. For example, vnc://hostname.domain.com. Or if using a display number other than the default, 5900 + the display number. For example, the URL for display 16 would be: vnc://hostname.domain.com:5916

  4. Assuming a VNC server is there, you connect the server and VNC starts. Right click the Screen Sharing icon that appears in the doc and select Save to Doc. That makes the icon available to you for future sessions and you no longer have to mess with Finder.


Enjoy your new VNC client for OS X.

Friday, 8 August 2008

2008 Summer Games gadget



With 302 events, 35 disciplines, and over two hundred teams, the Summer Games can be overwhelming. The 2008 Summer Games gadget can help you follow all the excitement.

gadget screenshot #1

This gadget is a triathlete of sorts: It displays medal counts, event schedules, and the latest news. Try it out, and be sure to choose your favorite team from the options.

gadget screenshot #2

The gadget has been localized for the host country China and works fine with the latest Google Gadgets for Linux.

Also check out these related efforts across Google:
Happy Summer Games from the Google Desktop team!

More information | Download gadget

Thursday, 7 August 2008

Internet Explorer innerHTML Gotchas

Someone commented on my innerHTML post earlier in the week suggesting I should mention the IE gotchas. (I approved the comment but somehow it has disappeared. Weird.) Anyhow, I was working a little on the Web 2.0 course so I decided to look up the details. I found the answer here:


http://ajaxian.com/archives/innerhtml-gotchas


Turns out a few HTML elements in IE are read only. So if you try to write to them, but things happen. Details in the link.



Tuesday, 5 August 2008

Speaking of Search, Yahoo is trying something new

I ran across this story on webware.com on Yahoo making their search results more open. The gist of the story is this, if you add some code to your web site, developers can provide richer information in the search results. Yahoo calls this technology SearchMonkey and they are previewing it with results from LinkedIn and Yelp.


As mentioned in the article, scaling could be an issue. You definitely could not just turn on extra information for all sites. But it is still an interesting idea.



Is Cuil Cool?

I was gonna blog about Cuil last week, but when it debuted last Monday, it didn't seem to work so good. It seems to be fixed now though. :)


Cuil is a new search engine created by some of the former higher ups at Google. Apparently frustrated by the Google UI and search methods for the back end, they left to create a new search engine.


What they have come up with doesn't seem to be a lot different. The search summaries are a lot more scrunched up. Looks pretty much the same. No ads yet. It will be interesting to see how much traction they get. Can anyone take on Google? We shall see.


The company name comes from the Irish name McCool or McCuil. Taken from the Irish folklore character Finn McCuil.



Monday, 4 August 2008

Featured gadget: Call Via Skype v.0.2



Name: Call Via Skype v.0.2.1
Author: De-L-Orient
Description: Allows you to call via Skype to a Skype user or a phone

More information | Download gadget

Each week this blog features a recently added Google Desktop gadget that looks promising. If you'd like to see all new Desktop gadgets as they're published, subscribe to the RSS feed.

Friday, 1 August 2008

Sun Ajax Development Best Practices

I ran across this link to Sun blueprints today while doing a little background research on a course. Written by Greg Murray, formerly of Sun and now with Aptana, it is a nice little summary of good Ajax programming practice. Well worth saving a link to.



DOM v innerHTML Performance

Ran across this page (http://www.quirksmode.org/dom/innerhtml.html) today by PPK on quirksmode while verifying some course content. I'm sure there are lots of links to this article as it comes up near the top of the Google list, but I wanted to save a reference for myself.


To summarize, innerHTML is way, way, way, way, faster than DOM. :)

Wildflowers 2008

I was playing around with Flickr late last night and uploaded a few Wildflower photos from my Spring Chautauqua hikes. The Bluebells start blooming in late April and are usually gone by June. They seem to change from blue to purple as they pass through the season and are quite spectacular when they are kind of bluey/purply. Anyhow, one blue phase photo and three purple phase turned out. Missed the mid phase this year.


http://www.flickr.com/photos/23323057@N05/sets/72157606483474174/