PluginProbe
Redirection / 2.3.15
Redirection v2.3.15
5.10.0 5.9.0 5.8.1 5.8.0 3.7.2 3.7.3 4.0 4.0.1 4.1 4.1.1 4.2 4.2.1 4.2.2 4.2.3 4.3 4.3.1 4.3.2 4.3.3 4.4 4.4.1 4.4.2 4.5 4.5.1 4.6.2 4.7.1 All 130 releases
redirection / redirection.php

redirection.php in Redirection 2.3.15, at redirection.php

59 lines 2.3 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /*
3 Plugin Name: Redirection
4 Plugin URI: http://urbangiraffe.com/plugins/redirection/
5 Description: Manage all your 301 redirects and monitor 404 errors
6 Version: 2.3.15
7 Author: John Godley
8 Author URI: http://urbangiraffe.com
9 ============================================================================================================
10 This software is provided "as is" and any express or implied warranties, including, but not limited to, the
11 implied warranties of merchantibility and fitness for a particular purpose are disclaimed. In no event shall
12 the copyright owner or contributors be liable for any direct, indirect, incidental, special, exemplary, or
13 consequential damages(including, but not limited to, procurement of substitute goods or services; loss of
14 use, data, or profits; or business interruption) however caused and on any theory of liability, whether in
15 contract, strict liability, or tort(including negligence or otherwise) arising in any way out of the use of
16 this software, even if advised of the possibility of such damage.
17
18 For full license details see license.txt
19 ============================================================================================================
20 */
21
22 define( 'REDIRECTION_VERSION', '2.3.1' ); // DB schema version. Only change if DB needs changing
23 define( 'REDIRECTION_FILE', __FILE__ );
24
25 include dirname( __FILE__ ).'/models/module.php';
26 include dirname( __FILE__ ).'/models/log.php';
27 include dirname( __FILE__ ).'/models/flusher.php';
28 include dirname( __FILE__ ).'/models/match.php';
29 include dirname( __FILE__ ).'/models/action.php';
30 include dirname( __FILE__ ).'/models/redirect.php';
31
32 function red_get_options() {
33 $options = get_option( 'redirection_options' );
34 if ( $options === false )
35 $options = array();
36
37 $defaults = array(
38 'support' => false,
39 'token' => '',
40 'monitor_post' => 0,
41 'auto_target' => '',
42 'expire_redirect' => 7,
43 'expire_404' => 7,
44 );
45
46 foreach ( $defaults AS $key => $value ) {
47 if ( !isset( $options[$key] ) )
48 $options[$key] = $value;
49 }
50
51 $options['lookup'] = apply_filters( 'red_lookup_ip', 'http://urbangiraffe.com/map/?ip=' );
52 return $options;
53 }
54
55 if ( is_admin() )
56 include dirname( __FILE__ ).'/redirection-admin.php';
57 else
58 include dirname( __FILE__ ).'/redirection-front.php';
59