Welcome Guest, Not a member yet? Register   Sign In
Need help related to my codeigniter wallpaper script
#13

It's suppose to be before everything else, so that you dump what $filter holds. Now it's already returning the sql command.
PHP Code:
public function color_sql($filter)
{
   
var_dump($filter);
   die();
   
$this->db->select('*, sum(count) AS color_sum');
   
$this->db->from('wallpapers_colors');
   
$this->db->where('saturation BETWEEN ' . (($filter['saturation'][0]) / 100) . ' AND ' . (($filter['saturation'][1]) / 100));
   
$this->db->where('lightness BETWEEN ' . (($filter['lightness'][0]) / 100) . ' AND ' . (($filter['lightness'][1]) / 100));
   
$this->db->where('hue BETWEEN ' . ($filter['hue'][0]) . ' AND ' . ($filter['hue'][1]));
   
$this->db->group_by('wallpaper_seq_id');
   return 
$this->sql();

Reply


Messages In This Thread
RE: Need help related to my codeigniter wallpaper script - by jreklund - 01-12-2018, 11:13 AM



Theme © iAndrew 2016 - Forum software by © MyBB