Welcome Guest, Not a member yet? Register   Sign In
Views in post
#2

(This post was last modified: 08-07-2017, 04:11 PM by jarmen_kell.)

you can always do this, to set your value by increment-1
PHP Code:
$this->db->set('views''views+1'FALSE)->where('slug'=>$slug); 

and this is already documented inside CI's documentation,
if you would like to explore the docs more thoroughly:

https://www.codeigniter.com/user_guide/d...ating-data
Reply


Messages In This Thread
Views in post - by Marcolino92 - 08-07-2017, 12:37 PM
RE: Views in post - by jarmen_kell - 08-07-2017, 04:10 PM
RE: Views in post - by Marcolino92 - 08-08-2017, 12:08 AM



Theme © iAndrew 2016 - Forum software by © MyBB