Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
flags.phtml
Go to the documentation of this file.
1 <?php
7 // @codingStandardsIgnoreFile
8 
9 // @deprecated
10 ?>
11 <?php if (count($block->getStores())>1): ?>
12 <div class="form-language">
13  <label for="select-language"><?= $block->escapeHtml(__('Your Language:')) ?></label>
14  <select id="select-language" title="<?= $block->escapeHtmlAttr(__('Your Language')) ?>" onchange="window.location.href=this.value" class="flags">
15  <?php foreach ($block->getStores() as $_lang): ?>
16  <?php $_selected = ($_lang->getId() == $block->getCurrentStoreId()) ? ' selected="selected"' : '' ?>
17  <option value="<?= $block->escapeUrl($_lang->getCurrentUrl()) ?>" style="background-image:url('<?= $block->escapeUrl($block->getViewFileUrl('images/flags/flag_' . $_lang->getCode() . '.gif')) ?>');"<?= /* @noEscape */ $_selected ?>><?= $block->escapeHtml($_lang->getName()) ?></option>
18  <?php endforeach; ?>
19  </select>
20 </div>
21 <?php endif; ?>
$block setTitle( 'CMS Block Title') -> setIdentifier('fixture_block') ->setContent('< h1 >Fixture Block Title</h1 >< a href=" store url</a><p> Config value
Definition: block.php:9
__()
Definition: __.php:13
$block
Definition: block.php:8
endif
Definition: flags.phtml:21
if(count( $block->getStores())>1)(__( 'Your Language:')) ?></label >< select id $_selected endforeach
Definition: flags.phtml:17