Sha256: 8f86765104576b3faf60295ba5fe2b8bdc10fa4822de16a5cd39b13cc8ef6d1b
Contents?: true
Size: 562 Bytes
Versions: 10
Compression:
Stored size: 562 Bytes
Contents
require 'fileutils' module Ckeditor module Utils CKEDITOR_INSTALL_DIRECTORY = File.join(RAILS_ROOT, '/public/javascripts/ckeditor/') ################################################################## # remove the existing install (if any) def self.destroy if File.exist?(CKEDITOR_INSTALL_DIRECTORY) FileUtils.rm_r(CKEDITOR_INSTALL_DIRECTORY) end end def self.escape_single_quotes(str) str.gsub('\\','\0\0').gsub('</','<\/').gsub(/\r\n|\n|\r/, "\\n").gsub(/["']/) { |m| "\\#{m}" } end end end
Version data entries
10 entries across 10 versions & 3 rubygems