Ignore:
Timestamp:
Apr 16, 2012, 5:16:27 AM (12 years ago)
Author:
rvelices
Message:

rv_gmaps - small template updates

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/rv_gmaps/trunk/map_data.php

    r13092 r14181  
    9191rvo( '{' );
    9292
    93 rvo( "\ntitle: ".jsgm_str( strip_tags(trigger_event('render_element_description', $page['title']) ) ) );
     93rvo( "\ntitle:".jsgm_str( strip_tags(trigger_event('render_element_description', $page['title']) ) ) );
    9494rvo( ",\n" );
    9595
    96 rvo( "page_url: ".jsgm_str( duplicate_index_url( array('start'=>0) ) ) );
     96rvo( "page_url:".jsgm_str( duplicate_index_url( array('start'=>0) ) ) );
    9797rvo( ",\n" );
    9898
    99 rvo( "blowup_url: ".jsgm_str( rvm_duplicate_blowup_url( array('start'=>0) ) ) );
     99rvo( "blowup_url:".jsgm_str( rvm_duplicate_blowup_url( array('start'=>0) ) ) );
    100100rvo( ",\n" );
    101101
    102 rvo( "kml_url: ".jsgm_str( rvm_duplicate_kml_index_url( array('start'=>0, 'flat'=>1) ) ) );
     102rvo( "kml_url:".jsgm_str( rvm_duplicate_kml_index_url( array('start'=>0, 'flat'=>1) ) ) );
    103103rvo( ",\n" );
    104104
    105 rvo( "nb_items: ".count($page['items']) );
     105rvo( "nb_items:".count($page['items']) );
    106106rvo( ",\n" );
    107107
    108 rvo( "bounds: " );
     108rvo( "bounds:" );
    109109if ( isset($cm) )
    110110  rvo( jsgm_bounds( $cm->bounds ) );
     
    114114
    115115
    116 rvo( "\nnb_clusters: ".count($clusters) );
     116rvo( "\nnb_clusters:".count($clusters) );
    117117rvo( "," );
    118118
    119 rvo( "\nimage_clusters: [\n" );
     119rvo( "\nimage_clusters:[\n" );
    120120$i=0;
    121121foreach( $clusters as $c )
     
    123123  if ($i) rvo( ",\n\n" );
    124124  rvo( "{" );
    125   rvo( 'position: '. jsgm_position( bounds_center($c->bounds) ) );
     125  rvo( 'position:'. jsgm_position( bounds_center($c->bounds) ) );
    126126  rvo( ",\n" );
    127   rvo( 'bounds: '. jsgm_bounds( $c->bounds ) );
     127  rvo( 'bounds:'. jsgm_bounds( $c->bounds ) );
    128128  rvo( ",\n" );
    129   rvo( 'nb_items: '.count($c->items) );
     129  rvo( 'nb_items:'.count($c->items) );
    130130  rvo( ",\n" );
    131131
    132   rvo( 'blowup_url: "'.rvm_duplicate_blowup_url(array('box'=>$c->bounds), array('start') ). '"' );
     132  rvo( 'blowup_url:"'.rvm_duplicate_blowup_url(array('box'=>$c->bounds), array('start') ). '"' );
    133133  rvo( ",\n" );
    134134
     
    138138    $c->items = array_slice($c->items, 0, $max_per_cluster);
    139139  }
    140   rvo( 'items: [' );
     140  rvo( 'items:[' );
    141141  for ($j=0; $j<count($c->items); $j++)
    142142  {
     
    157157    if ($j) rvo( "," );
    158158    rvo( "{" );
    159     rvo( "tn: ".jsgm_str( get_thumbnail_url( $img ) ) );
    160     rvo( ",name: ".jsgm_str( trigger_event('render_element_description', $title) ) );
    161     rvo( ",comment: ".jsgm_str( trigger_event('render_element_description', $img['comment']) ) );
    162     rvo( ",page_url: ".jsgm_str( $page_url ) );
     159    rvo( "tn:".jsgm_str( get_thumbnail_url( $img ) ) );
     160    rvo( ",name:".jsgm_str( trigger_event('render_element_description', $title) ) );
     161    rvo( ",comment:".jsgm_str( trigger_event('render_element_description', $img['comment']) ) );
     162    rvo( ",page_url:".jsgm_str( $page_url ) );
    163163    rvo( "}" );
    164164  }
Note: See TracChangeset for help on using the changeset viewer.