0

This script auto generates the image tag, but i need to put this command into a windows bat file. This piece of code works fine when written in cmd window.

FOR %i IN (*.JPG) DO ECHO ^<img src="%i" /^> >> index.html

Thanks and Regards

technocrat
  • 701
  • 5
  • 13
  • 23

1 Answers1

5

In batch files you need to use %%variable format instead of %variable

Try this:

FOR %%i IN (*.JPG) DO ECHO ^<img src="%%i" /^> >> index.html

MSDN reference

GoAvs
  • 103
  • 6