Commit | Line | Data |
0f0899e8 |
1 | NAME |
2 | Catalyst::Controller::MovableType - Run Movable Type through Catalyst |
3 | |
9eb09c1b |
4 | DESCRIPTION |
5 | Runs Movable Type 5 through Catalyst. Download Movable Type 5 from |
6 | http://www.movabletype.org/ |
7 | |
9839e790 |
8 | SYNOPSIS |
962d061e |
9 | package MyApp::Controller::Mt; |
9839e790 |
10 | |
962d061e |
11 | use Moose; |
12 | BEGIN {extends 'Catalyst::Controller::MovableType'; } |
13 | use utf8; |
9839e790 |
14 | |
962d061e |
15 | 1; |
9839e790 |
16 | |
17 | INSTALLATION |
18 | Install Movable Type by extracting the zip into your template root |
9eb09c1b |
19 | directory. Move mt-static to root/static/mt. See Synopsis on how to |
20 | inherit the Controller in your app. Presuming you installed Movable Type |
21 | into root/mt, in your App's config add: |
9839e790 |
22 | |
9eb09c1b |
23 | <Controller::Root> cgi_root_path mt/ cgi_dir mt/ </Controller::Root> |
24 | <Controller::Mt> mt_home = /full/path/to/MyApp/root/mt/ <actions> |
25 | <capture_script_name> PathPart = mt </capture_script_name> </actions> |
26 | </Controller::Mt> |
27 | |
28 | The cgi_* directives are always given for the Root controller, no matter |
29 | what the Root controller is. |
30 | |
31 | You can modify the path where the script matches by configuring the |
32 | PathPart as shown above. This controller defaults to match on the path |
33 | "/mt". |
34 | |
35 | Finally, make sure that the Static::Simple doesn't affect the Movable |
36 | Type's installation directory. An example: |
37 | |
38 | __PACKAGE__->config( name => 'TerveinkansaFi', static => { # first |
39 | ignore all extensions, then specify static directories! |
40 | 'ignore_extensions' => [ qr/.*/ ], 'dirs' => [ qw/static/ ] } ); |
9839e790 |
41 | |
42 | METHODS |
9eb09c1b |
43 | capture_mt_script |
44 | Captures the path of the Movable Type. |
45 | |
9839e790 |
46 | run_mt_script |
47 | Runs the requested Movable Type .cgi script transparently with |
48 | cgi_to_response. |
49 | |
50 | not_found |
51 | Sets the response to a simple 404 Not found page. You can override this |
52 | method with your own. |
53 | |
54 | BUGS |
55 | None known. |
56 | |
57 | SEE ALSO |
58 | Catalyst::Controller::WrapCGI |
59 | |
60 | AUTHOR |
61 | Oskari 'Okko' Ojala <perl@okko.net> |
62 | |
63 | CONTRIBUTORS |
64 | Matt S. Trout <mst@shadowcatsystems.co.uk> |
65 | |
0f0899e8 |
66 | COPYRIGHT & LICENSE |
67 | Copyright 2010 the above author(s). |
68 | |
69 | This sofware is free software, and is licensed under the same terms as |
70 | Perl itself. |
9839e790 |
71 | |