I have a PowerShell command that returns an HTML snippet:
(Get-AzureResourceGroupGalleryTemplate -Identity Microsoft.WebSiteSQLDatabase.0.3.17-preview).description
Is there a way to easily render that snippet without first saving it to a file? e.g. perhaps throw it into a web browser?
Create a new Internet Explorer instance and inject your HTML snippet into the body of a blank page:
$id = 'Microsoft.WebSiteSQLDatabase.0.3.17-preview'
$html = (Get-AzureResourceGroupGalleryTemplate -Identity $id).description
$ie = New-Object -COM 'InternetExplorer.Application'
$ie.Navigate('about:blank')
do {
Start-Sleep -Milliseconds 100
} until ($ie.ReadyState -eq 4)
$ie.Document.body.innerHTML = $html
$ie.Visible = $true
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With