can we apply oops concept in xhtml...?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • rahullko05
    New Member
    • Oct 2008
    • 34

    can we apply oops concept in xhtml...?

    i have a small xhtml code, which is common across 10 files. right now same code is written in all 10 files. is there a way in xhtml that i
    can write that peice of code (extended in .html) is in one file and use it in all the files. may be something like oops concept?
  • Dormilich
    Recognized Expert Expert
    • Aug 2008
    • 8694

    #2
    XML (and thus XHTML) itself is not capable of OOP, because it's a markup and not a programming language. if you want to re-use code, you might want to use a server side scripting language to do so.

    PS: XHTML with the .html extension is treated as HTML (you have to use either .xml or .xhtml)

    Comment

    • rahullko05
      New Member
      • Oct 2008
      • 34

      #3
      Thanks for the suggestion Dormilich

      i'll definately look forward to it...

      thanks again.

      Comment

      • Dormilich
        Recognized Expert Expert
        • Aug 2008
        • 8694

        #4
        note of caution:
        Internet Explorer is not able to handle XHTML!!!

        Comment

        • David Laakso
          Recognized Expert Contributor
          • Aug 2008
          • 397

          #5
          Originally posted by Dormilich
          note of caution:
          Internet Explorer is not able to handle XHTML!!!
          No bone to pick, personally, but just a friendly word of caution:

          On a list or forum frequently populated by beginners and novices an explanation of that blanket statement accompanied by appropriate historical and technical resources would be a nice touch...

          Comment

          • Kate Hudson
            New Member
            • Mar 2014
            • 1

            #6
            Sorry for the late response- We must use scripting language like PHP for it to work.
            Last edited by Rabbit; Mar 3 '14, 05:04 PM. Reason: Link removed, has no bearing on question in the thread.

            Comment

            Working...