「ver4/関数リファレンス/BcBaser googleMaps」の版間の差分
提供: baserCMS公式ガイド
行46: | 行46: | ||
####コード | ####コード | ||
<syntaxhighlight lang="php"> | <syntaxhighlight lang="php"> | ||
− | + | <?php $this->BcBaser->googleMaps(array('width'=>'800', 'height'=>'600', 'zoom'=>'18')); ?> | |
</syntaxhighlight> | </syntaxhighlight> | ||
2018年1月14日 (日) 11:47時点における版
[このコンテンツは内容調整中です]
目次
説明
Google Maps を出力する。
使い方
$this->BcBaser->googleMaps([$data] , [$options] )
パラメータ
- (array) $data
- 読み込むテンプレートに引き継ぐパラメータ
- 初期値 : array()
- (string) $option
- オプション
- 初期値 : array()
- -
width
:表示するマップの幅をピクセル単位で指定(初期値 : '600') - -
height
:表示するマップの高さをピクセル単位指定(初期値 : '400') - -
zoom
:表示するマップのズーム値を指定(初期値 : '16') - -
mapId
:表示するマップのIDを指定(初期値 : 'map') - -
address
:表示位置の住所を指定(初期値 : システム設定画面で設定した住所) - -
markerText
:マーカーテキストを指定(初期値 : null) - -
longitude
:表示位置の経度を指定(初期値 : null) - -
latitude
:表示位置の緯度を指定(初期値 : null)
戻り値
なし
用例
基本
コード
<?php $this->BcBaser->googleMaps() ?>
応用
コード
<?php $this->BcBaser->googleMaps(array('width'=>'800', 'height'=>'600', 'zoom'=>'18')); ?>