Welcome Guest, Not a member yet? Register   Sign In
My Request helper or library
#6

[eluser]slowgary[/eluser]
Exactly. Libraries are for classes, helpers and plugins are just procedural functions. Create a class with your functions, stick it in the application/libraries directory and load it with $this->load->library('request'), then you can call $this->request->isPost().

Just a recommendation, CodeIgniter uses_underscores as opposed to CamelCase. For consistency, you might want to consider naming your functions is_post(), is_get() and is_ajax().


Messages In This Thread
My Request helper or library - by El Forum - 09-05-2010, 06:33 AM
My Request helper or library - by El Forum - 09-05-2010, 09:27 AM
My Request helper or library - by El Forum - 09-05-2010, 09:43 AM
My Request helper or library - by El Forum - 09-05-2010, 09:54 AM
My Request helper or library - by El Forum - 09-05-2010, 09:57 AM
My Request helper or library - by El Forum - 09-05-2010, 10:23 AM
My Request helper or library - by El Forum - 09-05-2010, 12:43 PM
My Request helper or library - by El Forum - 09-05-2010, 02:38 PM
My Request helper or library - by El Forum - 09-06-2010, 12:16 AM



Theme © iAndrew 2016 - Forum software by © MyBB