/[maps]/web/googlemap.cgi
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /web/googlemap.cgi

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 15 by dpavlin, Mon Dec 3 14:47:08 2007 UTC revision 19 by dpavlin, Mon Dec 3 19:16:55 2007 UTC
# Line 30  my $head = ''; Line 30  my $head = '';
30  my $html = join('', qq{  my $html = join('', qq{
31  <h1>Select GPS NMEA dump</h1>  <h1>Select GPS NMEA dump</h1>
32          },          },
33          $q->start_form,          $q->start_form( -id => 'trace_frm' ),
34          $q->popup_menu(          $q->popup_menu(
35                  -name => 'trace',                  -name => 'trace',
36                  -values => [                  -values => [
# Line 41  my $html = join('', qq{ Line 41  my $html = join('', qq{
41                                  (stat("$trace_path/$a"))[10] <=> (stat("$trace_path/$b"))[10]                                  (stat("$trace_path/$a"))[10] <=> (stat("$trace_path/$b"))[10]
42                          } @traces                          } @traces
43                  ],                  ],
44                    -onChange => 'trace_frm.submit()',
45          ),          ),
46          $q->submit( -value => 'Show trace' ),          $q->submit( -value => 'Show trace' ),
47          $q->end_form,          $q->end_form,
# Line 74  if ( my $trace = $q->param('trace') ) { Line 75  if ( my $trace = $q->param('trace') ) {
75          }          }
76          close($fh);          close($fh);
77    
78          #$map->zoom(10);          if ( $points > 0 ) {
         #$map->v2_zoom(0);  
         $map->controls("large_map_control", "map_type_control");  
         $map->map_type('hybrid');  
79    
80          my ( $map_div, $map_script );                  #$map->zoom(10);
81          ( $head, $map_div, $map_script ) = $map->render;                  #$map->v2_zoom(0);
82                    $map->controls("large_map_control", "map_type_control");
83                    $map->map_type('hybrid');
84    
85          $html .= join('', qq{                  my ( $map_div, $map_script );
86                    ( $head, $map_div, $map_script ) = $map->render;
87    
88                    $html .= join('', qq{
89  <h1>Plotting $points points from }, $q->param('trace'), qq{</h1>  <h1>Plotting $points points from }, $q->param('trace'), qq{</h1>
90  $map_div  $map_div
91  $map_script  $map_script
92  <a href="http://aprs.gids.nl/nmea/">GPS - NMEA sentence information</a>  <a href="http://aprs.gids.nl/nmea/">GPS - NMEA sentence information</a>
93          });                  });
94            
95            } else {
96                    $html .= '<em>No points found for ' . $q->param('trace') . '</em>';
97            }
98    
99  }  }
100    

Legend:
Removed from v.15  
changed lines
  Added in v.19

  ViewVC Help
Powered by ViewVC 1.1.26