Archive for the ‘Programming’ Category
Google App Inventor Blocks Editor not working on Ubuntu 10.04?
I was having issues with loading the Blocks Editor when using the Google App Inventor then I saw this:
Tips: If you are using GNU/Linux, then you should use Sun Java rather than OpenJDK. App Inventor does not work well with OpenJDK.
Ubuntu by default loads the Blocks Editor with OpenJDK, so the solution is to install Sun Java instead. I installed it with the Synaptic Package Manager. Then the next time you open up the Blocks Editor, don’t use the OpenJDK. Instead select other and locale this file: /usr/lib/jvm/java-6-sun/jre/bin/javaws and you should be good. You can use this from now on.
RoR Newb Note: Gems are installed per RubyGems version
So while working on ShoutReel, I had to upgrade to a newer version of RubyGems in order to use the i18n version of the geokit gem. When I upgraded, it said I was missing all the gems for the app. Consulting with my friend who told me that when upgrading RubyGems, you also have to re-install all the gems for the app.
This is just a newb note for myself as well as anyone on the Internet having this issue.
Diving into Ubuntu (again)
A while ago, I attempted to start using Ubuntu, but failed to install it on an old gateway laptop that didn’t have any linux drivers for audio, visual and wifi devices. Or at least I couldn’t find any online for the laptop. Due to the failure in getting it to work, I stopped my Ubuntu journey. I wasn’t ready for it. Skip forward a year later and I found myself installing Ubuntu 10.04 on my newer HP laptop. Installation was a breeze and everything worked out of the box except for some issues with double fingers on the touchpad and the right/left click ares on it. I was impressed. Wifi, bluetooth, sound, video, and pretty much everything worked instantly with Ubuntu.
As soon as I started to use it for a few hours, I noticed they took a some of their UI from Apple’s OS X and Windows. It’s the best from both OSs combined into one. Workspaces is cool. I’ve never experienced that working on Windows. I find that very useful when multitasking. I also like the way alt-tab works when switching from one item to another.
The best part of it all is developing with Ubuntu, which is the main reason I switched. I was having a hard time dealing with Windows and developing with Ruby on Rails. On Ubuntu it was extremely fast for obvious reasons. I haven’t tried developing in PHP or Java yet, but will soon.
How to add a class to the form_for tag in Ruby on Rails
I’ve searched for a while and couldn’t figure this out until I actually picked up my book and browsed the source of examples. I’ll get straight to the code:
<% form_for :user, :url => users_path,:html => { :class => ’standard-form’ } do |f| -%>
That produces:
300+ Free Programming Books
Excellent resource.