Posts from MyOwnDB Blog...

A new home!

Today we migrated the myowndb application to new hardware. This change brings multiple benefits. One of them is that the server hosting the app until now was getting old. MyOwnDB was started more than 2 years ago now, and has been running on the same server since the launch. Although it’s a good indication that you [...]
Tags: news

Freedom in the cloud

Richard Stallman, the founder of the Free Software Foundation, launched a call for action concerning freedom and privacy in the cloud. "This is a post about freedom. The freedom to keep your data for yourself and the freedom to run free software. You should be able to reclaim and enjoy these freedoms also when using web [...]
Tags: news, code, agpl, freedom, open_source

Slow Awakening

Hi all! Yes! MyOwnDB is not dead. It doesn’t even smell funny. While it has been quiet here for some time, in the background a lot of work has been done by an expanded development team. Two important milestones will be reached soon Dedomenon, the core of MyOwnDB, gets a complete REST API making it the easiest [...]
Tags: news

YUI-ext grid and context menus

I recently had the opportunity to use YUI-Ext for a little application. I’ll focus on the creation of the context menus for the grid. If you’re discovering YUI-Ext’s layout approach, more information is available from Jack Slockum’s blog in Exploring Cross-browser Web 2.0 Layouts with Yahoo! UI and Cross-browser Web 2.0 Layouts (Part 2) [...]
Tags: javascript, yui-ext

Accessing temlpate variables in tests

In your tests, you can easily access variables defined in your templates as: @response.template_objects["key"] and here’s a concrete example: assert(@response.template_objects["user"].errors.invalid?(”password”)
Tags: rails

Upgrade to Rails 1.2 notes

As I was looking to upgrade applications to rails 1.2, I wrote down all changes I had to do, and post those here in the hope it can be useful to anyone. I have skipped rails 1.1 for some apps and upgraded from rails 1.0, so some (all?) of the points could be from differences [...]
Tags: rails

Understanding javascript’s prototype member

After looking Douglas Crockford’s talks about javascript, I started experimenting to really understand javascript’s prototype. If you have downloaded the presentation’s slides, this is an illustration of slide 27. I’ve worked with the javascript interpreter included in the JDK6, based on Rhino. If you do this, just run $JAVA_HOME/bin/jrunscript and you get a prompt of [...]
Tags: javascript

Enhance your javascript knowledge online!

Until now I’ve been using javascript as a simple language to get Ajax features, but as I used it I discovered interesting features and got really interested to know more. As the JDK 6 has rhino included, you can also use javascript and get access too all Java libraries, which makes javascript knowledge even more [...]
Tags: javascript

Javascript closures illustration

Jack Slocum mentioned in a comment the problem comes from the creation of a global variable. When you create a local variable, you don’t get the problematic behaviour. Thanks Jack for taking the time to correct me. Intro Here is the illustration of a bug that was present in version 0.1 of the yui slideshow. If you [...]
Tags: code, javascript

YUI based slideshow

As I wanted to add a slideshow on the MyOwnDB homepage, I started looking for a ready made solution, but as I didn’t find exactly what I wanted, but also because I was curious of how it could be done, I started coding one based on YUI. I wanted a slideshow that enabled me to: load [...]
Tags: code, ajax, javascript

Remember to reset the YUI listeners on updated content

I had event listeners set on elements added dynamically to the page not working: my original content Click here to replace content YAHOO.namespace("raphinou"); YAHOO.raphinou.new_content = 'Click here to display original content‘; YAHOO.util.Event.addListener(”test_link”,’click’,change_content); YAHOO.util.Event.addListener(”undo_link”,’click’,reverse_content); When you click on the test_link, the content of [...]
Tags: ajax, code, javascript

Web 2.0 traffic watch list

MyOwnDB is progressing in Seth Godin’s Web 2.0 Traffic Watch List to 595th position. Although this is not a remarkable result, and the list has to be regarded with usual caution, it’s good to see MyOwnDB progress.
Tags: misc

Mass mailing with active mailer

So, you have plenty of users, and you want to notify them of a significant update. You have all recipient emails in you database, and the corresponding ActiveRecord models. Rails also provides the nice ActiveMailer tool. Writing a script using all your existing infrastructure seems the best solution, and it’s also how I wanted to [...]
Tags: rails, code

Some tricks to use S3 in your web application

After the post on my dojo.io.bind experience, here’s what I learned in using S3. I’m using the S3 library for Ruby published by Amazon. Uploads When you save an entry with a file attached in MyOwnDB, the Rails action handling the form checks the size of the file. If it is within the limits allowed for the [...]
Tags: rails, code, webservices

Famfamfam Silk icons used

I’ve deployed new icons in the application. These are Famfamfam Silk icons, a collection if 1000(!!) free (under the Creative Commons license) icons of really high quality, with very broad coverage. If you’re looking for icons in your web application, you know where to go from now on. Note that the Silk icons are not [...]
Tags: uncategorized, news

File uploads to Amazon S3 the AJAX way thanks to Dojo

File uploads are finally deployed! You can now specify in MyOwnDB that a detail of your entity is of the type “file”. This will let you attach a file to an entry, and subsequently replace or delete it. This required some changes in the application, more specifically in the way the forms are submitted back [...]
Tags: rails, code, ajax, javascript

Use of Yahoo UI’s tooltip and overlay

Monday has seen a big update of the signup code, with, amongst other changes, the use of the Yahoo UI libs. Although prototype is well integrated with rails, Yahoo’s extensive documentation and the praise it got from some leading javascript developers got me interested, and I must say I wasn’t disappointed. When you download the distribution [...]
Tags: code, javascript

Sending HEAD requests using Amazon’s S3 Ruby lib

After some usage of Amazon’s S3 storage service from Ruby, I’m quite happy with the result obtained. Amazon’s S3 Ruby library makes it quite easy to start playing with S3 from Ruby. I’m posting this essentially to share a minimal addition ( adapted S3.rb version, or patch for S3.rb available on 2006-05-21) to this (REST) library: [...]
Tags: rails, code

Testing Rails controllers communicating with external web services

As I was writing the code to accept payments through Paypal for MyOwnDB, I kept wondering how I could write functional tests to validate it. All those methods initiate or react to communications with Paypal, and although there’s a sandbox available, you cannot predict the id assigned to the transactions and that must be returned [...]
Tags: rails, code

Google sitemap for Ruby on Rails website

I was building a Google site map for http://www.myowndb.com using their generator (in python). Using the generator is very easy: just edit the config file according to the comments included the example. You can configure the generator to analyze access logs of your webserver to extract URLs to put in the sitemap. You can also [...]
Tags: rails, code
next page »