Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
I'm wondering what is the best way to insert example data into the Umbraco content tree after installing a starter kit
Is there a default way of doing this our should I write my own bootstrapper that does this for me?
I've taken a look at the LocalGovStarter kit and StarterKitInstall class takes care of this by importing a xml file. Is this the way to go?
Thanks in advance!
yes i wrote the import stuff inside the localgov starter kit because the standard content bits in the package manager don't quite work if you want to do anything complicated.
if you are just importing some very basic (not linked) content then it will work fine.
but if the content you are wanting to import has things like multi node tree pickers or page links in content then it's not going maintain those links when you import it - the code in the StarterKitInstall package does that for you.
originally i just used uSync to do this, as you can call the api with those xml files and it will do all the importing and mapping as you go. but bundling the usync dlls with a public starter kit isn't ideal - because if the packages can be updated out of sync it causes issues (and i wrote both of them! )
So if you are looking to import content that is linked, bootstrap it in code somehow (feel free to lift the localgov stuff) - but if it's just say a homepage and quick sample page, picking the content node when you create the package should work fine.
Thanks for the input, I will definitely check it out some more and build a poc to see if it suits my case
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted