OneDreamCloser has asked for the wisdom of the Perl Monks concerning the following question:
and returns : "No head/html tags, nowhere to insert. Returning javascript anyway" how can i overcome this problem ? what is the cause of it ? thank you#!/usr/bin/perl -wT use strict ; use warnings ; use diagnostics ; use CGI ; use CGI::Ajax ; print "Content-type: text/html \n\n"; sub initialize_html { my $html = <<HTML ; <!DOCTYPE html> <html> <head> <meta name="viewport" content="initial-scale=1.0, user-scalable=no +"/> <meta http-equiv="content-type" content="text/html; charset=UTF-8" +/> <style type="text/css"> html { height: 100% } body { height: 100%; margin: 0px; padding: 0px } label { font-size:9px; text-align:center; color:#222; text- +shadow:0 0 5px #fff; font-family:Helvetica, Arial, sans-serif; } #map_canvas { height: 100% } </style> <title>network_weathermap</title> <script type="text/javascript" src="http://maps.google.com/maps/ap +i/js?sensor=false"></script> <script type="text/javascript" src="js/network_weathermap.js"></sc +ript> </head> <body> <div id="map_canvas"></div> </body> </html> HTML print $html . "\n" ; } #initialize_html() ; sub parameterize_info_window { return "CGI \n" ; } my $cgi = new CGI() ; my $ajax = new CGI::Ajax( describeInfoWindow => \¶mete +rize_info_window) ; print $ajax->build_html($cgi, \&initialize_html) ; $ajax->JSDEBUG( 1 ) ;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: CGI ... newbie
by wind (Priest) on Apr 11, 2011 at 05:08 UTC | |
|
Re: CGI ... newbie
by Anonymous Monk on Apr 10, 2011 at 22:37 UTC | |
|
Re: CGI ... newbie
by locked_user sundialsvc4 (Abbot) on Apr 11, 2011 at 04:34 UTC | |
by Anonymous Monk on Apr 11, 2011 at 04:37 UTC |