Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??
First I think that yoou should make sure that your hash is populated
(something that you've probably done :p )
Anyway I thing that the best method is to put some warnings during the processing
in order to make sure that it is processed correct.
Anyway another good practice is to send the html to a variable and then print it.
It avoid to have the page breaked in the middle when an error occurs.
Generally we would like to use something like this:
my $html = qq {<SELECT NAME="partNumber" SIZE="1" >}; foreach my $key (sort keys %{$HASHDATAFROMLIBRARYFILE{TIMING}}) { #my $p = \%{$rpt{$HASHDATAFROMLIBRARYFILE}{TIMING}{$key}}; warn "\n Here we are $key "; # just to make sure it is executed $text .= qq { $html .= qq { <OPTION VALUE='$keys' @{[ ( ( defined($rpt{PART_NUMBER}) ) && ($FORM{CellName} eq $keys ) ) ? 'SELECTED' : '' ]} >$keys</OPTION> }; }

I hope it could help you.

In reply to Re: Problems Processing Hash within Cgi Script by r34d0nl1
in thread Problems Processing Hash within Cgi Script by EchoAngel

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



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.
  • Log In?
    Username:
    Password:

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

    How do I use this? | Other CB clients
    Other Users?
    Others romping around the Monastery: (4)
    As of 2019-12-15 01:59 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?

      No recent polls found

      Notices?