Re: HELP! Perl&CGI problem




"yoyo" <thenewmcy@xxxxxxxxx> wrote in message
news:1165005776.835882.45230@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi I am new at Perl and trying to create a small Hangman game.


http://verycoldice.tripod.com/cgi-bin/index2.cgi
(don't mind the labels in the table ->name, price,box)

Here's my problem exactly: Everytime the user types in a guess, it
refreshes the webpage and it generates a new random word from my array.
Obviously, I want to disable that and want the random word to stay the
same.


I tried to achieve this with a "do{ ... } while ( ... ); ", but it
doesn't seeem to work.
I believe it's the way I send my GET/POST request.



Shall you want to take a look at my code, I can post it as well.

Joey


If it refreshes the webpage then I guess no parameters are being kept.

use CGI;
my $word=param('word');
this will pick up the 'word' from the form.

Either as <input type='text' name='word' value='$word'></input> or whatever
or <input type='hidden' name='word' value='$word'></input>

Regards
John



--------------------------------------------------------------------------------
I am using the free version of SPAMfighter for private users.
It has removed 99008 spam emails to date.
Paying users do not have this message in their emails.
Try SPAMfighter for free now!


.



Relevant Pages

  • Webpage reloads automatically
    ... While viewing a webpage it refreshes by itself and I must scroll back down to ... the section I was reading. ... I have opened internet options in control panel>general ...
    (microsoft.public.windows.inetexplorer.ie6.browser)
  • Saving text entered on textbox before page refreshes itself
    ... I have a aspx webpage that gets new records on the database at pre- ... the web page refreshes itself when its time to ... textbox are lost, it did not get sent to the server when the client ...
    (microsoft.public.vstudio.development)
  • HTML Refreshing Problem with Meta Tags, Anchors, Commas, Semicolons
    ... The meta tag I have defined in the header of the page is listed below: ... continually refreshes but never recongnizes the anchor tag. ... I would like for the webpage to continually refresh at the ...
    (comp.infosystems.www.authoring.html)
  • Some help with scrollTo please?
    ... It's just that I found a program/script that will refresh a webpage ... for it to scroll down about 3 or 4 clicks OR I can scroll it down my ... self but when it refreshes it goes down to the point I was at. ...
    (comp.lang.javascript)