where do i put the <head> tag here?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • marc goyvaerts
    New Member
    • Apr 2011
    • 7

    where do i put the <head> tag here?

    ?>
    <meta http-equiv="Refresh" content="300" />
    <meta http-equiv="Pragma" content="no-cache" />
    <meta http-equiv="Cache-Control" content="no-cache" />

    <?php
    $doPrintBNLWN = false;
    include("BNLWN-mesomap.php");
    print $BNLWN_CSS; ?>
    </head>
    <body>
    <?php print $BNLWN_MAP; print $BNLWN_TABLE; ?>
    <?php
    Attached Files
  • JKing
    Recognized Expert Top Contributor
    • Jun 2007
    • 1206

    #2
    Normally before the meta tags. However without seeing what is being included with top.php it's hard to be certain.

    Comment

    • marc goyvaerts
      New Member
      • Apr 2011
      • 7

      #3
      Hi,

      Thanks for the answer, i have enclosed the "top" page, perhaps this enlightens you....
      Marc,
      Attached Files
      Last edited by marc goyvaerts; Apr 25 '11, 03:44 PM. Reason: Included txt file

      Comment

      • JKing
        Recognized Expert Top Contributor
        • Jun 2007
        • 1206

        #4
        If you added it as an attachment I cannot see it. Perhaps try uploading it again or copying and pasting the contents of top.php into CODE tags and reposting.

        Comment

        • JKing
          Recognized Expert Top Contributor
          • Jun 2007
          • 1206

          #5
          The head tag is being included in top.php. You shouldn't need to add it at all.

          Comment

          • marc goyvaerts
            New Member
            • Apr 2011
            • 7

            #6
            Yeah, but when i insert it like that it ends above the template instead of in the template, look here:

            Comment

            • JKing
              Recognized Expert Top Contributor
              • Jun 2007
              • 1206

              #7
              Check your footer.php file. It looks likes you have included an extra header in there as well as a body and doctype.

              Comment

              • marc goyvaerts
                New Member
                • Apr 2011
                • 7

                #8
                You've got me lost here! Can you take a look at it and give me a few pointers?

                Thx in advance!!
                Attached Files

                Comment

                • JKing
                  Recognized Expert Top Contributor
                  • Jun 2007
                  • 1206

                  #9
                  Okay.

                  Your main template includes two other templates. One for the top of the page and one for the footer. In the footer there is a duplicate html, head, and body tag as well as a doctype.

                  Lines 34-42 in your footer.php are the duplicate lines.

                  Removing them should solve your issue. As always when making changes make sure you backup your original file.

                  Here's the snippet to look for.
                  Code:
                  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
                      "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
                  <html xmlns="http://www.w3.org/1999/xhtml">
                  <head>
                  <meta name="generator" content=
                  "HTML Tidy for Windows (vers 14 February 2006), see www.w3.org" />
                  <title></title>
                  </head>
                  <body>

                  Comment

                  • marc goyvaerts
                    New Member
                    • Apr 2011
                    • 7

                    #10
                    Hello,

                    Found the snippet, removed it but to no avail, the snippet above was inserted as you can see by accident thanks to my validator....

                    Marc,

                    Comment

                    • JKing
                      Recognized Expert Top Contributor
                      • Jun 2007
                      • 1206

                      #11
                      What do you mean by to no avail?

                      Removing the snippet from the footer has removed the duplicate head tag.

                      I am no longer certain what your question is or what issue you are trying to solve...

                      Comment

                      • marc goyvaerts
                        New Member
                        • Apr 2011
                        • 7

                        #12
                        It didn't resolved the issue i am having with the page i am trying to fix...

                        Sorry,

                        Comment

                        • JKing
                          Recognized Expert Top Contributor
                          • Jun 2007
                          • 1206

                          #13
                          After closer inspection of the page I see you have a center aligned layout far below all the info and date for the page. I am right in assuming that the problem is your content(the map and the date) is not inside your page?

                          If this is the case you need to modify the first template you posted.

                          You need to move line 49 to inside your main div(around line 61).
                          This is the line in question:
                          Code:
                          <?php print $BNLWN_MAP; print $BNLWN_TABLE; ?>
                          This is the code with the line moved:
                          Code:
                          <?php
                          ############################################################################
                          # A Project of TNET Services, Inc. and Saratoga-Weather.org (WD-World template set)
                          ############################################################################
                          #
                          #   Project:    Sample Included Website Design
                          #   Module:     sample.php
                          #   Purpose:    Sample Page
                          #   Authors:    Kevin W. Reed <kreed@tnet.com>
                          #               TNET Services, Inc.
                          #
                          # 	Copyright:	(c) 1992-2007 Copyright TNET Services, Inc.
                          ############################################################################
                          # This program is free software; you can redistribute it and/or
                          # modify it under the terms of the GNU General Public License
                          # as published by the Free Software Foundation; either version 2
                          # of the License, or (at your option) any later version.
                          #
                          # This program is distributed in the hope that it will be useful,
                          # but WITHOUT ANY WARRANTY; without even the implied warranty of
                          # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
                          # GNU General Public License for more details.
                          #
                          # You should have received a copy of the GNU General Public License
                          # along with this program; if not, write to the Free Software
                          # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA
                          ############################################################################
                          #	This document uses Tab 4 Settings
                          ############################################################################
                          require_once("Settings.php");
                          require_once("common.php");
                          ############################################################################
                          $TITLE= $SITE['organ'] . " - Sample Blank Page";
                          $showGizmo = true;  // set to false to exclude the gizmo
                          include("top.php");
                          ############################################################################
                          
                          ?>
                          <meta http-equiv="Refresh" content="300" />
                          <meta http-equiv="Pragma" content="no-cache" />
                          <meta http-equiv="Cache-Control" content="no-cache" />
                          
                          <?php
                          $doPrintBNLWN = false;
                          include("BNLWN-mesomap.php");
                          print $BNLWN_CSS; ?> 
                          </head>   
                          <body>
                          <?php
                          ############################################################################
                          include("header.php");
                          ############################################################################
                          include("menubar.php");
                          ############################################################################
                          ?>
                          <div id="main-copy">
                            
                          	<h1>Benelux Weather Network</h1>
                              
                                  [B]<?php print $BNLWN_MAP; print $BNLWN_TABLE; ?> [/B]
                          </div><!-- end main-copy -->
                          <?php
                          ############################################################################
                          include("footer.php");
                          ############################################################################
                          # End of Page
                          ############################################################################
                          ?>

                          Comment

                          • marc goyvaerts
                            New Member
                            • Apr 2011
                            • 7

                            #14
                            Yes!!

                            That finally did the trick! Thank you so much for helping me out with this! I still have a few pages who need some editing because they are not totally right, i would be very grateful if you would help me out with these too?

                            Marc,
                            PS, the good page is on http://www.akker.be/car/wxbenelux.php

                            Comment

                            • JKing
                              Recognized Expert Top Contributor
                              • Jun 2007
                              • 1206

                              #15
                              Looks good.

                              If you have separate issues on other pages, you should start a different thread clearly outlining the issue and either myself or another user will help you out.

                              Comment

                              Working...