File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ <?php
2+
3+ namespace Craft ;
4+
5+ class StatusCodePlugin extends BasePlugin
6+ {
7+
8+ /**
9+ * Returns the plugin’s name
10+ *
11+ * @return string
12+ */
13+ public function getName ()
14+ {
15+ return 'Status Code ' ;
16+ }
17+
18+ /**
19+ * Returns the plugin’s version number.
20+ *
21+ * @return string The plugin’s version number.
22+ */
23+ public function getVersion ()
24+ {
25+ return '0.1.0 ' ;
26+ }
27+
28+ /**
29+ * Returns the plugin developer’s name.
30+ *
31+ * @return string The plugin developer’s name.
32+ */
33+ public function getDeveloper ()
34+ {
35+ return 'www.crafted.systems ' ;
36+ }
37+
38+ /**
39+ * Returns the plugin developer’s URL.
40+ *
41+ * @return string The plugin developer’s URL.
42+ */
43+ public function getDeveloperUrl ()
44+ {
45+ return 'https://www.crafted.systems ' ;
46+ }
47+
48+ /**
49+ * @return string
50+ */
51+ public function getDocumentationUrl ()
52+ {
53+ return 'https://github.com/craftedsystems/craft--status-code ' ;
54+ }
55+
56+ /**
57+ * Release feed
58+ * - must be valid JSON
59+ * - must begin with https://
60+ * https://craftcms.com/support/updating-plugins-for-craft-2.5#plugin-update-notifications
61+ * @return string
62+ */
63+ public function getReleaseFeedUrl ()
64+ {
65+ return 'https://raw.githubusercontent.com/craftedsystems/craft--status-code/master/releases.json ' ;
66+ }
67+
68+ }
Original file line number Diff line number Diff line change 1+ <?php
2+
3+ namespace Craft ;
4+
5+ class StatusCodeVariable {
6+
7+ /**
8+ * Get HTTP status
9+ */
10+ public function getHttpStatus ()
11+ {
12+ return http_response_code ();
13+ }
14+
15+ }
You can’t perform that action at this time.
0 commit comments