Run script, line by line, modified php for sed usage