Monday, January 18, 2016

Prepend data to each line in text file

I needed to write a string to the start of each line in a text file.  I used Powershell to achieve this.  You can see the code here:

Saturday, January 2, 2016

Create a html file with images

I needed to create a quick and dirty HTML file that had 2 columns.  1 column was the website path to the image, the 2nd column was the image itself.  This would need to be created dynamically.
I have powershell code on here:

The following command:

.\CreateHTMLWithImages.ps1 -website -sourcepath \\web01\blog\images\2016\1\3\ -HTMLFile \\web01\blog\20160103.html -YSize 100 -XSize 100

Will produce a HTML file similar to this.