msgbartop
Useful MOSS 2007 and Ruby and Rails stuff
msgbarbottom

26 Jul 08 Wordpress for iPhone

It is now easy to blog on the go using the Wordpress app on the iPhone!

photo

Tags:

26 Jul 08 Deploying Rails

http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/

$ sudo gem install capistrano
$ capify .
$ cap deploy:setup
$ cap deploy:cold
$ cap deploy:migrations

Can’t remember where I got this from…

deploy.rb

set :runner, "username"
set :use_sudo, false

# =============================================================================
# CUSTOM OPTIONS
# =============================================================================
set :user, "username"
set :application, "application.com"
set :domain, "my.ip.address.here"
set :alias, %{ application.com }

role :web, domain
role :app, domain
role :db,  domain, :primary => true

# =============================================================================
# DATABASE OPTIONS
# =============================================================================
 set :rails_env,       "production"

# =============================================================================
# DEPLOY TO
# =============================================================================
set :deploy_to, "/home/#{user}/#{application}"

# =============================================================================
# REPOSITORY
# =============================================================================
set :scm, "git"
set :deploy_via, :remote_cache
set :repository, "/home/#{user}/reponame.git"

# =============================================================================
# SSH OPTIONS
# =============================================================================

default_run_options[:pty] = true
ssh_options[:paranoid] = false
ssh_options[:keys] = %w(/Users/username/.ssh/id_rsa)
ssh_options[:port] = 1600

http://www.softiesonrails.com/2008/6/5/the-absolute-moron-s-guide-to-capistrano-git-and-thin-edition

24 Jul 08 in place editing rails 2.1

http://www.buildingwebapps.com/learningrails/14

Tags:

23 Jul 08 Rails 2.1 Cross Site Forgery Protection

Getting this problem?

ActionController::InvalidAuthenticityToken (ActionController::InvalidAuthenticityToken):

Disable csfp
http://ryandaigle.com/articles/2007/9/24/what-s-new-in-edge-rails-better-cross-site-request-forging-prevention

18 Jul 08 Using Query String Variables to Populate SharePoint Form Fields

http://mdablog.spaces.live.com/blog/cns!B0C40902E1212960!623.entry

<script type="text/javascript">

_spBodyOnLoadFunctionNames.push("fillDefaultValues");

var vals = new Object();

var navBarHelpOverrideKey = "wssmain";

function fillDefaultValues() {
  var qs = location.search.substring(1, location.search.length);
  var args = qs.split("&");

  for (var i=0; i < args.length; i++) {
    var nameVal = args[i].split("=");
    var temp = unescape(nameVal[1]).split('+');
    nameVal[1] = temp.join(' ');
    vals[nameVal[0]] = nameVal[1];
  }
  setLookupFromFieldName("ProjectID", vals["ProjectID"]);
}

// setLookupFromFieldName: Set a form field value using its
//    fieldname to find it in the page
// Arguments:
//        fieldName:    The name of the list column
//        value:        Set the fieldName to this value
//
    function setLookupFromFieldName(fieldName, value) {
        if (value == undefined) return;
        var theInput = getTagFromIdentifierAndTitle("input","",fieldName);
        if(theInput != null) {
            theInput.value = value;
        }
    }

// getTagFromIdentifierAndTitle: Find a form field object using its tagName,
//     identifier, and title to find it in the page
// Arguments:
//        tagName:    The type of input field (input, select, etc.)
//        identifier:    The identifier for the instance of the fieldName
//                       (ff1, ff2, etc.)
//        title:        The title of the list column
//
    function getTagFromIdentifierAndTitle(tagName, identifier, title) {
        var len = identifier.length;
        var tags = document.getElementsByTagName(tagName);

        for (var i=0; i < tags.length; i++) {
            var tempString = tags[i].id;
            if (tags[i].title == title && (identifier == "" ||
                  tempString.indexOf(identifier) == tempString.length - len)) {
                return tags[i];
            }
        }
        return null;
    }

</script>

Tags:

17 Jul 08 Sharepoint Designer Screencasts

http://www.youtube.com/profile_videos?user=SharePointGuys

Tags:

16 Jul 08 More on Single Sign-On for MOSS

http://www.sharepointblogs.com/llowevad/archive/2007/06/25/sharepoint-2007-single-sign-on-setup.aspx

 

http://technet.microsoft.com/en-us/library/cc262932(TechNet.10).aspx

Tags: ,

16 Jul 08 Rails Ajax

http://api.rubyonrails.org/classes/ActionView/Helpers/PrototypeHelper.html#M000414

Tags: ,

15 Jul 08 Learn Ruby on Rails

http://www.sitepoint.com/article/learn-ruby-on-rails

Tags:

15 Jul 08 Ruby Quick Ref

http://www.zenspider.com/Languages/Ruby/QuickRef.html

 

Tags:

This blog is multi language by p.osting.it's Babel