Title / Description
Code def create @cookbook = Cookbook.new(params[:cookbook]) @cookbook.code_html = CodeRay.scan(@cookbook.code.gsub(/^\s+\n/, ''), @cookbook.category).div(:line_numbers => :list, :css => :style) @cookbook.code_html = CodeRay.scan(@cookbook.code.gsub(/^\s+\n/, ''), @cookbook.category).div(:line_numbers => :list, :css => :style) @cookbook.user_id = current_user.id if @cookbook.save redirect_to :action => "show", :id => @cookbook else render :action => :new end end
Author
Highlight as C C++ CSS Clojure Delphi ERb Groovy (beta) HAML HTML JSON Java JavaScript PHP Plain text Python Ruby SQL XML YAML diff code