#!/bin/bash # # it works. # Put a tag in your html document where you want to insert data from the np.sh script called . # # export NOWPLAYING=$(ssh user@host /path/to/np.sh) export NOWPLAYING=$(PATH/TO/np.sh) file_name="/var/www/html/index.test" sed "s,,$NOWPLAYING," $file_name > /var/www/html/index.html