當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Grid::display_grid方法代碼示例

本文整理匯總了PHP中Grid::display_grid方法的典型用法代碼示例。如果您正苦於以下問題:PHP Grid::display_grid方法的具體用法?PHP Grid::display_grid怎麽用?PHP Grid::display_grid使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Grid的用法示例。


在下文中一共展示了Grid::display_grid方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: get_component

 public static function get_component($component, $data)
 {
     $display = "";
     switch ($component) {
         case 'carousel':
             $display .= Carousel::display_carousel($data, true);
             break;
         case 'grid':
             $display .= Grid::display_grid($data, true);
             break;
         case 'card':
             $display .= Card::display_card_simple($data, true);
             break;
         case 'button':
             $display .= Button::display_buttons($data, true);
             break;
         case 'masonry':
             $display .= Masonry::display_masonry($data, true);
             break;
         case 'flex-layout':
             $display .= Freewall::display_flex_layout($data, true);
             break;
         case 'windows':
             $display .= Freewall::display_win8_layout($data, true);
             break;
         case 'img-layout':
             $display .= Freewall::display_image_layout($data, true);
             break;
         case 'pinterest':
             $display .= Freewall::display_pinterest_layout($data, true);
             break;
         default:
             $display .= Grid::display_grid($data, true);
             break;
     }
     return $display;
 }
開發者ID:gabzon,項目名稱:experiensa,代碼行數:37,代碼來源:showcase.php

示例2:

                Masonry::display_masonry($countries);
                break;
            case 'flex-layout':
                Freewall::display_flex_layout($countries);
                break;
            case 'windows':
                Freewall::display_win8_layout($countries);
                break;
            case 'img-layout':
                Freewall::display_image_layout($countries);
                break;
            case 'pinterest':
                Freewall::display_pinterest_layout($countries);
                break;
            default:
                Grid::display_grid($countries);
                break;
        }
        ?>
        </div>
    <?php 
    } else {
        ?>
        <h3><?php 
        _e('Sorry! Currently there are no promotions', 'sage');
        ?>
</h3>
    <?php 
    }
    ?>
</div>
開發者ID:gabzon,項目名稱:experiensa,代碼行數:31,代碼來源:promotions.php

示例3:

                Masonry::display_masonry($themes);
                break;
            case 'flex-layout':
                Freewall::display_flex_layout($themes);
                break;
            case 'windows':
                Freewall::display_win8_layout($themes);
                break;
            case 'img-layout':
                Freewall::display_image_layout($themes);
                break;
            case 'pinterest':
                Freewall::display_pinterest_layout($themes);
                break;
            default:
                Grid::display_grid($themes);
                break;
        }
    } else {
        ?>
                <h3><?php 
        _e('Sorry! Currently there are no themes', 'sage');
        ?>
</h3>
                <?php 
    }
    ?>
            <br>
            <br>
        </div>
    </div>
開發者ID:gabzon,項目名稱:experiensa,代碼行數:31,代碼來源:themes.php

示例4:

                Masonry::display_masonry($locations);
                break;
            case 'flex-layout':
                Freewall::display_flex_layout($locations);
                break;
            case 'windows':
                Freewall::display_win8_layout($locations);
                break;
            case 'img-layout':
                Freewall::display_image_layout($locations);
                break;
            case 'pinterest':
                Freewall::display_pinterest_layout($locations);
                break;
            default:
                Grid::display_grid($locations);
                break;
        }
    } else {
        ?>
                <h3><?php 
        _e('Sorry! Currently there are no destinations', 'sage');
        ?>
</h3>
                <?php 
    }
    ?>
        </div>
        <br>
        <br>
        <br>
開發者ID:gabzon,項目名稱:experiensa,代碼行數:31,代碼來源:destinations.php

示例5: get_option

<?php

$agency_settings = get_option('agency_settings');
$display_partners = isset($agency_settings['setting_partners_display']) ? $agency_settings['setting_partners_display'] : 'FALSE';
$partners = isset($agency_settings['agency_partners']) ? $agency_settings['agency_partners'] : array();
if ($display_partners == 'TRUE' && !empty($partners) && !empty($partners[0]['partner_name'])) {
    ?>
<section id="promotion" class="ui basic vertical segment center aligned">
    <br><br>
    <div class="ui container">
        <h1><?php 
    _e('Our Partners', 'sage');
    ?>
</h1><br>
    </div>
    <?php 
    foreach ($partners as $partner) {
        $info['title'] = $partner['partner_name'];
        $info['subtitle'] = '';
        $info['post_link'] = !empty($partner['partner_website']) ? $partner['partner_website'] : '#';
        $info['image_url'] = wp_get_attachment_url($partner['partner_logo'][0]);
        $info['thumbnail_url'] = !empty($partner['partner_logo'][0]) ? wp_get_attachment_thumb_url($partner['partner_logo'][0]) : '';
        $info['show_thumbnail'] = true;
        $partner_list[] = $info;
    }
    Grid::display_grid($partner_list);
    ?>
</section>
<?php 
}
開發者ID:gabzon,項目名稱:experiensa,代碼行數:30,代碼來源:partners.php


注:本文中的Grid::display_grid方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。