Hi, this blog is no longer maintained, my new blog is here

Ruby On Rails and a Conning Israeli entrepreneur

Update: Social Network Ruby on Rails Applications


Update 28/1/09 : Added El-Dorado

Update 27/1/09 : Added OneBody
Update 12/2/09: Added EchoWaves, OpenMind and Forulio

One of my current consulting positions, involves a startup company with a great idea and a great social network implementation idea.
For that matter, i have been scavenging the web lately for Rails based social netowrking plugins, Engines or maybe even a skeleton application for those guys and i found some very good solution apps and infrastructures, the only problem rails Rails 2.0 compatibility (which i didn't check yet, and some don't indicate) and Documentation, which seem to be neglected on almost all those apps.

So, Here's the current list:

LovdByLess
include blogs, user profiles, photo uploads, forums, friendships and user-to-user messaging funcionallity.
Looks great and has a great look and feel.
Comes as a full application under MIT license.


CommunityEngine
A Rails engine, now supports Rails 2.0.
Gives you the basic functionality for a social networking site. It includes features such as User pages, forums, uploads, geo searches, blogging and more.
Important to say that extending the basic engine with your own controllers and models, is supposed to be easy and simple, i am currently testing it out so i don't really have an opinion yet.
Documentation has to be improved though, a lot.

TOG, presentation
TOG is basically a package of features (in the form of plugins) which you can choose to add to your applications as one, or as a whole.
Using these prepackaged and automated features should let you focus on the real key point about social networks: keep the conversation going with your members. If you’re just starting a social site or wants to polish your community with lovely social capabilities maybe you should give tog a try.

Insoshi
Features include:
  • Activity feed
  • Personal profiles with photo upload and comment walls
  • Internal messaging system with read/replied/trashed messages
  • Contacts list
  • Blogs with comments
  • Discussion forum
  • Search for profiles, forums, and blogs
  • Admin panel with site preferences
  • Option for email verification and activity notifications
Documentation is kind of missing here too.

LuvFoo
Under developement, but runs several sites at the moment,
include some neat features on top of the plain simple ones, such as API and CMS intergration.


OneBody
Although i am not sure why they indicate their audience as Churches (?), it looks like a good social framework with a lot of features such as:
  • Membership Management | aka ChMS
  • Online Directory | search, print
  • Groups | email lists, attendance tracking
  • Social Networking | friends, favorites
  • Content Management System | page editing
and more, read on in the Wiki manual


El-Dorado
Looks nice and packed, a pretty live demo site too.
Features include:
  • Forum
  • Group chat
  • Event calendar
  • File sharing
  • Random headers
  • Avatars
  • Themes
  • Privacy settings

EchoWaves

EchoWaves
This is a group chat social network application. You can start conversations and connect wih other users while discussing it.
It is possible to make a conversation read-only for presenting a content too.

Openmind

Openmind
Openmind enables you to create a collaborative environment for collecting the thoughts of your customers/collagues on a product/service.
User can discuss online about an idea & vote for the features. Admin can mark the most-requested features as "to be included in next releases" & users get informed from this. A nice application for creating a constructive community.

Forulio

Forulio: Ruby on Rails Forum
Forulio is a Ruby on Rails forum application with a similar approach to popular forum softwares like phpBB or vBulletin.
It supports sub-forums, has a monitoring page for viewing the activity and has tagging integrated.

Other resources:

Mockups: Easily create application mockups

One of the very first steps of every application, is to gather around your UI guidelines.
This Mockups tool, by Balsamiq, is one of the best tool that i had seen for this job.
It's an amazing tool, combining a beautiful interface of it's own, a vast library of UI elements and an overhaull feeling of "planning".


The only downside is of course the price, 79$ is more than Textmate's price tag... i can say that in a price of 50$, it's a must have.
Big thanks to Lior Levin for this tip.

FireFox blogging extention: ScribeFire

For a while iv'e been trying to find a better way to post my blog posts, other than simply go into the Blogger Dashboard.
Iv'e tried several Mac clients (MarsEdit, Ecto) and none of them succeeded in working with my blog (probably a template issue, not resolved yet).
A few days ago i came across this Blogging firefox extention called ScribeFire, which appears to be the ultimate solution.
ScribeFire supports multiple blog platforms, HTML editing and even an embedded ads service (didn't try it though).

Rails Conditional Eager Loading

Rails's eager loading (ScreenCast) is an important practice that saves some requests and queries when dealing with table relations in rails.
Up until now, using a condition hash to specify query was a little tricky if you use the eager loading method:
User.find(:all, :include => :jobs, :conditions => ["jobs.salary > ?",1000])

or using a hash (without eager loading)
User.find(:all, :conditions => {:name => 'eizesus'})

Using a conditions array/hash isn’t always my favorite way to write finds in Rails, but in certain cases must have when you deal with complex queries (like and "Advanced Search" feature).

In my current work,I needed to run conditions on an associated table in just such an "Advanced search" feature, so i came up with this simple and easy way to use a condition hash for eager loading methods:
User.find(:all, :include => :jobs, :conditions => {:name => 'eizesus', :jobs => {:position => 'Manager'})


or you can prepare the condition hash on the fly:
conditions = {}
conditions[:first_name] = params[:first_name] unless params[:first_name].blank?
conditions[:last_name] = params[:last_name] unless params[:last_name].blank?
conditions[:jobs] = {:position => params[:position]} unless params[:position].blank?

@users = User.find(:all, :conditions => conditions, :include => :jobs)

2 Useful CSS tips

"Don't look for water when something burns, just don't play with fire" - My Mom.

Preventing bugs before they happen, that's the key.
If you don’t prevent bug, they will start a snow ball that will force you on and on with ridiculous patch-work and what i basically call the "fire extinguishing loop", there will be a lot of them interacting with each other, making it difficult to figure out what’s what, and were it all began from.
The majority of bugs reside in JS differences between browsers and CSS and DOM interpretation, so i'll try to specify some methods and techniques we use here at my company, who make our lives a lot more easier.


CSS Resets

asterisk CSS selector:
* {margin: 0; padding: 0;}

But, it's too rough. Using this technique cause my forms to get messy and got me upset since i had to define every single padding and margin specification.
ince then, I’ve been using the popular CSS reset by Eric Meyer, which collects a set of such reset attributes, for several common HTML tags.
Of course i had to tweak it to fully match my needs, but still , it's a must-have baseline for cross browser CSS development.

Clearing floats

IE6 does not like floats too much, IE8RC1 is not a big fan either, especially when those floats are not clear.
Uncleared floats are often the cause of major bugs. however, it’s a bug that is easy to fix.
Setting an HR element with width of %1 and setting it to clear:both, will solve the problem.
<div id="container">
  <div class="floater">
    floating.
  </div>
  <div class="floater">
    floating.
  </div>
  <hr class="clear"/>
</div>
<span>I am below!!</span>


and the CSS:
#container{
}
.floater{float:left, width:60px; margin:6px; padding:6px; border:2px solid #888;}
hr.clear{clear:both;width:1%;}


ther clear:both definition orders the HR element to go down one line if the is any other element on it's left or on it's right, read more on the clear CSS attribute.

IE8 RC1: IE6 again?

IE6 was, and still is the worst nightmare for web developers (client side mostly).
This browser/disease who surfaced the Web years ago, still acts as a major market share holder (about 67% these days) and hurts users, developers and basically everyone who comes across it's path.
I am a web developer and there are many in my profession who can really understand this evil browser, much more than the common user who think the "internet is the blue icon...no?", we're still dealing with CSS Hacks, HTML and JavaScript that IE6 forced us to write, PNG manipulation (what did we ask for?! transparency?) and much more.
So the nearing release of IE8 should be good news, right? Everybody moves up a notch, even the poor people who have to use IE6 in the working place (yeah, there are more than a couple of these companies in Israel).

Not so fast. What made IE6 so bad is that it's bugs became standards. That people accepted it's negligence as a permanent status and began to work around it's bugs around the clock, forcing themselves and other to years of web-desperation.
On the other hand, these people web sites usually were their paychecks, so they really didn't have too much time to wait for dear old Microsoft to release a patch/fix/update that will fix their specific bug (and probably bringing 300 other bugs), so they hack CSS, HTML, JavaScript and Images in order to make it work. Before they knew it, the bugs and other demented issues from the IE standard demonic bugs, have become the standard.

After trying out IE8 RC1, i can say that i am worried, Tables that don't render correctly, JavaScript calls that crash the browser into oblivion and meta tags that order the browser to render the page as IE7, get real.
It's not just the bugs, it's the fact that the IE8 development seems to be giving these bugs the backend, it's been there, and have been reported already in Beta (i know i did).
If IE8 makes it out with this huge list of basic usage bugs, we are going on round 2 with IE6, And all of us web developers and designers will travel back in time to 2002.

IE6 for my opinion was the reason that almost nothing moved around web development and web applications between 2002/3 up until FireFox came along, when there was no competition, IE rules with it's bugs without nothing to worry about and with nobody has the ability to point out the exact things he wish to have in a browser, so Microsoft did nothing until FireFox became strong enough to threat the king.
Although that i would be happy to extinguisher the very existence of the IE family, i will be very happy to see a normal, advanced browser coming from Microsoft.

So, if you want to make sure that IE8 isn't a new IE6 in a new outfit, get yourself a copy of IE8 and start shooting some feedback at Microsoft. Also, vote up those bugs that really need fixing. Even if you don't use IE in your day-to-day work, if you develop web software, this is a matter of raising the bar, before they make a new one, very very low one.

Get Internet Explorer 8 and get to work.

CSS Frameworks Tutorials and getting started guides

First thing, it helps.
Exactly the same as in Server side languages and client side languages, frameworks are a great improvement (in most cases) to a regular off the board development.
There are a lot of CSS frameworks these days, Noupe guide to CSS framework gathers the best of the guides and tutorials for each of the major frameworks.
I personally tried to use several of them and i guess the 960 CSS framework proven to be the easiest to handle (for me, and i usually don't do CSS).

Ruby 1.9 is out

source Ruby Inside

Benchmarks say it's twice as fast as 1.8.7, but developers worn not to use it as a production ruby rght away becouse it may a lot of libraries and Gems.
so, be worned.

Amazon AWS: Calculate your monthly costs on Amazon S3, EC2 and SQS

"its' 0.3 cents per hour, this is 0.32 cents per request"
So how can we get the subtotal cost of an AWS Cloud application?
Simple, use the Amazon Cloud Services Cost Calculator.
note: i tried it with my own parameters, and it's showed a little above what i actually pay (5$ more).

Noupe: 15+ Incredibly Useful Mac Apps For Freelance Web Designers

Noupe: 15+ Incredibly Useful Mac Apps For Freelance Web Designers . <== This is a great blog, don't dare not to subscribe to their RSS Feed.

1. Espresso


Extremely powerful web development tool, created by the minds behind CSSEdit. Providing a powerful editing, sleek projects, live preview, real publishing and synchronization tools.
Espresso features an immensely powerful rule-based syntax engine, CoreSyntax, that transforms your text documents into semantic structure. Espresso has an extensible Navigator that’s best compared to the CSSEdit styles list.

2. CSSEdit


CSSEdit’s unique focus is on style sheets, it offers a wide range of features for any level of expertise. Starting out? Selector Builder, advanced visual editors, Live Preview, intelligent source environment and a powerful X-Ray web page inspector for an unbeatable CSS debugging suite.

3. Pixelmator


Pixelmator, the beautifully designed, easy-to-use, fast and powerful image editor for Mac OS X has everything you need to create, edit and enhance your images. Pixelmator is a layer-based image editor. You can quickly create layers from your photos, other pictures, from selections or even your iSight. Pixelmator can add a layer to your composition directly from your Mac’s little camera. With Pixelmator’s powerful, pixel-accurate collection of selection tools you can quickly and easily select any part of your images to edit and apply special effects to portions of your pictures.

4. Coda


Panic Coda is a great all-in-one Web development environment tool, keeping many of your commonly used tools in separate tabs. Tools include: text-editor, css editor, file transfer, svn, terminal & smart Spelling. All of the usual languages are supported and styled appropriately including: CSS, HTML, Javascript, Java, Perl, PHP, Python, Ruby, SQL, XML, and straight text.

5. Lineform


Lineform is an ideal Mac app for vector art, diagrams and illustrations. Lineform has all of the most popular tools, including everything from freeform gradients to compositing effects, enabling you to create the designs you want without getting in your way with superfluous “features” you don’t need.

6. Fontcase


Fontcase is a font management application that provides an elegant and powerful workflow to help you organise the fonts you have installed on your system. Designed to be an iTunes for your fonts, Fontcase has a powerful tagging system, which is designed to let you control your fonts like you control your music.

7. Deep- Image Search


Deep calculates the range of colors used in each of your images by analyzing the pixels and calculating the most popular colors. This is what makes the palettes in Deep powerful, you can find images that have similar colors, which is great when you are looking for the perfect picture to go on your web site. In fact, just drag any image on to Deep and it will find and rank all the images on your computer that are similar.

8. Cyberduck


Cyberduck is an open source FTP, SFTP, WebDAV, Mosso Cloud Files and Amazon S3 browser for the Mac. It features an easy to use interface with quickly accessible bookmarks.

9. Flow


Flow is another file transfer coming in style. Flow brings the best of the Mac to your server’s files and folders. Put simply, Flow makes working remotely every bit as intuitive and natural as working locally with the Finder. With Flow, you can edit files directly on your server, connect to (FTP, SFTP, Amazon S3, WebDAV, and MobileMe iDisk servers), Quickly Upload Without UI and many other features.

10. Sequel Pro


Sequel Pro is a Mac OS X MySQL Database Management app. Sequel Pro gives you direct access to your MySQL databases on local and remote servers with support for importing and exporting data from popular files including SQL, CSV and XML.

11. Things


Task management has never been this easy. Organize your to-dos with Projects and Areas of Responsibility. Features include: A smart Today list automatically gathers all you need to look at, Repeating To Dos, Every list can easily be filtered and sorted by due date, iPhone Sync and many other features.

12. xscope


xScope is a powerful set of tools that are ideal for measuring, aligning and inspecting on-screen graphics and layouts. Quickly available via the Mac OS X menu bar, xScope’s flexible tools float above desktop windows and UI elements making measuring a breeze.

13. KeyCue


KeyCue gives you an instant overview of the overall functionality of any application, plus lets you automatically start working more efficiently by making use of menu shortcuts.

14. TextExpander


TextExpander saves you countless keystrokes with customized abbreviations for your frequently-used text strings, code snippets and images.

15. OnTheJob


On The Job has a lot of power under the hood but maintains it’s reputation as the easiest to use time and expense tracking solution available for Mac OS X. On The Job offers flexible invoice creation. Create invoices for specific date ranges, covering a single job, or spanning multiple jobs.

Other Mac Apps you will find interesting

- TextMate
- Billings
- Littlesnapper
- MAMP
- Inkscape
- Picturesque
- Layers

UML for Rails applications

UML is a Graphical language for visualizing, specifying and constructing the artifacts of a software-intensive system. The Unified Modeling Language offers a standard way to write a system's blueprints, including conceptual components such as business processes and system functions as well as concrete things such as programming language statements, database schemas, and reusable software components.[1] UML combines the best practice from data modeling concepts such as entity relationship diagrams, business modeling (work flow), object modeling and component modeling. It can be used with all processes, throughout the software development life cycle, and across different implementation technologies.
As the strategic value of software increases for many companies, the industry looks for techniques to automate the production of software and to improve quality and reduce cost and time-to-market.
These techniques include component technology, visual programming, patterns and frameworks. Businesses also seek techniques to manage the complexity of systems as they increase in scope and scale. In particular, they recognize the need to solve recurring architectural problems, such as physical distribution, concurrency, replication, security, load balancing and fault tolerance. Additionally, the development for the World Wide Web, while making some things simpler, has exacerbated these architectural problems. The Unified Modeling Language (UML) was designed to respond to these needs and to supply the programmers and the project managers with a visual application state and layout.
There isn't a clear why to implement the usage of UML for rails development, but here are the tools i did find.

  • RailsRoad is a RailRoad is a class diagrams generator for Ruby on Rails applications. It's a Ruby script that loads the application classes and analyzes its properties (attributes, methods) and relationships (inheritance, model associations like has_many, etc.) The output is a graph description in the DOT language, suitable to be handled with tools like Graphviz. Last tested on old rails versions!
  • A visual paradigm plugin for generating ruby (yap, not rails)
  • ruby-uml, couldn't find any documentations.
  • The generate_from_uml plugin does the oppsite and enerates rails models from a UML schema, i didn't see how advanced relations are handled though (:has_many :through for example)

Deploying Ruby on Rails on EC2 - Deploying Oracle

Well, generally i use Oracle for my large scale applications.
Some people might say that it's not too-competible with Rails, but using the oracle_enhanced_adapter didn't pop up any special issues (it even supports Oracle's bind variables technique).
The Oracle Cloud Deployment tutorials on Oracle's website contains explanations, PDFs, tutorials and demos on how and when to deploy Oracle DB in the cloud.
Extra guides include backup and recovery practices.

Web Base SQL schema design

This amazing online SQL design (ERD) tool called wwwsqldesigner, is a great solution for those of us who get too troubled by designing simple apps database layouts. (NOTE: you should always hire a professional DBA)


Checkout the Homepage on GoogleCode, and Live demo.

Deploying Ruby on Rails on EC2 - Update

Tom Mornini, the Founder and CTO of EngineYard, introduced me their latest announcement, Solo.
Solo is an inexpensive, web-based platform for on-demand management of your Ruby on Rails web application on Amazon’s cloud computing infrastructure. Manage your web application from development to deployment. You get Engine Yard’s Ruby on Rails deployment expertise wrapped in an easy-to-use interface.
Solo removes a lot of the hassles and provides a battle tested Rails stack and many tools required to create reliable and manageable deployment atop Amazon's wonderful AWS offerings.

Tom also mentions that using my Deploying on Ruby on Rails on EC2 guide is not recommended for production stages and that users on AWS should always keep in mind that in case of a crash or reboot of the environment will result in lost data (without proper countermeasures, like EngineYard offers)

So your setup scenario as i suggested, should be used for development only, and carefully even in that case and keep in mind the non-persistence state of EC2 instance disks.

Beautiful Javascript Date Pickers

Source: Woork! - Beautiful Javascript Date Pickers
Great list of Date Picker plugins and scripts, for several Javascript frameworks.


The Web Ask eizesus.com

Subscribe

    follow me on Twitter

    Twiters Around

    About Me

    My photo
    I am a web developer for more than 9 years, managed, cried, coded, designed and made money in this industry. now trying to do it again.

    Labels