How to include html code

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • redmark
    Registered User
    • Jul 2007
    • 8

    #1

    How to include html code

    What most webmasters do to include html code to their pages like a menu on top of every pages of the site that can be updated without manually change all these pages.

    What is the right way to do this for seo, server speed and user friendly

    I need step by step details for server configuration
    Thanks in advance
    Redmark
  • hulker
    Registered User
    • Mar 2013
    • 26

    #2
    Originally posted by redmark
    I need step by step details for server configuration
    Most of us is happy to help you, but nobody works for free.
    pervypig.com

    Comment

    • Tittytweaker
      Confirmed User
      • Dec 2012
      • 184

      #3
      What kind of site do you have? Purely HTML or is it handled through a content management system?

      If it's the former, you need to look into HTML and CSS.

      http://www.w3schools.com/

      That website is very helpful.
      www.tittytweaker.com

      Comment

      • johnny_d
        Confirmed User
        • Sep 2012
        • 827

        #4
        You can either use a content management system (like Wordpress, or Joomla) or PHP.

        To start make header.php, index.php, and footer.php, and then you can work on adding the rest of the sites (between the header and footer; site1.php, site2.php etc).

        You are going to use php "include", and as the index.php loads first you are going to add include 'header.php' and include 'footer.php' on the bottom of the index file. So basically you need to do it with php. Then you can start working on custom titles for every page etc. There is a lot of info about it on the Internet.

        Comment

        • sarettah
          see you later, I'm gone
          • Oct 2002
          • 14293

          #5
          Originally posted by redmark
          What most webmasters do to include html code to their pages like a menu on top of every pages of the site that can be updated without manually change all these pages.

          What is the right way to do this for seo, server speed and user friendly

          I need step by step details for server configuration
          Thanks in advance
          There is no single right way. There are various ways to pull iit off. As was said above you can use php and php includes OR you can use SSI (Server Side Includes).

          It depends on what you are building and what kind of framework (cms) you may be inside of.

          Each method has trade offs in speed, generally the more complex the scheme the longer it takes to complete.

          As far as seo and user friendliness that has everything to do with the actual web design and absolutely nothing to do with how you include the html code (unless you are doing something funky like having your pages written entirely from a javascript call. If you are doing that you are purposely not making it seo friendly.)

          .
          All cookies cleared!

          Comment

          • redmark
            Registered User
            • Jul 2007
            • 8

            #6
            Thanks everybody for your answers

            I saw websites using dynamic pages with .php and .html
            Using .html for dynamic pages can slowdown the server, is this true?
            Redmark

            Comment

            • Mark.Roy
              Confirmed User
              • Apr 2013
              • 122

              #7
              what you are referring to is called php function include.

              if same content on your site is gonna appear on many pages then you create a separate file for it and just use this code in pages, where you wanna sho it.
              <?php
              include(filename.php); ?>

              read some books on php and html, there are loads of material online and for free too.
              good luck.



              email: mark[at]insanedollars[dot]com | ICQ::685~986~008

              Flat $125 PPS Cam Site! Make Insane Dollar$!!

              Comment

              • PeR930
                Confirmed User
                • Dec 2012
                • 283

                #8
                Ditto on php include function as others have said.

                Comment

                Working...