Formatting HTML Source - Is there a utility?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • just say NO to PDF

    Formatting HTML Source - Is there a utility?

    Here's the scoop:

    Does anyone remember the UNIX utility "pretty" for formatting C code?

    What I'm looking for is a utility that will do two things:
    1) Format the HTML code itself to make it more readable (indentation, line
    breaks, etc.)
    2) Optimize HTML to remove empty and redundant tags

    Reason: Have you ever seen what kind of a mess you get when you paste WORD
    (or other rich text) into a HTML editor like Front Page? Answer is a "Hello,
    World" of about 50KB...

    Recognising that the two requirements are somewhat contradictory, I may need
    two utilities...are there any free ones available before I do it myself in
    PERL?

    --Maarten ( webnames.ca_NO_ SPAM_@city.rich mond.bc.ca )


  • John Bokma

    #2
    Re: Formatting HTML Source - Is there a utility?

    just say NO to PDF wrote:
    [color=blue]
    > Here's the scoop:
    >
    > Does anyone remember the UNIX utility "pretty" for formatting C code?[/color]



    John

    --
    email: mail(at)johnbok ma.com (or reply) home: http://johnbokma.com/
    UI design tips: http://johnbokma.com/websitedesign/ ~ ICQ 218175426

    @%68%65%6C%6C%6 F%2C%20%4E%6F%7 2%74%6F%6E%21

    Comment

    • Mike Novak

      #3
      Re: Formatting HTML Source - Is there a utility?


      "just say NO to PDF" <stingray_67@no _spam.hotmail.c om> wrote in message
      news:XKDRa.15$5 V2.471@news.bc. tac.net...[color=blue]
      > Here's the scoop:
      >
      > Does anyone remember the UNIX utility "pretty" for formatting C code?
      >
      > What I'm looking for is a utility that will do two things:
      > 1) Format the HTML code itself to make it more readable (indentation, line
      > breaks, etc.)
      > 2) Optimize HTML to remove empty and redundant tags
      >
      > Reason: Have you ever seen what kind of a mess you get when you paste WORD
      > (or other rich text) into a HTML editor like Front Page? Answer is a[/color]
      "Hello,[color=blue]
      > World" of about 50KB...
      >
      > Recognising that the two requirements are somewhat contradictory, I may[/color]
      need[color=blue]
      > two utilities...are there any free ones available before I do it myself in
      > PERL?
      >
      > --Maarten ( webnames.ca_NO_ SPAM_@city.rich mond.bc.ca )
      >
      >[/color]

      Try HTML-Kit




      Comment

      • Toby A Inkster

        #4
        Re: Formatting HTML Source - Is there a utility?

        On Thu, 17 Jul 2003 13:29:31 -0700, just say NO to PDF wrote:
        [color=blue]
        > What I'm looking for is a utility that will do two things:
        > 1) Format the HTML code itself to make it more readable (indentation, line
        > breaks, etc.)
        > 2) Optimize HTML to remove empty and redundant tags[/color]

        Tidy does both of these. Someone has already posted a link to the old Tidy
        site, but the newest versions can be found at http://tidy.sourceforge.net/
        [color=blue]
        > Reason: Have you ever seen what kind of a mess you get when you paste WORD
        > (or other rich text) into a HTML editor like Front Page? Answer is a "Hello,
        > World" of about 50KB...[/color]

        Tidy has special routines for dealing with the output of FrontPage, Word,
        etc...

        --
        Toby A Inkster BSc (Hons) ARCS | mailto:tobyink@ goddamn.co.uk | pgp:0x6A2A7D39
        aim:inka80 | icq:6622880 | yahoo:tobyink | jabber:tai@jabb er.linux.it
        http://www.goddamn.co.uk/tobyink/ | "You've got spam!"
        playing://(nothing)

        Comment

        • Michel

          #5
          Re: Formatting HTML Source - Is there a utility?

          try notepad.

          Nothing beats notepad when it comes to web-design....

          Michel

          "just say NO to PDF" <stingray_67@no _spam.hotmail.c om> wrote in message
          news:XKDRa.15$5 V2.471@news.bc. tac.net...[color=blue]
          > Here's the scoop:
          >
          > Does anyone remember the UNIX utility "pretty" for formatting C code?
          >
          > What I'm looking for is a utility that will do two things:
          > 1) Format the HTML code itself to make it more readable (indentation, line
          > breaks, etc.)
          > 2) Optimize HTML to remove empty and redundant tags
          >
          > Reason: Have you ever seen what kind of a mess you get when you paste WORD
          > (or other rich text) into a HTML editor like Front Page? Answer is a[/color]
          "Hello,[color=blue]
          > World" of about 50KB...
          >
          > Recognising that the two requirements are somewhat contradictory, I may[/color]
          need[color=blue]
          > two utilities...are there any free ones available before I do it myself in
          > PERL?
          >
          > --Maarten ( webnames.ca_NO_ SPAM_@city.rich mond.bc.ca )
          >
          >[/color]


          Comment

          • kchayka

            #6
            Re: Formatting HTML Source - Is there a utility?

            John Bokma wrote:
            [color=blue]
            > Toby A Inkster wrote:
            >[color=green]
            >> On Fri, 18 Jul 2003 00:32:36 +0200, Michel wrote:
            >>[color=darkred]
            >>>Nothing beats notepad when it comes to web-design....[/color]
            >>
            >> Yeah, it does:
            >>
            >> http://www.nedit.org/[/color]
            >
            > Texpad (http://www.textpad.com/ ) is cool too.[/color]

            Nah, Crimson Editor is better than textpad any day. :)
            <URL:http://crimsoneditor.c om/>

            --
            To email a reply, remove (dash)ns(dash). Mail sent to the ns
            address is automatically deleted and will not be read.

            Comment

            • Jim Royal

              #7
              Re: Formatting HTML Source - Is there a utility?

              In article <bf7864$4q4$1@n ews.cistron.nl> , Michel
              <webmaster@hand leiding-online-nospam-aub.nl> wrote:
              [color=blue]
              > try notepad.
              >
              > Nothing beats notepad when it comes to web-design....[/color]

              BBEdit.

              'Nuff said.

              --
              Jim Royal
              "Understand ing is a three-edged sword"

              Comment

              • John

                #8
                Re: Formatting HTML Source - Is there a utility?

                In article <1058488673.699 918@halkan.kabe lfoon.nl>,
                postmaster@cast leamber.com says...[color=blue]
                > Toby A Inkster wrote:
                >[color=green]
                > > On Fri, 18 Jul 2003 00:32:36 +0200, Michel wrote:
                > >
                > >[color=darkred]
                > >>Nothing beats notepad when it comes to web-design....[/color]
                > >
                > >
                > > Yeah, it does:
                > >
                > > http://www.nedit.org/
                > >[/color]
                >
                > Nirvana rocks :-)
                >
                > Texpad (http://www.textpad.com/ ) is cool too. I like the clip library
                > and the tabbed interface.
                >
                > John[/color]

                There are also dandy macros you can add to TextPad, and when you add Tidy
                to the Tools menu, what more could you want?

                (another) John
                _______________ _______________ _______________ __
                C'est la vie! C'est la guerre! Say no more!

                Comment

                • Arve Bersvendsen

                  #9
                  Re: Formatting HTML Source - Is there a utility?

                  John Bokma wrote in news:1058474495 .743828@halkan. kabelfoon.nl:
                  [color=blue]
                  > http://www.w3.org/People/Raggett/tidy/[/color]

                  Tidy now lives at <URL:http://tidy.sourceforg e.net/>

                  (And for prettyprinting of HTML, there's not much that beats tidy).

                  --
                  Arve | http://www.bersvendsen.com/ | http://www.virtuelvis.com/

                  Lyd i nettbasert reklame? Nei takk!

                  Comment

                  • Lars G. Svensson

                    #10
                    Re: Formatting HTML Source - Is there a utility?

                    On Thu, 17 Jul 2003 13:29:31 -0700, just say NO to PDF
                    <stingray_67@no _spam.hotmail.c om> wrote:
                    [color=blue]
                    > What I'm looking for is a utility that will do two things:
                    > 1) Format the HTML code itself to make it more readable (indentation,
                    > line
                    > breaks, etc.)
                    > 2) Optimize HTML to remove empty and redundant tags[/color]
                    JEdit <http://www.jedit.org> with XML/HTML and JTidy plugins. Requires
                    Java, though.

                    --
                    Lars

                    Comment

                    • Brian

                      #11
                      Re: Formatting HTML Source - Is there a utility?

                      kchayka wrote:[color=blue][color=green]
                      >>Texpad (http://www.textpad.com/ ) is cool too.[/color][/color]

                      That's a new one for me.
                      [color=blue]
                      > Nah, Crimson Editor is better than textpad any day. :)
                      > <URL:http://crimsoneditor.c om/>[/color]

                      I tried that. The context highlighting, with different colors, was
                      great. But I couldn't live w/out my clip libraries in NoteTab, so I
                      went back. Does Crimson have anything like that?

                      --
                      Brian
                      follow the directions in my address to email me

                      Comment

                      • Leonard Blaisdell

                        #12
                        Re: Formatting HTML Source - Is there a utility?

                        In article <18072003002621 2115%jimroyal@c anada.com>, noone@nowhere.c om wrote:
                        [color=blue]
                        > BBEdit.
                        >
                        > 'Nuff said.[/color]

                        Amen old Mac buddy! I can't speak for any of the PC world programs, but I
                        can't imagine a better text editor. What would it do that BBEdit can't?

                        leo

                        --
                        <http://web0.greatbasin .net/~leo/>

                        Comment

                        • Ian Rastall

                          #13
                          Re: Formatting HTML Source - Is there a utility?

                          On Fri, 18 Jul 2003 10:36:46 +0200, Stephen Poley <sbpoley@xs4all .nl>
                          wrote:
                          [color=blue]
                          >NoteTab is pretty good - and the Light version is free.[/color]

                          NoteTab Pro is pretty much what my world revolves around. Tidy is
                          integrated too, which is nice.

                          Ian
                          --

                          A curated library of public domain literature.

                          Comment

                          • Lauri Raittila

                            #14
                            Re: Formatting HTML Source - Is there a utility?

                            In article <leo-180703013249000 1@leosmac.spark s.nv.us>, Leonard Blaisdell
                            wrote:
                            [color=blue]
                            > What would it do that BBEdit can't?[/color]

                            I don't know. But I bet emacs can do that.

                            --
                            Lauri Raittila <http://www.iki.fi/lr> <http://www.iki.fi/zwak/fonts>
                            Saapi lähettää meiliä, jos aihe ei liity ryhmään, tai on yksityinen
                            tjsp., mutta älä lähetä samaa viestiä meilitse ja ryhmään.

                            Comment

                            • Michel

                              #15
                              Re: Formatting HTML Source - Is there a utility?

                              Exactly my point

                              And you're the only one yet to see it.

                              Regards,

                              Michel


                              Comment

                              Working...