Looking to Build/Redesign a Website or Blog ?

To speak to Rakshit, call +91 968 704 2303

Set Meta Tags (SEO Tags) in CakePHP

cakephp-freelancer-developer

Hello Friends,

In my previous post, i show you the way how to set Page Title Tag in CakePHP. But setting Meta keywords and Meta Description is not the same way as Meta Title. .Also Meta Keyword and Meta Description is important part of Search Engine Optimization. Refer to below syntax to set Meta tags in CakePHP.

<?php 
echo $html->meta('keywords','enter any meta keyword here');
?>
//Output <meta name="keywords" content="enter any meta keyword here"/>
<?php 
echo $html->meta('description','enter any meta description here');
?>
//Output <meta name="description" content="enter any meta description here"/>

If you find any problem in this than let me know by comment.
Share:

13 Comments

  • Hi..
    Very nice well managed blog Rakshit. By profession I am SEO executive, so not understood much in this post about CakePHP. But I like that being a developer, you are learning SEO techniques. It will definately help you in future  lot. I am also learning some CMS and PHP now to expend my knowledge.

    Gerat to read your profile however you have not mention the company you are working for. anyways if I can help you anyway I will be glad doing that.
    Keep it up.

  • Hi..
    Very nice well managed blog Rakshit. By profession I am SEO executive, so not understood much in this post about CakePHP. But I like that being a developer, you are learning SEO techniques. It will definately help you in future  lot. I am also learning some CMS and PHP now to expend my knowledge.

    Gerat to read your profile however you have not mention the company you are working for. anyways if I can help you anyway I will be glad doing that.
    Keep it up.

  • Hi,

    I have big troubles customizing my meta tags. I hope you can help me out. I currently use the following line:

    echo $html->meta(‘description’,$this->getVar(‘metaDescription’));

    But how can I put a default value in case the $this->getVar(‘metaDescription is empty?

    Cheers

  • estrategias marketing…

    […]Set Meta Tags (SEO Tags) in CakePHP | Programming Facts -PHP Freelancer-Indian Freelancer[…]…

  • Website Design Sussex…

    […]Set Meta Tags (SEO Tags) in CakePHP | Programming Facts -PHP Freelancer-Indian Freelancer[…]…

Leave a Reply

Your email address will not be published.