I want to get content of this page and save it as a batch variable.
http://ip-api.com/line?fields=2
I just want to do it with batch without any external apps or PowerShell commands if possible.
The above URL will return country code of the current IP Address.
I already did it with this batch file, But I don't want PowerShell codes:
@echo off
for /f "tokens=*" %%i in ('powershell /command "(Invoke-WebRequest -Uri 'http://ip-api.com/line?fields=2').Content"') do set return=%%i
echo "%return%"
pause