Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
I'm curious as to what other people do when it comes to generating complex pages of HTML from a perl script.

My typical method is that I design the web pages in HotMetal, and use a super-classed version of the HTML::Parser module that does variable substitution (and more) for all the dynamic stuff.

I look at a page like the main page of the Monastery, or SlashDot, and wonder how it's managed. I'm familiar with the CGI module, but formatting the perl source so that it's readable has always been a problem. I prefer my HTML indented, to the effect of:

<table ...> <tr> <td><p>This is some text</p></td> </tr> </table>

I have yet to find a way of formatting that in perl that allows me to understand at a glance how the page is going to look. I also know that I can use some of the "fancy" (read: highly compressed) formatting as shown in the CGI.pm docs, but I don't consider that maintainable (from the standpoint of not using the CGI module everyday, and coming back to it in a few months).

I'm proficient enough in HTML, but I don't want to "think" about writing in HTML. I'd rather "think" about my writing in Perl. This is why I use pages that I can design (and others can edit) in an HTML editor.

So, monks, friars, saints, and the lot of you, what's your opinion? How do you manage your massive amounts of HTML?

--Chris

In reply to Managing large CGI pages by jcwren

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (5)
As of 2024-04-16 04:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found