Jump to content

imap_search wildcard question - driving me crazy!


samlich

Recommended Posts

I've been working on this problem for two days now. I feel like an idiot because this should be so simple but I can't find any info about it online or any examples of this type of command in any form anywhere.

 

All I want to do is return a list of emails that match a imap_search() query. I am trying to search through an inbox to find emails that contain UPS tracking numbers. I can find no way (and coincidentally no documentation) to use a wildcard in a search string.

 

In other words, in my script, something like this works:

<?php $m_search=imap_search ($mail, 'BODY "comcast"') ?>

 

And these return nothing:

<?php $m_search=imap_search ($mail, 'BODY "comcas*"') ?>

<?php $m_search=imap_search ($mail, 'BODY "comcas%"') ?>

 

I feel like I've tried anything and really need some help.

 

ANY guidance would be amazing. I will likely send cash / gifts to anyone who can help me on this...

 

Thanks for reading.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.