20 lines
482 B
Bash
Executable File
20 lines
482 B
Bash
Executable File
#!/bin/bash
|
|
source templates/head.sh
|
|
|
|
echo "<form action='${r[url]}/search.shs'>
|
|
<input name='q' type='text'>
|
|
<input type='submit' value='Search'>
|
|
</form>
|
|
|
|
<h1>All user's favourites:</h1>"
|
|
|
|
IFS=$'\n'
|
|
for i in $(tac storage/faves); do
|
|
IFS=':'
|
|
array=($i)
|
|
if [[ ${array[1]} == '' ]]; then
|
|
break
|
|
fi
|
|
echo "<div><a href='watch.shs?v=${array[1]}'><img src='https://i.ytimg.com/vi/${array[1]}/mqdefault.jpg'><br><b>${array[@]:2:999}</b></a><br>Favourited by ${array[0]}</div>";
|
|
done
|