{"action":"created","issue":{"url":"https://api.github.com/repos/meetinghouse/cms/issues/217","repository_url":"https://api.github.com/repos/meetinghouse/cms","labels_url":"https://api.github.com/repos/meetinghouse/cms/issues/217/labels{/name}","comments_url":"https://api.github.com/repos/meetinghouse/cms/issues/217/comments","events_url":"https://api.github.com/repos/meetinghouse/cms/issues/217/events","html_url":"https://github.com/meetinghouse/cms/issues/217","id":131097842,"number":217,"title":"BOTH THEMES: Add custom pages capability to both themes.","user":{"login":"jboz62","id":11739120,"avatar_url":"https://avatars.githubusercontent.com/u/11739120?v=3","gravatar_id":"","url":"https://api.github.com/users/jboz62","html_url":"https://github.com/jboz62","followers_url":"https://api.github.com/users/jboz62/followers","following_url":"https://api.github.com/users/jboz62/following{/other_user}","gists_url":"https://api.github.com/users/jboz62/gists{/gist_id}","starred_url":"https://api.github.com/users/jboz62/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jboz62/subscriptions","organizations_url":"https://api.github.com/users/jboz62/orgs","repos_url":"https://api.github.com/users/jboz62/repos","events_url":"https://api.github.com/users/jboz62/events{/privacy}","received_events_url":"https://api.github.com/users/jboz62/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/meetinghouse/cms/labels/High%20Priority","name":"High Priority","color":"e11d21"}],"state":"open","locked":false,"assignee":{"login":"barryaprogrammer","id":15351144,"avatar_url":"https://avatars.githubusercontent.com/u/15351144?v=3","gravatar_id":"","url":"https://api.github.com/users/barryaprogrammer","html_url":"https://github.com/barryaprogrammer","followers_url":"https://api.github.com/users/barryaprogrammer/followers","following_url":"https://api.github.com/users/barryaprogrammer/following{/other_user}","gists_url":"https://api.github.com/users/barryaprogrammer/gists{/gist_id}","starred_url":"https://api.github.com/users/barryaprogrammer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/barryaprogrammer/subscriptions","organizations_url":"https://api.github.com/users/barryaprogrammer/orgs","repos_url":"https://api.github.com/users/barryaprogrammer/repos","events_url":"https://api.github.com/users/barryaprogrammer/events{/privacy}","received_events_url":"https://api.github.com/users/barryaprogrammer/received_events","type":"User","site_admin":false},"milestone":null,"comments":66,"created_at":"2016-02-03T17:35:57Z","updated_at":"2016-02-17T16:48:31Z","closed_at":null,"body":"Currently, there is no function to add custom pages, although, Andy has pointed out that it exists in the code and needs to be activated. \r\n\r\nComments from Andy:\r\n\r\nFor John and Barry - \r\nsome rough instructions below - note that I don't expect these to work without a little tweaking, this is mostly just off the top of my head.  It should get you started though.  The laravel 4.2 documentation is excellent.\r\n\r\ncopy the contents of the app/views/pages/edit.blade.php file to existing app/views/pages/create.blade.php file.  remove any unnecessary fields (delete button, etc) and whatever other text changes you want.  line 13 should look something like ` {{ Form::model('page', array('method' => 'POST', 'route' => array('pages.store'), 'files' => 'true', 'role' => 'form')) }}` - note the minor changes there.  \r\n\r\nThen in your `app/controllers/PagesController.php` file you should already have an empty `create` and `store` method.  The `create` method just needs to look like:\r\n```\r\n parent::show();\r\n        return View::make('pages.create');\r\n```\r\n\r\nand the `store` method should look something like:\r\n```\r\n$input = Input::all();\r\n$validator = Validator::make($input, array('slug' => 'regex:/^\\/[A-Za-z0-9_]+$/'));           \r\n            if($validator->passes()) {\r\n                $page = Page::create($input);\r\n                $banner = $this->bannerSet($page);\r\n                return Redirect::to(\"pages.index\")->withMessage(\"Created Page\");\r\n            } else {\r\n                return Redirect::to('pages/' . $page->id . '/edit')->withErrors($validator)\r\n                    ->withMessage(\"Error \");\r\n```\r\n\r\nthen you'll just need to add a button at the bottom of the `app/views/pages/index.blade.php` file like `<a class=\"btn btn-success\" href=\"/pages/create\">create page</a>`"},"comment":{"url":"https://api.github.com/repos/meetinghouse/cms/issues/comments/185293100","html_url":"https://github.com/meetinghouse/cms/issues/217#issuecomment-185293100","issue_url":"https://api.github.com/repos/meetinghouse/cms/issues/217","id":185293100,"user":{"login":"jboz62","id":11739120,"avatar_url":"https://avatars.githubusercontent.com/u/11739120?v=3","gravatar_id":"","url":"https://api.github.com/users/jboz62","html_url":"https://github.com/jboz62","followers_url":"https://api.github.com/users/jboz62/followers","following_url":"https://api.github.com/users/jboz62/following{/other_user}","gists_url":"https://api.github.com/users/jboz62/gists{/gist_id}","starred_url":"https://api.github.com/users/jboz62/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jboz62/subscriptions","organizations_url":"https://api.github.com/users/jboz62/orgs","repos_url":"https://api.github.com/users/jboz62/repos","events_url":"https://api.github.com/users/jboz62/events{/privacy}","received_events_url":"https://api.github.com/users/jboz62/received_events","type":"User","site_admin":false},"created_at":"2016-02-17T16:48:31Z","updated_at":"2016-02-17T16:48:31Z","body":"Some of the formatting is missing on S+H and the mobile menu I added is also missing, I can ftp them up for now and then commit the changes when I get set up, if that works. Those changes should be in the base code, as well, for the dark theme, so I'll create a branch to add the changes and then we can do a merge. Should be set up by the weekend, I hope, if all goes well."}}