R
robertchen117
I am trying to use this to output the last 100 lines to a cgi page,
but because it do not print \n in HTML, so everything is mess up. I do
not want to try to open a file, read the last 100 lines and close the
file. Because I think it would be slow than Unix "tail".
$done = system("tail -100 $filename")
tail in cgi page, No return/new lines:
DISSE0029I Current software package status is 'IC---'. DISSE0001I
Operation successful. DISSE0609I The container 'NT' is skipped because
the condition '$(os_name) == Windows_NT' is false. =================
Software Package: "test_package^1.0" Operation: install Mode: not-
transactional,not-undoable | force Time: 2007-02-13 00:24:35 Log File:
ess.vip.dot.com:/tivoli/bin/swdis/work/test_package^1.0.log
================= squad.sjc.dot.com: DISSE0074I Operation successfully
submitted. Distribution ID is 1278500431.238232. =================
Software Package: "test_package^1.0" Operation: install Mode: not-
transactional,not-undoable | force Time: 2007-02-13 00:24:46
================= sq.csco.dot.com: DISSE0155I Distribution ID:
`1278500431.238232' DISSE0029I Current software package status is
'IC---'. DISSE0001I Operation successful. DISSE0609I The container
'NT' is skipped because the condition '$(os_name) ==
but because it do not print \n in HTML, so everything is mess up. I do
not want to try to open a file, read the last 100 lines and close the
file. Because I think it would be slow than Unix "tail".
$done = system("tail -100 $filename")
tail in cgi page, No return/new lines:
DISSE0029I Current software package status is 'IC---'. DISSE0001I
Operation successful. DISSE0609I The container 'NT' is skipped because
the condition '$(os_name) == Windows_NT' is false. =================
Software Package: "test_package^1.0" Operation: install Mode: not-
transactional,not-undoable | force Time: 2007-02-13 00:24:35 Log File:
ess.vip.dot.com:/tivoli/bin/swdis/work/test_package^1.0.log
================= squad.sjc.dot.com: DISSE0074I Operation successfully
submitted. Distribution ID is 1278500431.238232. =================
Software Package: "test_package^1.0" Operation: install Mode: not-
transactional,not-undoable | force Time: 2007-02-13 00:24:46
================= sq.csco.dot.com: DISSE0155I Distribution ID:
`1278500431.238232' DISSE0029I Current software package status is
'IC---'. DISSE0001I Operation successful. DISSE0609I The container
'NT' is skipped because the condition '$(os_name) ==