Not able to create tables by using batch cmd
Posted: 09 Nov 2014 00:18
I want to add gif files into a TABLE (HTML file) by using batch command, I am facing problem with below lines
set "table_start=^<table border='1'>"
set "table_one=^<tr^>^<th^>^Name^</th^>^<th^>^Remarks^</th^>^</tr^>"
when i edit the html file in notepad i don't see tags for table border and row one.
Below is the complete code, can somebody help me on this?
@echo off
setlocal
set "file_start=^<title^>^HTML Table Header GIRI^</title^>"
set "table_start=^<table border='1'>"
set "row_one=^<tr^>^<th^>^Name^</th^>^<th^>^Remarks^</th^>^</tr^>"
set "image_start=^<tr^>^<th^>^<IMG SRC=""
set ^"image_end="^>^</th^>^<th^>^Remarks^</th^>^</tr^>"
set "table_end=^</table^>"
set "file_end=^</BODY^>^</HTML^>"
set "file_name=Index.html"
>"%file_name%" ( echo %USERNAME% %DATE% %TIME%
echo %file_start%
for %%I in (*.gif) do echo %image_start%%%~fI%image_end%
echo %file_end%
)
start %file_name%
set "table_start=^<table border='1'>"
set "table_one=^<tr^>^<th^>^Name^</th^>^<th^>^Remarks^</th^>^</tr^>"
when i edit the html file in notepad i don't see tags for table border and row one.
Below is the complete code, can somebody help me on this?
@echo off
setlocal
set "file_start=^<title^>^HTML Table Header GIRI^</title^>"
set "table_start=^<table border='1'>"
set "row_one=^<tr^>^<th^>^Name^</th^>^<th^>^Remarks^</th^>^</tr^>"
set "image_start=^<tr^>^<th^>^<IMG SRC=""
set ^"image_end="^>^</th^>^<th^>^Remarks^</th^>^</tr^>"
set "table_end=^</table^>"
set "file_end=^</BODY^>^</HTML^>"
set "file_name=Index.html"
>"%file_name%" ( echo %USERNAME% %DATE% %TIME%
echo %file_start%
for %%I in (*.gif) do echo %image_start%%%~fI%image_end%
echo %file_end%
)
start %file_name%