Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How can I get the response #30

Open
ghost opened this issue Sep 25, 2020 · 3 comments
Open

How can I get the response #30

ghost opened this issue Sep 25, 2020 · 3 comments

Comments

@ghost
Copy link

ghost commented Sep 25, 2020

I was using this script https://github.com/npocmaka/batch.scripts/blob/master/hybrids/jscript/winhttpjs.bat. So what I want is to get the response and make it as a variable and not using external txt files.

@npocmaka
Copy link
Owner

Hello,

Thanks for using my tools.

Ty using -saveTo con to print it in the console

@ghost
Copy link
Author

ghost commented Sep 26, 2020

Thanks but what I want is to store the response in a variable

@npocmaka
Copy link
Owner

npocmaka commented Oct 5, 2020

Use for loop

setlocal enableDelayedExpansion
for /f "tokens=* delims=" %%# in ('winhttpjs.bat ... -saveto con') do (
  set "response=!response! %%#"
)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant