Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New page name "untitled" when creating via API with new Name Format for Children setting. #425

Closed
adrianbj opened this issue Mar 28, 2014 · 2 comments

Comments

@adrianbj
Copy link

I think this is a bug rather than a feature. Set the Name Format for Child to: title and then create a new page via the API with a title assigned, but no name.

$p = new Page();
$p->template = "basic-page";
$p->parent = $pages->get("/about/");
$p->title = "Test New Page";
$p->save();

The newly created page will be titled correctly, but will have "untitled" for the name. I would expect. Note that everything works as expected if you also don't set the title and set the status to the new temp option.

I think that if you create a page with a title, then the name should still be assigned as it normally is. Am I missing the reason for this current behavior?

ryancramerdesign added a commit that referenced this issue Mar 28, 2014
…set getting named "untitled" rather than attempting to convert title to a name.
@ryancramerdesign
Copy link
Owner

Thanks Adrian, I've pushed a fix for this issue.

@adrianbj
Copy link
Author

Looks to be working great - thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants