Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #931374

    Hi,

    I’ve searched but unable to find how to do this. I have the HTML code, but how do I add the metatag to all my pages?

    I understand it should be in the header, so presumably something in the header.php file? I don’t know how to adapt the html in order to add it to a php file.

    <meta name=”viewport” content=”width=device-width, initial-scale=1″>

    Please advise, thank you

    #931385

    Well you can add to the head section with
    this to functions.php of your child-theme

    add_action('wp_head', 'add_to_head');
    function add_to_head(){
    ?>
    	<meta name="viewport" content="width=device-width, initial-scale=1">
    	<meta name="description" content="best not more than 140letters">
    	<meta name="keywords" content=" seperated by commata ">
    	<link rel="shortcut icon" type="image/x-icon" href="/wp-content/uploads/icons/favicon.ico">
    	<link rel="apple-touch-icon" href="/wp-content/uploads/icons/apple-touch-icon.png">
    <?php
    }

    everything like description is that you see in search on google under the url ( Real sentences with not more than 140 letters)
    or keywords are the tags you look for – separated via commata
    and viewport too

    #931777

    Hi SuperSportsUAE,

    Does the solution from Guenni007 resolve your issue or do you still need more help?

    Best regards,
    Victoria

    #931793

    Thank you, I’ll give that a try.

    #931839

    Think it did, but decided to go with a plugin to avoid playing with things I don’t really understand :-)

    Thanks

    #931932

    Hi SuperSportsUAE,

    Glad you got it working for you! :)

    If you need further assistance please let us know.

    Best regards,
    Victoria

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.