Welcome Guest, Not a member yet? Register   Sign In
Trying to extend the input class
#1

[eluser]douglasbrownca01[/eluser]
I am trying to store a query string in a table then bring it back the string and substitue the the id number to shorten the url.

I've done this for the MY_Input.php in the library.


<?php
class MY_Input extends CI_Input {


function save_query($query_array) {

$CI =& get_instance();

$CI->db->insert('ci_query', array('query_string' => http_build_query($query_array)));

return $CI->db->insert_id();
}

function load_query($query_id) {

$CI =& get_instance();

$rows = $CI->db->get_where('ci_query', array('id' => $query_id))->result();
if (isset($rows[0])) {
parse_str($rows[0]->query_string, $_GET);
}

}

}


in my search function in the controler I save the query string like this:


$query_id = $this->input->save_query($query_array);

All I get is a blank screen, not a 404 error -- So something is failing somewhere. I know that the function is being reconized -- when I remove the code from MY_Input.php, I get an error, so I know that it's registering.

What is the best way to trouble shoot something like this when you're getting a blank screen?


Messages In This Thread
Trying to extend the input class - by El Forum - 01-07-2013, 07:05 AM
Trying to extend the input class - by El Forum - 01-07-2013, 07:30 AM
Trying to extend the input class - by El Forum - 01-07-2013, 07:31 AM
Trying to extend the input class - by El Forum - 01-07-2013, 08:22 AM
Trying to extend the input class - by El Forum - 01-07-2013, 08:29 AM
Trying to extend the input class - by El Forum - 01-07-2013, 08:47 AM
Trying to extend the input class - by El Forum - 01-07-2013, 09:11 AM
Trying to extend the input class - by El Forum - 01-07-2013, 11:09 AM
Trying to extend the input class - by El Forum - 01-07-2013, 11:11 AM
Trying to extend the input class - by El Forum - 01-07-2013, 11:12 AM
Trying to extend the input class - by El Forum - 01-07-2013, 11:14 AM
Trying to extend the input class - by El Forum - 01-07-2013, 11:22 AM
Trying to extend the input class - by El Forum - 01-07-2013, 12:25 PM
Trying to extend the input class - by El Forum - 01-07-2013, 12:30 PM



Theme © iAndrew 2016 - Forum software by © MyBB