Answers for "javascript set meta tag"

2

javascript change meta tag

document.querySelector('meta[name="description"]').setAttribute("content", _desc);
Posted by: Guest on January-16-2020
0

append meta tag to head javascript

<script>  var link = document.createElement('meta');  link.setAttribute('name', 'shareaholic:url');  link.content = document.location;  document.getElementsByTagName('head')[0].appendChild(link);</script>
Posted by: Guest on January-12-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language