none
MOSS 2007 problem with adding DOCTYPE in master page

    Question

  • Hi,
         I have added a web part containing a modal pop up in the master page global navigation menu (Menu containing welcome,my site etc). Webpart added successfully but when i click on it, a pop up gets open and whole structure of the page changes (horizontal scroll,vertical scrolls, background opaque etc) which is not intended.
    Now when i add the doctype tag in the master page (<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">) or any other type of DOCTYPE tag for that matter, the pop up works absolutely fine but the height of the page is reduced upto the level of webparts. So if there are no webparts , the page is as good as collapsed.
    Is there any workaround other than fixing the height of some webparts or table ?

    Thanks in advance.

    Ajit


    http://www.sharepointkings.com
    Friday, July 24, 2009 7:21 AM

All replies

  • What browser are you experiencing this in?

    I'm guessing the DOCTYPE causes the browser to kick out of quirks mode and into alternate standards mode, which I've noticed in some cases screws with Sharepoints lovely table structured layouts. So basicaly you have three choices:

    1. Don't use a DOCTYPE
    2. Edit the master page and fix the code that breaks when the DOCTYPE is added, probably some sort of table or tablerow height property
    3. Use a different DOCTYPE that doesn't trigger Alternate Standards mode (like <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">)

    Other than that I'm not sure what else to suggest.


    Facts are meaningless. You could use facts to prove anything that's even remotely true!
    Friday, July 24, 2009 2:49 PM
  • I am experiencing it in IE 7.

    Well i have to use DOCTYPE only because the page is looking weird without it.
    I tried using all types of DOCTYPE but result is same.
    I cannot fix the height of the table as it will give rise to other problems.

    I hope there must be some solution.

    Thanks

    Ajit
    http://www.sharepointkings.com
    Monday, July 27, 2009 11:21 AM
  • I do not understand why you need “DOCTYPE” in the page, since it’s not an HTML tag and its only purpose is to instruct the browser what version of the markup language the page is written in.

     

    To control the position of modal window is extremely delicate, you can use some tools in debugging this issue.

    For IE: IE Debugging Tools

    For Firefox: Firebug


    Keep It Simple and Stupid.
    Tuesday, July 28, 2009 4:20 AM
  • Hi Charlie,
                    I am using "DOCTYPE" in the page because without it the page is looking weird as i wrote in my last reply. As soon as the modal pop up opens the page structure changes abruptly and nothing is visible on the page. Horizontal and vertical scrolls are introduced and background grays out.


    Ajit
    http://www.sharepointkings.com
    Wednesday, July 29, 2009 10:29 AM