Welcome Guest, Not a member yet? Register   Sign In
passing data to a custom library
#2

[eluser]pickupman[/eluser]
You should be able to use
Code:
$this->load->library('RemoteConnector', array($url));

Or just edit the library so it will take an array. Take a look at the Email.php file in /system/libraries/Email.php.

An array is passed to the constructor. If the array exists, it calls the initialize() method. That method loops through each array key=>value pair and sets the classes property=>value.

The array is used to order the arguments for the constructor. CI doesn't know how many values you need to pass.


Messages In This Thread
passing data to a custom library - by El Forum - 09-21-2010, 06:30 PM
passing data to a custom library - by El Forum - 09-21-2010, 07:52 PM
passing data to a custom library - by El Forum - 09-21-2010, 08:25 PM
passing data to a custom library - by El Forum - 09-22-2010, 08:19 AM
passing data to a custom library - by El Forum - 10-08-2010, 07:20 PM
passing data to a custom library - by El Forum - 08-05-2011, 03:06 PM
passing data to a custom library - by El Forum - 08-05-2011, 05:05 PM



Theme © iAndrew 2016 - Forum software by © MyBB