sed [options] sed-command [input-file]
| Option | Description | Example |
|---|
| <?php | |
| /** | |
| * ----------------------------------------------------------------------------------------- | |
| * Based on `https://github.com/mecha-cms/mecha-cms/blob/master/system/kernel/converter.php` | |
| * ----------------------------------------------------------------------------------------- | |
| */ | |
| // HTML Minifier | |
| function minify_html($input) { |
| <?php | |
| class WP_HTML_Compression { | |
| protected $compress_css = true; | |
| protected $compress_js = true; | |
| protected $info_comment = true; | |
| protected $remove_comments = true; | |
| protected $html; | |
| public function __construct($html) { | |
| if (!empty($html)) { |
| <?php | |
| /** | |
| * deploy.php by Hayden Schiff (oxguy3) | |
| * Available at https://gist.github.com/oxguy3/70ea582d951d4b0f78edec282a2bebf9 | |
| * | |
| * No rights reserved. Dedicated to public domain via CC0 1.0 Universal. | |
| * See https://creativecommons.org/publicdomain/zero/1.0/ for terms. | |
| */ | |
| // random string of characters; must match the "Secret" defined in your GitHub webhook |
| <% flash.each do |type, message| %> | |
| <div class="alert alert-<%= bootstrap_class_for(type) %> fade in"> | |
| <button class="close" data-dismiss="alert">×</button> | |
| <%= message %> | |
| </div> | |
| <% end %> |
| <%= form_with(model: document, local: true) do |form| %> | |
| <% if document.errors.any? %> | |
| <div id="error_explanation"> | |
| <h2><%= pluralize(document.errors.count, "error") %> prohibited this document from being saved:</h2> | |
| <ul> | |
| <% document.errors.full_messages.each do |message| %> | |
| <li><%= message %></li> | |
| <% end %> | |
| </ul> |
| extension = "newrelic.so" | |
| newrelic.license = "LICENSE_KEY" | |
| newrelic.logfile = "/var/log/newrelic/php_agent.log" | |
| newrelic.appname = "Kyani MODx; backoffice-modx; ${DESIGNATION}-backoffice" | |
| newrelic.capture_params = true | |
| newrelic.attributes.enabled = true | |
| newrelic.daemon.logfile = "/var/log/newrelic/newrelic-daemon.log" | |
| newrelic.framework = "no_framework" |
| # ------------------------------------------------------------------------------ | |
| # | |
| # Curtousy of the Magento Support Center | |
| # http://magentosupport.help/what-are-expires-headers-and-how-do-i-implement-them/ | |
| # | |
| # ------------------------------------------------------------------------------ | |
| # ------------------------------------------------------------------------------ | |
| # | Mod Caching via Apache | |
| <?php | |
| /** | |
| * Gravity Forms Paynamics Add-On. | |
| * | |
| * @since 1.0 | |
| * @package GravityForms | |
| * @author Rocketgenius | |
| * @copyright Copyright (c) 2009 - 2018, Rocketgenius | |
| */ |
| public function init() { | |
| filter( 'gform_field_content', array( $this, 'add_paynamics_inputs' ), 10, 5 ); | |
| add_action( 'gform_after_submission', array( $this, 'paynamics_after_submission' ), 10, 3 ); | |