html_encode meta variables
parent
5d6d5d8601
commit
58a6c5ace1
|
@ -82,7 +82,7 @@ if [[ "${get_data[v]}" ]]; then
|
|||
meta[title]="${strings[title]}"
|
||||
meta[description]="$(jq -r '.description' <<< "$video")"
|
||||
meta[unsafe]="
|
||||
<meta property='og:image' content='https://i.ytimg.com/vi/${get_data[v]}/hqdefault.jpg'>
|
||||
<meta property='og:image' content='https://i.ytimg.com/vi/$(html_encode "${get_data[v]}")/hqdefault.jpg'>
|
||||
<meta property='og:type' content='video.other'>
|
||||
<meta property='video:duration' content='$(jq -r '.duration' <<< "$video")'>
|
||||
"'<script type="application/ld+json">'"$(jq '{
|
||||
|
@ -93,7 +93,7 @@ if [[ "${get_data[v]}" ]]; then
|
|||
"description": .description,
|
||||
"thumbnail": .thumbnails[-1].url,
|
||||
"duration": ("PT" + (.duration | tostring) + "S"),
|
||||
}' <<< "$video")"'</script>'
|
||||
}' <<< "$video" | sed 's/</\</g;s/>/\>/g;')"'</script>'
|
||||
source templates/head.sh
|
||||
fi
|
||||
formats=$(jq '.formats' <<< "$video")
|
||||
|
|
Loading…
Reference in New Issue