<commit_before><?php
defined('BASEPATH') OR exit('No direct script access allowed');

class select_options extends Base_Controller {
    function __construct() {
        parent::__construct();
        $this->load->model('select_options_model'); 
    }
    
	public function index()
	{
        check_login();       
            $this->load->view('select_options_list');        
	}
    <commit_msg>added proc action for procedure<commit_after><?php
defined('BASEPATH') OR exit('No direct script access allowed');

class select_options extends Base_Controller {
    function __construct() {
        parent::__construct();
        $this->load->model('select_options_model'); 
    }
    
	public function index()
	{
        check_login();       
            $this->load->view('select_options_list');        
	}
    
	public function proc()
	{   
	    $segments = $this->uri->segments;
	    $sLength  =  sizeof($segments);
	    $params ="";
	    if($sLength>3){
	         
            for ($x = 4; $x <= $sLength; $x++) {
                if($params!=="") $params .=",";
                $params .= $segments[$x];
            } 
	        
	    }
	    
        check_login();
        $query =$this->db->query("call ".$segments[3]."($params)");
        jsonOut( $query->result());
	}    
        
{'fraction_non_alphanumeric': 0.15707620528771385, 'fraction_numerical': 0.0023328149300155523, 'mean_word_length': 2.1313868613138687, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 17, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3301470', 'n_tokens_mistral': 386, 'n_tokens_neox': 374, 'n_words': 71}