def get_meta_headers

      headtags = ''

      # decide wether it is a page or it is a template displying other content i.e. the category page

      if !@content.nil?


        # if it has ACTUAL content then generate meta from the page content
        if !(@content.respond_to? :length)

          home_id = Setting.get('home_page')

          if @content.id == home_id.to_f
            # if it is the homepage create the meta tags manually
            headtags = get_manual_metadata 'home'
          else
            # use the page content to generate the meta data
            if @content.post_seo_is_disabled != 'Y'
              headtags = "#{get_page_title}\n"
              headtags += "#{get_meta_description}\n"
              headtags += "#{get_google_analytics}\n"
              headtags += "#{get_robots_tag}"
              headtags += "#{canonical_urls}"
            end
          end

          render :inline => headtags

        else

          url_arr = params[:slug].split('/') if !params[:slug].nil?

          # get generic variables
          article_url = Setting.get('articles_slug')
          category_url = Setting.get('category_slug')

          # if the url is equal to the article, category or archive area
          if (!url_arr.blank? && (url_arr.last == article_url || url_arr.last.match(/\A\+?\d+(?:\.\d+)?\Z/) || url_arr[1] == category_url))
            last_url = url_arr.last
            robots_var = nil

            if url_arr[0] == article_url || url_arr[1] == category_url
              robots_var = 'category'
            elsif last_url.match(/\A\+?\d+(?:\.\d+)?\Z/)
              robots_var = 'archive'
            end

            new_string = last_url.slice(0,1).capitalize + last_url.slice(1..-1)

            if last_url.match(/\A\+?\d+(?:\.\d+)?\Z/)
              if !url_arr[2].blank?

                new_string = Date::MONTHNAMES[url_arr[2].to_i]
                new_string = "#{new_string} #{url_arr[1]}"

                if !url_arr[3].blank?
                  new_string = "#{url_arr[3]} #{new_string}"
                end

              end
            end

            headtags = "#{get_page_title new_string}\n"
            headtags += "#{get_google_analytics}\n"
            headtags += "#{get_robots_tag robots_var}"

            render :inline => headtags

          end

        end

      else

        # render the 404 meta data
        headtags = response.status == 404 ? get_manual_metadata('404') : application_set_headers
        render :inline => headtags

      end

    end
def get_meta_headers

      headtags = ''

      # decide wether it is a page or it is a template displying other content i.e. the category page

      if !@content.nil?


        # if it has ACTUAL content then generate meta from the page content
        if !(@content.respond_to? :length)

          home_id = Setting.get('home_page')

          if @content.id == home_id.to_f
            # if it is the homepage create the meta tags manually
            headtags = get_manual_metadata 'home'
          else
            # use the page content to generate the meta data
            if @content.post_seo_is_disabled != 'Y'
              headtags = "#{get_page_title}\n"
              headtags += "#{get_meta_description}\n"
              headtags += "#{get_google_analytics}\n"
              headtags += "#{get_robots_tag}"
              headtags += "#{canonical_urls}"
            end
          end

          render :inline => headtags

        else

          url_arr = params[:slug].split('/') if !params[:slug].nil?

          # get generic variables
          article_url = Setting.get('articles_slug')
          category_url = Setting.get('category_slug')

          # if the url is equal to the article, category or archive area
          if (!url_arr.blank? && (url_arr.last == article_url || url_arr.last.match(/\A\+?\d+(?:\.\d+)?\Z/) || url_arr[1] == category_url))
            last_url = url_arr.last
            robots_var = nil

            if url_arr[0] == article_url || url_arr[1] == category_url
              robots_var = 'category'
            elsif last_url.match(/\A\+?\d+(?:\.\d+)?\Z/)
              robots_var = 'archive'
            end

            new_string = last_url.slice(0,1).capitalize + last_url.slice(1..-1)

            if last_url.match(/\A\+?\d+(?:\.\d+)?\Z/)
              if !url_arr[2].blank?

                new_string = Date::MONTHNAMES[url_arr[2].to_i]
                new_string = "#{new_string} #{url_arr[1]}"

                if !url_arr[3].blank?
                  new_string = "#{url_arr[3]} #{new_string}"
                end

              end
            end

            headtags = "#{get_page_title new_string}\n"
            headtags += "#{get_google_analytics}\n"
            headtags += "#{get_robots_tag robots_var}"

            render :inline => headtags

          end

        end

      else

        # render the 404 meta data
        headtags = response.status == 404 ? get_manual_metadata('404') : application_set_headers
        render :inline => headtags

      end

    end
Returns a block of html with all the necessary headers for the front end html to include.
 this is for the SEO functionallity to be included on each page. get_meta_headers is a
 bootstrap to include all of the necessary functions