<div class="panel-body">Panel #1</div> </div> </div> <div class="col-sm-4"> <div class="panel panel-default"> <div class="panel-body">Panel #2</div> </div> </div> <div class="col-sm-4"> <div class="panel panel-default"> <div class="panel-body">Panel #3</div> </div> </div> </div>'], ['name' => 'Complex row of panels', 'description' => 'You can specify custom options which will be added to the panel row’s <code>div</code> tag.', 'php_code' => "echo BootHelp::panel_row(['column_class'=>'col-sm-6', 'id'=>'panel_row', 'class'=>'en', 'data-js'=>1], function(){\n return [\n BootHelp::panel('John Smith', ['title'=>'User', 'context'=>'info']),\n BootHelp::panel(['title'=>'Phone'], function(){\n return BootHelp::icon('earphone') . ' 323-555-5555';\n })\n ];\n});", 'result' => BootHelp::panel_row(['column_class' => 'col-sm-6', 'id' => 'panel_row', 'class' => 'en', 'data-js' => 1], function () { return [BootHelp::panel('John Smith', ['title' => 'User', 'context' => 'info']), BootHelp::panel(['title' => 'Phone'], function () { return BootHelp::icon('earphone') . ' 323-555-5555'; })]; }), 'html_code' => '<div data-js="1" class="en row" id="panel_row"> <div class="col-sm-6"> <div class="panel panel-info"> <div class="panel-heading"> <h3 class="panel-title">User</h3> </div> <div class="panel-body"> John Smith </div> </div> </div> <div class="col-sm-6"> <div class="panel panel-default"> <div class="panel-heading">
<div class="panel-body">You accepted the Terms of service.</div> <div class="panel-footer">Pay attention to this!</div> </div>'], ['name' => 'Panel with title', 'description' => 'Use the <code>title</code> options to display a title above the panel.', 'php_code' => "echo BootHelp::panel('You accepted the Terms of service.', ['title'=>'Congratulations']);", 'result' => BootHelp::panel('You accepted the Terms of service.', ['title' => 'Congratulations']), 'html_code' => '<div class="panel panel-default"> <div class="panel-heading"> <h3 class="panel-title">Congratulations</h3> </div> <div class="panel-body"> You accepted the Terms of service. </div> </div>'], ['name' => 'Contextual panels', 'description' => 'Set the <code>"context"</code> option to change the color (and semantic context) of the panel. Available contexts are <code>"default"</code> (default), <code>"primary"</code>, <code>"success"</code>, <code>"info"</code>, <code>"warning"</code> and <code>"danger"</code>.', 'php_code' => "echo BootHelp::panel('You accepted the Terms of service.', ['title'=>'Thanks', 'context'=>'success']);", 'result' => BootHelp::panel('You accepted the Terms of service.', ['title' => 'Thanks', 'context' => 'success']), 'html_code' => '<div class="panel panel-success"> <div class="panel-heading"> <h3 class="panel-title">Thanks</h3> </div> <div class="panel-body">You accepted the Terms of service.</div> </div>'], ['name' => 'Panels with custom tag', 'description' => 'Set the <code>tag</code> option to use a different HTML tag to wrap the panel.', 'php_code' => "echo BootHelp::panel('You accepted the Terms of service.', ['tag'=>'aside']);", 'result' => BootHelp::panel('You accepted the Terms of service.', ['tag' => 'aside']), 'html_code' => '<aside class="panel panel-default"> <div class="panel-body">You accepted the Terms of service.</div> </aside>'], ['name' => 'Complex panels', 'description' => 'To include HTML tags or a long text in the panel, pass your content in a block. You can also specify custom options which will be added to the alert’s <code>div</code> tag.', 'php_code' => "echo BootHelp::panel(['heading'=>'Thanks', 'context'=>'info', 'id'=>'panel', 'class'=>'en', 'data-js'=>1], function(){\n return 'You accepted the Terms of service. ' . BootHelp::icon('ok');\n});", 'result' => BootHelp::panel(['heading' => 'Thanks', 'context' => 'info', 'id' => 'panel', 'class' => 'en', 'data-js' => 1], function () { return 'You accepted the Terms of service. ' . BootHelp::icon('ok'); }), 'html_code' => '<div data-js="1" class="en panel panel-info" id="panel"> <div class="panel-heading">Thanks</div> <div class="panel-body"> You accepted the Terms of service. <span class="glyphicon glyphicon-ok"></span> </div> </div>']]]; /** * Panel samples. */ echo new Sample($panels);