Skip to content

How to find how many people have opened my autoresponder from the database?

edited July 2013 in Questions

I'm making an app that ties in with Sendy. I used the official API where I could, but many things I wanted to do weren't covered. So, I am making PHP scripts to pull the data I want out of the SQL database.

Currently, I'm trying to find how many people have opened my autoresponder.

It's easy enough to find how many it was sent to - in the recipients column of the ares_emails table there is just a plain number. Great!

But now I want to find how many opened it. The next column over, opens, seems to be what I want.

But here's what it says:

  84:,85:US,83:US,89:US,89:US,90:US,87:US,95:KR,92:CA,93:CA,97:US,107:US,111:TR,112:BR,116:MX,122:US,123:US,119:HU,106:MX,130:GB,119:HU,132:US,133:NG,127:IL,148:US,136:HK,151:US,158:AU,161:US,159:US,91:US,113:LB,83:US,88:US,143:US,119:HU,167:GR,85:US,165:AU,175:US,179:US,169:US,180:US,174:CA,181:US,182:AU,183:US,176:US,186:US,188:GB,170:US,101:US,193:GB,201:US,167:GR,119:HU,201:US,211:US,208:CR,207:CR,217:US,211:US,174:CA,174:CA,174:CA,174:CA,174:CA,224:US,227:US,228:US,90:US,90:US,232:CN,119:HU,234:GB,241:PH,151:US,217:US,244:MY,247:PH,249:PH,242:NO,259:US,201:US,262:US,263:GB

Not exactly plaintext :(

How do I extract how many people have opened the autoresponder email from the database?

Comments

  • You need to use PHP explode to get the individual subscriber ids and their country code for opens.

  • edited July 2013

    @Ben

    So this should work:

    $array = explode(',', $stringFromDB);
    

    And then count the array?

  • Yes - count($array)

This discussion has been closed.