Skip to content

Instantly share code, notes, and snippets.

<?php
public function hledej($vyraz, $sloupec)
{
$conditions = array();
if ($sloupec == 'K') {
for ($i = 1; $i <= 4; ++$i)
$conditions[] = array('%n LIKE %s', $sloupec . $i, '%' . $vyraz . '%');
} else {
$conditions[] = array('%n LIKE %s', $sloupec, '%' . $vyraz . '%');
<?php
class MyPresenter extends BasePresenter
{
protected function createComponentSomeForm()
{
$form = new AppForm();
// ...
return $form;
}
<?php
class BasePresenter extends Presenter
{
// ...
protected function beforeRender()
{
// ...