HandyKit v2.1  

 Online
 Index page
 HowTo

HandyKIT packages

 HandyCGI.pm
 HandyList.pm
 HandyMail.pm
 HandyTemplate.pm
 HandyTextDB.pm
 SiteBag.pm

Other packages

 HandySQL.pm
 HandyLog.pm
 HandyCrypt.pm

 

HOWTO

Please, read carefully how templates are working in HandyTemplate module docs.

How do I put a subscribe newsletter box ?

Here's the example form:

<form method="post" action="&baseurl;">
<input type="text" name="email" value="&email;">
<input type="text" name="fullname" value="&fullname;">
<input type="submit" name="subscribe" value=" SUBSCRIBE ">
</form>

It's simple and self-explanatory!

But two template files MUST exists - subscribe.msg and unsubscribe.msg that are sent, when user has subscriben or unsubscriben.

How do I put a poller on page?

  1. Set variable pollers to the list of names of pollers that will be used on this page, for example &vars{pollers}{index,smart} (be sure, that their definition exists in pollersfile).

  2. Set variables poller_NAME_voted, poller_NAME_notvoted, poller_NAME_answer_fmt, where NAME corresponds to names of active pollers.

    a)
    poller_NAME_voted and poller_NAME_notvoted has same structure of replaces, but poller_NAME_voted is shown only when user has pressed on 'VOTE' button. Inside of this variable following entities will be replaced:
    &poller; => poller NAME
    &poller_question; => question in poller
    &poller_answers; => answers in poller

    (poller_answers are formatted using poller_NAME_answer_fmt variable and then concatenated)
    b)
    poller_NAME_answer_fmt replaces:
    &row; => number of question
    &voteid; => ID of this vote
    &answer; => answer
    &votes; => votes for this answer
    &total; => total votes in poller

  3. Well done, now try to test that poller. The request to vote should contain only two parameters - poller=NAME_OF_POLLER;vote=VOTEID

How do I put a counter on page?

Use following replaces:
&counter_total_hits; total number of hits
&counter_hits; hits for this page
&counter_total_hosts; total number of unique hosts
&counter_hosts; total number of unique hosts for this page
&counter_total_started; when total counter was reset
&counter_started; when counter for this page was started
&counter_total_ins; total number of ins
&counter_ins; total number of ins to this page
&counter_total_outs; total number of outs
&counter_outs; total number of outs from this page

How do I put a banner on page?

Simply - prepare block of banners. And then use &banner_small; for example, where small block represents banners size 100x64. The banner block is prepared via admininterface (coming soon!) or directly by use of HandyTextDB module for altering adsfile.

How do I put a list of links on page?

Simply - prepare block of links. And then use &links_intro; for example, where intro block represents some introductory links... The link block is prepared via admininterface (coming soon!) or directly by use of HandyTextDB module for altering adsfile.




TOP
© 2000 || Perl4YOU.com E-mail: info@perl4you.com