Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic

Comment on

( #3333=superdoc: print w/replies, xml ) Need Help??

Your requirements are simply enough to use just a plain old CGI script, i.e. one Perl script either renders the page with the input/upload fields or, if input has been made, use your calculator to process the input and render the results page.
This is not the most modern way of web programming but it's still good enough for a one-page-process-one-thing site like yours and it's also a good way of getting into web programming without having to learn an entire framework.

Get started here. There is a section describing how to handle file uploads but to get started I would leave that and get it to work with a simple text field for pasting the protein sequence. Once you have cracked that it will be easy enough to add on handling of an uploaded file.

In the end a CGI script is nothing magical, except that your web server must be configured to use it. It's just another Perl script that is run by your web server if someone visits your web site. All it does is to print text (the html of the web page) that is sent to the browser of the site visitor. So you need to write a script that checks if there is user input and then either prints the html for the page with the input forms or it prints the results page (or adds a results section to the page with the input forms. The perldoc explains all about getting user input but it's worth learning a little bit about how browsers and servers communicate with each other and what GET and POST requests are.

In reply to Re^3: Interface creation by tospo
in thread Interface creation by yuvraj_ghaly

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?

    What's my password?
    Create A New User
    and all is quiet...

    How do I use this? | Other CB clients
    Other Users?
    Others perusing the Monastery: (3)
    As of 2018-05-21 23:06 GMT
    Find Nodes?
      Voting Booth?