snipt

Ctrl+h for KB shortcuts

Bash

See which modules are loaded in Apache (on OSX)

/usr/sbin/apachectl -l
https://snipt.net/embed/a17534013b8b9c8126a807f9e06917a4/
/raw/a17534013b8b9c8126a807f9e06917a4/
a17534013b8b9c8126a807f9e06917a4
bash
Bash
1
2019-06-22T07:52:14
True
False
False
/api/public/snipt/10839/
see-which-modules-are-loaded-in-apache-on-osx
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a>/usr/sbin/apachectl -l </span></pre></div> </td></tr></table>
apache, modules, osx

Bash

Apache2 permanent redirect to external URL

1
2
3
## APACHE2: permanently redirect local link to external URL

Redirect 301 /blog/rss http://feeds2.feedburner.com/petekarl
https://snipt.net/embed/c131cd47d5804ebd98776f65b56fa731/
/raw/c131cd47d5804ebd98776f65b56fa731/
c131cd47d5804ebd98776f65b56fa731
bash
Bash
3
2019-06-21T14:02:59
True
False
False
/api/public/snipt/4976/
apache2-permanent-redirect-to-external-url
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a> <a href="#L-2">2</a> <a href="#L-3">3</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a><span class="c1">## APACHE2: permanently redirect local link to external URL</span> </span><span id="L-2"><a name="L-2"></a> </span><span id="L-3"><a name="L-3"></a>Redirect <span class="m">301</span> /blog/rss http://feeds2.feedburner.com/petekarl </span></pre></div> </td></tr></table>
apache, redirect

ApacheConf

mod_rewrite 301 redirect

RewriteRule ^whatever/(.*)$ http://www.domain.com/$1/ [R=301,L]
https://snipt.net/embed/e4754a4e77c65133b1c9404bb821e45a/
/raw/e4754a4e77c65133b1c9404bb821e45a/
e4754a4e77c65133b1c9404bb821e45a
apacheconf
ApacheConf
1
2019-06-25T14:05:16
True
False
False
/api/public/snipt/438/
mod_rewrite-301-redirect
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a><span class="nb">RewriteRule</span> ^whatever/(.*)$ http://www.domain.com/$1/ [R=301,L] </span></pre></div> </td></tr></table>
apache, mod_rewrite