1. #1
    Sencha User
    Join Date
    Apr 2012
    Posts
    33
    Vote Rating
    0
    wiwi is on a distinguished road

      0  

    Default Hello

    Hello


    I'm trying to display a marker within a map, in my panel, but it doesn't shows up , here is my code :

    Ext.setup(
    {
    onReady: function(){
    var pnl = new Ext.Panel({
    layout:'fit',
    fullscreen:true,
    dockedItems:[
    {
    dock:'top',
    xtype:'toolbar',
    title:'Simple map',
    }
    ],
    items:[{
    xtype:'map',
    getLocation:true,
    markers: [{
    'lat': 42.339641,
    'long': -71.094224,
    marker: {title: 'Boston Museum of Fine Arts'}
    }]
    }
    ]
    })
    }
    });

    have you ever try to do the same thing as here?

  2. #2
    Sencha - Sales Team daniel.gallo's Avatar
    Join Date
    Apr 2009
    Location
    Bath, UK
    Posts
    50
    Vote Rating
    8
    daniel.gallo will become famous soon enough

      0  

    Default


    In the future, please remember to post your code using CODE tags.

    The following example should work for you. I've usually used the "maprender" listener to add markers after the render of the map.

    Code:
    Ext.setup
    ({
        onReady: function()
        {
            var pnl = new Ext.Panel
            ({
                layout:'fit',
                fullscreen:true,
                dockedItems:
                [{
                    dock:'top',
                    xtype:'toolbar',
                    title:'Simple map',
                }],
                items:
                [{
                    xtype:'map',
                    mapOptions: 
                    {
                         zoom: 12,
                         center: new google.maps.LatLng(42.339641, -71.094224) 
                     },
                    listeners: 
                    {
                        maprender: function(mapcomp, map)
                        {
                            var marker = new google.maps.Marker
                            ({
                                position: new google.maps.LatLng(42.339641, -71.094224),
                                map: map,
                                title: "Boston Museum of Fine Arts"
                            });
                        }
                    }
                }]
            })
        }
    });
    Daniel Gallo
    Sales Engineer EMEA
    Sencha UK Ltd

  3. #3
    Sencha User
    Join Date
    Apr 2012
    Posts
    33
    Vote Rating
    0
    wiwi is on a distinguished road

      0  

    Default


    Sorry for the code tags, and Thank you very much, now it is working very well !!

Thread Participants: 1

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi