logo       
Google Custom Search
    AddThis Social Bookmark Button

Re: CGI::App & CGI:Ajax nearly working - please help with last bit: msg#00093

Subject: Re: CGI::App & CGI:Ajax nearly working - please help with last bit
Bruce McKenzie wrote:

Your "corresponding" javascript func must send the string to some target div or else handle it with another function (a callback) that will manipulate it further.
I know, I didn't show all the code as I thought it would make the message unnecessarily long. The validate_nhsno sub that does the validation (and I know works properly) is registered to CGI::Ajax as:
my $pjx = new CGI::Ajax( validate_nhsno => \&validate_nhsno );

The template contains the target div, also not shown earlier but basically:
<p><input type="text" id="nhsno" onchange="validate_nhsno(['nhsno'], ['bad_nhsno']); return true;"><b id="bad_nhsno"></b></p>

The fact that I get the validation output in the div:
Content-Type: text/html; charset=ISO-8859-1 invalid NHSNo!
means the system is working, but I cannot find a way of preventing the 'Content-Type: text/html; charset=ISO-8859-1' header appearing. Or have I misunderstood your reply? It's most frustrating as I felt I was close to success, but now feel it's slipping away.
--
Richard Jones
Leeds, UK
mailto:ra.jones@xxxxxxxxxxxxxxx

---------------------------------------------------------------------
Web Archive:  http://www.mail-archive.com/cgiapp@xxxxxxxxxxxxxxxxx/
             http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: cgiapp-unsubscribe@xxxxxxxxxxxxxxxxx
For additional commands, e-mail: cgiapp-help@xxxxxxxxxxxxxxxxx





Try Searching:
servers, voip, java, networking, microsoft ...
<Prev in Thread] Current Thread [Next in Thread>