# HG changeset patch # User Nattee Niparnan # Date 2014-09-21 02:56:56 # Node ID 46e3534d5d5da4c63d1c4ac5ab95e5c9b9b9fd0b # Parent fd6c259da216aee9cf8b42a2744c64f708404549 add lexer for php diff --git a/app/controllers/graders_controller.rb b/app/controllers/graders_controller.rb --- a/app/controllers/graders_controller.rb +++ b/app/controllers/graders_controller.rb @@ -80,6 +80,7 @@ when "ruby" then Rouge::Lexers::Ruby.new when "python" then Rouge::Lexers::Python.new when "java" then Rouge::Lexers::Java.new + when "php" then Rouge::Lexers::PHP.new end @formatted_code = formatter.format(lexer.lex(@submission.source)) @css_style = Rouge::Themes::ThankfulEyes.render(scope: '.highlight')