As a programmer, there are no real problems but challenges...ones that we need to overcome. This means that there is a solution for all challenges that one may face. For all the challenges that I have faced, I will share them and their solutions.
Wednesday, February 18, 2015
Clear attachments from previous email when sending with Codeigniter
I had the problem of sending multiple emails with attachment and having the attachment from a previous email included in the next email when using the codeigniter framework. Even though I searched the manual and included the clear option, the problem still persists. After doing some research, I found out that I had to include the TRUE option in the clear function: $this->email->clear(TRUE); This is what solved it for me.
Labels:
attachment,
clear,
codeigniter,
emails,
multiple,
php
Wednesday, February 4, 2015
PHP Array to String conversion Codeigniter
I was having this problem where I was doing an update batch to my db and I was getting the error of array to string conversion. The funny thing was that the db was being updated. After doing some research, I found out that there was a problem with the DB_active_rec.php file in Codeigniter, on line 1407.
Change $not[] = $k.'-'.$v; to $not[] = $k2.'-'.$v2 and the problem is solved.
Change $not[] = $k.'-'.$v; to $not[] = $k2.'-'.$v2 and the problem is solved.
Labels:
array,
codeigniter,
conversion,
error,
php,
string
Subscribe to:
Posts (Atom)