Archives
Trending
Support
Login
Basic Web form filling in PowerShell and IE
Show paste
<#
Basic Web form filling in PowerShell and IE
you need to start power shell like this:
PowerShell -ExecutionPolicy Bypass <script.ps1>
#>
Get InnerHTML of all DIV tags on a web page
Show paste
$Browser = New-Object -COM "InternetExplorer.Application"
$URL = "http://filmsbykris.com/v6/index.php"
$Browser.Navigate($URL)
While ($Browser.ReadyState -ne 4) { Start-Sleep -Seconds 1 }
unzip files with Power Shell
Show paste
$shell = new-object -com shell.application
$zip = $shell.NameSpace("C:\test.zip")
foreach($item in $zip.items())
{
$shell.Namespace("C:\test").copyhere($item)
Basic Webserver 1
Show paste
<#
This creates a web server on port 8080
It servers up output from this script.
example: http://localhost:8080/hello
Arguments
Show paste
<#
Script By Kris Occhipinti
http://filmsbykris.com
June 6th 2014
GPLv3
basename
Show paste
<#
Get's the base file name of a file
#>
$url = "http://test.com/folder/file.png"
Write-Host "The URL is $url"
Get and Run Quake - Windows - Progess Bar
Show paste
<#
Gets and Runs Quake for Windows
#>
My Wget in PowerShell
Show paste
<#
Not Really WGET
This is my own powershell for basic file downloading.
Script By Kris Occhipinti
Download a file with Power Shell
Show paste
Write-Output "Downloading File..."
$storageDir = $pwd
$webclient = New-Object System.Net.WebClient
$url = "https://dl.dropbox.com/s/69s8hogh2sxcqrl/miniweb-win32-20130309.zip"
Basic Webserver 2 - request file
Show paste
<#
From "http://obscuresecurity.blogspot.com/2014/05/dirty-powershell-webserver.html"
Webserver on port 8000
will serve up a file if you request it by name
example: "http://localhost:8000/index.html"
Previous
1
2
...
2658
2659
2660
2661
2662
...
2679
2680
Next