Nico Knoll Posted November 13, 2011 Share Posted November 13, 2011 Hi, how can I select "hidden" via API? My current code doesn't work: $home = $this->pages->get('/'); $page = new Page(); $page->parent = $home; $page->template = $this->templates->get('admin'); $page->name = 'storage'; $page->hidden = 'true'; $page->title = "Storage"; $page->process = $this; $page->sort = $home->numChildren; $page->save(); Greets, Nico Link to comment Share on other sites More sharing options...
ryan Posted November 14, 2011 Share Posted November 14, 2011 Nico, replace your $page->hidden = 'true'; with this: $page->addStatus(Page::statusHidden); 1 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now