All Posts by Email, Once a Week

Media Temple logo

CSS-Tricks is brought to you in part by Media Temple, the web hosting that we both use and recommend.

Code not displaying clean in "view source"

  • # December 10, 2008 at 11:04 pm

    Hi. As my subject states, my code isn’t displaying clean when i go to view source in FF. I haven’t checked any other browsers.

    I use Dreamweaver, but only the code view. I code everything perfectly clean. I’ve only noticed this with DW, as I used to use a different editing tool.

    Any thoughts or reasons why this is happening?

    # December 11, 2008 at 9:08 am

    This reply has been reported for inappropriate content.

    dunno – I use Dreamweaver as a code editor only all the time, no problems with untidy code – it comes out exactly as I put it in…

    I know along time ago when I used DW8 it didnt do the most tidy code, but it was more down to the use of the WYSIWYG editor

    So dunno, what version are you using?

    # December 11, 2008 at 10:30 pm

    This reply has been reported for inappropriate content.

    I’m using CS3…

    Sometimes my indents aren’t lining up correctly, or separate lines will be combined into one long one.
    I tried googling a phrase on it, but nothing came up really.

    When you do your indents, do you use the indent icon or just tab the code over? I just use the tab, but I can’t imagine why that’d be a problem.

    # December 12, 2008 at 12:55 am

    This reply has been reported for inappropriate content.

    The only thing I could think of for the "separate lines will be combined into one long one" is that you never actually hit "enter" or "return" inside of DW.

    When you have the file open in DW, each line should be numbered on the left. If you have lots of text on one line (for example a wrapped in a <p> tag) it won’t count the text wrapping as a new line. Did that make sense? Here’s a screen just in case:

    My tabs don’t always line up perfectly when viewing source either, I don’t have a solution there for ya.

    # December 12, 2008 at 2:30 am

    This reply has been reported for inappropriate content.

    I’ve never seen that.. everytime I hit enter, it just keeps the number there on the left. Every single space has a number.

    Ugh, i just looked at another site I’ve almost completed and the spacing is terrible… this time a few of the div tags have roughly 6-7 tabs out from the parent tag. :<

    What I meant more about the long lines is that typically, something would look like this…


    blah blah blah

    But one of my pages I looked at literally had this…

    blah blah blah
Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.

There's a whole bunch of content on CSS-Tricks.

Search for Stuff   •   Browse the Archives

Get the Newsletter ... or get the RSS feed