PHP code example of kassovicms / onyx

1. Go to this page and download the library: Download kassovicms/onyx library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

kassovicms / onyx example snippets


    $drp_data = new sqldata();
    $drp_data->sql_query = "SELECT ID, sposob_oslovenia from typ_navstevy";
    $drp_data_result = $drp_data->get_sql_data();
    
    $drp = new purecss_form_control();
    $drp->label = "Spôsob";
    $drp->name = "sposob_oslovenia";
    $drp->id = "sposob_oslovenia";
    $drp->help_block = "Navštívená osoba 1";
    $drp->dd_value = array_column($drp_data_result, 'ID');
    $drp->dd_display = array_column($drp_data_result, 'sposob_oslovenia'); //array("Volvo", "BMW", "Toyota");
    $drp->

    $item = new purecss_form_control();
    $item->label = "POS";
    $item->name = "ID_POS";
    $item->type = "number";
    $item->input_value = $pos;
    $item->
 echo $form_action;