Posted on 20/11/2018 13:28:40
Hi Adrian
If you are using a viewmodel there are not tags or loops from the 'old' template world. It is either one or the other. The viewmodels are instead of template tags.
When in a master template, you are using the pageviewmodel which can be found here: https://doc.dynamicweb.com/api/html/8175ac67-de8b-696a-7436-6505c1a61e47.htm
The list of external providers is not exposed on the viewmodel, but can be accessed directly in the API:
using Dynamicweb.Security.UserManagement.ExternalAuthentication;
ProviderCollection providers = Provider.GetActiveProviders();
Be aware that GetActiveProviders will result in a database call and has no caching whatsoever. Same as with the DWExtranetExternalLoginProviders loop.
BR Nicolai