Welcome Guest, Not a member yet? Register   Sign In
Meta tag helper with Open Graph tags
Big Grin 
(This post was last modified: 01-23-2015, 11:04 PM by Smith.)

Hi guys!
I have a problem with the "html_helper". For example, I have this function in a controller:

PHP Code:

$data['post']      = $this->blog_model->getPost($unix);

$data['post'] as $meta)
$metas = array(
'name' => 'og:title''content' => $meta["content"], 'type' => 'property')



I try to create labels based on the content you get from a model. The problem is that the meta label is created above the html tag. I extended the html_helper to use Open Graph tags.

<meta name="description" content="My Great site" />
<!DOCTYPE html>
<!--[if IE 8]>            <html class="ie ie8"> <![endif]-->
<!--[if IE 9]>            <html class="ie ie9"> <![endif]-->
<!--[if gt IE 9]><!-->    <html> <!--<![endif]-->

I tried to fix this with a validation in the template. but does not work

You are loading template with an array where ['post'] is your meta data?

Is this template loader suppose to replace some meta tags with data or generate meta data @ some point of file. I assume you should check your template file and see if it has it's anchors/replace_tags placed correctly if it's using any.

Theme © iAndrew 2016 - Forum software by © MyBB