skeeks/cms-ya-map

Виджеты для работы с yandex картами

Installs: 356

Dependents: 2

Suggesters: 0

Stars: 1

Watchers: 2

Forks: 1

Type:yii2-extension

1.1.0.1 2019-06-20 13:03 UTC

README

##SkeekS CMS Marketplace

http://marketplace.cms.skeeks.com/solutions/instrumentyi/razrabotchiku/228-cms-ya-map

##Exemples

simple

<?= \skeeks\cms\ya\map\widgets\YaMapWidget::widget([
    'options' =>
    [
        'class' => 'sx-map'
    ]
]) ?>

or

<? $yaMap = \skeeks\cms\ya\map\widgets\YaMapWidget::begin([
    'options' =>
    [
        'class' => 'sx-map'
    ]
]) ?>
    <? $yaMap->setZoom(5)->setCenter(); ?>
<? \skeeks\cms\ya\map\widgets\YaMapWidget::end() ?>

advanced

<? $yaMap = \skeeks\cms\ya\map\widgets\YaMapWidget::begin([
    'options' =>
    [
        'class' => 'sx-map'
    ],
    'clientOptions' =>
    [
        'onReady' => new \yii\web\JsExpression(<<<JS
            function(e, YaMap){
                console.log(YaMap);
            }
JS
)
    ],
]) ?>
    <? $yaMap->setZoom(5)->setCenter(); ?>
<? \skeeks\cms\ya\map\widgets\YaMapWidget::end() ?>

skeeks! SkeekS CMS (Yii2) — быстро, просто, эффективно! skeeks.com | cms.skeeks.com | marketplace.cms.skeeks.com