Copy link to clipboard
Copied
I am unable to reference/use the uid values in my cfpop query becasue they all have commas in them. The documentation says that uid is "UID or a comma-separated list of UIDs to get or delete. Invalid UIDs are ignored." But since there is a comma in the uid, none of them are showing as valid.
Here is a short example list of the uid values I am seeing:
1242171504.5738.mail16,S=7799
1256158656.31258.mail41,S=4187
1256160932.4879.mail4,S=5539
Perhaps only part of these strings is really the uid?
Thanks for any help/suggestions. I searched Google and the forums but could not find a solutioin. The last comment in the CF 8 documentation asks the same quesiton - http://livedocs.adobe.com/coldfusion/8/htmldocs/help.html?content=Tags_p-q_08.html but it is unanswered.
Thank you,
Cheryl
Copy link to clipboard
Copied
Maybe just try a bit of experimentation. I suspect the first numeric sequence is the actual UID (this is based on reading some RFCs which suggest the UID is a 32-bit integer value).
Why don't you just try an operation using that pat of what's being returned as the UID and see what happens? If you're using a test mail box, it's a zero-risk experiment.
--
Adam
Copy link to clipboard
Copied
Thanks for the suggestions Adam, but none of the substrings work either. I even tried just hardcoding one of the IDs and also parts of it and nothing gets returned, which according to the CF8 docs means it is not a valid uid (invalud uids get ignored).
Using this ID: 1256160932.4879.mail4,S=5539
In addition to the full uid valud used in the code below, I also tried to enter the following values in the cfpop code, and nothing works:(
1256160932
1256160932.4879
1256160932.4879.mail4
S=5539
5539
<cfpop
server="mail.mydomain.com"
action="getHeaderOnly"
name="emailmessages"
password="mypw"
username="myun"
uid="1256160932.4879.mail4,S=5539">
<cfdump var="#emailmessages#">
If I eliminate the uid attribute in the code above, then all three messages on the server get returned, including the one showing a uid of 1256160932.4879.mail4,S=5539.
Any other suggestions? Could this somehow be related to the mail host or the email account settings (Network Solutions)?
Thanks.
Copy link to clipboard
Copied
Oh - I also forgot to mention that it is a test mailbox at this point.
Copy link to clipboard
Copied
Any other suggestions? Could this somehow be related to the mail host or the email account settings (Network Solutions)?
Not really, no. I'm no real expert in how POP is supposed to work.
But it would not hurt to get in touch with the provider and ask them how it is their UIDs aren't actually UIDs.
Are you running on CF9 by any chance? And if so do you need to use POP or could you use IMAP instead?
You should probably at the very least raise this with Adobe (http://cfbugs.adobe.com/cfbugreport/flexbugui/cfbugtracker/main.html), and possibly open a support call with them. If it turns out to be their fault, they won't charge you.
--
Adam
Copy link to clipboard
Copied
I am using CF8. I read some other comments that there are inconsistencies with mail servers and the uids. I have started writing my code using the messagenumber, but apparently there are bugs with messagenumber in CF9 (http://www.johnramon.com/index.cfm/id/19/ColdFusion-9-cfpop-problem-with-messagenumber)
I opened a bug report. I will also contact the mail host, Network Solutions, though who knows if their tech support will even understand what I am referring to!
Thanks again.
Copy link to clipboard
Copied
After a fair bit of research, I think Paul Vernon has the answer: http://popcfc.riaforge.org/
We had been using his cfx_pop3, but we wanted to move to a straight forward solution.
Using Paul's pop.cfc solved the issue, and allows the retrieval by uid.
Best regards
Claude
Copy link to clipboard
Copied
Yes, popcfc is the solution.
See http://murrayhopkins.wordpress.com/2013/10/24/cfpop-deleting-an-email-when-there-is-a-comma-in-the-u... for more on how to use it.
@wandsoft: Thanks for pointing this out.
Cheers,
Murray