This is a quick one, but man is it sexy. I’m loving the new configuration support in Sitecore 9. Let’s take a look at the new “set” command in the patch configuration.
Here’s how we could update two site values in the previous versions of Sitecore:
<sites> <site name="website" virtualFolder="/"> <patch:attribute name="domainPath">/home</patch:attribute> <patch:attribute name="virtualFolder">/sitecore modules/site</patch:attribute> </site> </sites>
Is that impossible to figure out? Nah. Can it be easier? Yep! Here’s how to do the same thing in Sitecore 9.
<sites> <site name="website" virtualFolder="/" set:domainPath="/home" set:virtualFolder="/sitecore modules/site" /> </sites
Now THAT is simple!
Edit: You’re going to want to import this in your configuration node like so:
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/" xmlns:set="http://www.sitecore.net/xmlconfig/set/">
[ls_content_block slug=”nineonninefooter”]
![Share on Facebook Facebook](https://rockpapersitecore.com/wp-content/plugins/social-media-feather/synved-social/image/social/regular/48x48/facebook.png)
![Share on Twitter twitter](https://rockpapersitecore.com/wp-content/plugins/social-media-feather/synved-social/image/social/regular/48x48/twitter.png)
![Share on Reddit reddit](https://rockpapersitecore.com/wp-content/plugins/social-media-feather/synved-social/image/social/regular/48x48/reddit.png)
![Share on Linkedin linkedin](https://rockpapersitecore.com/wp-content/plugins/social-media-feather/synved-social/image/social/regular/48x48/linkedin.png)
![Share by email mail](https://rockpapersitecore.com/wp-content/plugins/social-media-feather/synved-social/image/social/regular/48x48/mail.png)
Very cool, but you don’t provide any details on where you are importing that command from.
Good catch. I updated the post!