Hi,

I'm a perl-beginner. I'm working at a project where I read data from a db and generate a html page with the results using print "<htmlcode>". Testing with apache2.

Now my boss wants to have some functions like drop-down boxes and stuff to make using my page more compfortable - and he wants me to use jquery for that.

Ok after reading and trying out some tutorials I can use a little jquery on a html page and I can use some perl to get the data. But how do I use both on the same page? I googled for an example but all of them were too complicated for me.

Do I also have to "print" the jQuery functions with perl and where do i put that jquery.js file so the generated html page finds it? Or is there any other way to mix them up? And is there a BETTER way to make a html page with perl without having to print every line? I've read something about html::template but couldn't figure out how it works on my own.

I'm asking for a very simple example of a html page using perl to get some data and jquery to display it. Is there a SIMPLE example you can give me or a link with a BEGINNERS guide?

Please help me. Normally I'm programming java and now all of a sudden i got this really big project with html/css(never used before) and perl(used once in university) and jquery (never even heard of before). Perl seems interesting but is so different from everything I did before...


In reply to How do I mix up Perl and jQuery (for beginners) by eyekona

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, details, 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, summary, 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.