Search the web
Sign In
New User? Sign Up
ydn-mail · Yahoo! Mail Developer Community
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Want to share photos of your group with the world? Add a group photo to Flickr.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
Question about accessing elements in ListFolders()   Message List  
Reply | Forward Message #651 of 655 |
Re: Question about accessing elements in ListFolders()

Erm, "bump"?

--- In ydn-mail@yahoogroups.com, "Rob" <robsartgallery@...> wrote:
>
> Hi Ryan:
>
> I tried your suggestion and added that trace code, but I think Yahoo! hates me
now or something, because I just hit a "error-999" trying to run the test again
(starting at http://www.dscomic.com/code/test.php)
>
> As far as practical examples of the nitty-gritty, what would be worth more
than gold to me would be to see specific examples of the following, with PHP:
>
> 1) Getting the list of folders and listing out the folder names
> 2) Selecting a folder and grabbing the first message
> 3) deleting a message and moving to the next one
>
> Hope that's not too much to ask, but once I get rolling, I should be set
forever... :)
>
> Thanks,
>
> Rob
>
> --- In ydn-mail@yahoogroups.com, Ryan Kennedy <rckenned@> wrote:
> >
> > What "nitty-gritty" are you looking for? Give some examples of some calls
you want to make and I can tell you how to craft the request.
> >
> > As for setting trace on SoapClient, it sounds like you're doing it wrong.
PHP appears to think you're passing 3 parameters to the SoapClient constructor
when you should only be passing 2 parameters:
> >
> > $client = new SoapClient("http://mail.yahooapis.com/ws/mail/v1.1/wsdl",
> > array(
> > "trace" => true
> > )
> > );
> >
> > There are only 2 parameters: the URL pointing to the WSDL and the array
containing the client options.
> >
> > --
> > Ryan Kennedy
> > Technical Yahoo!
> > rckenned@
> >
> >
> > >
> > >From: robsartgallery <robsartgallery@>
> > >To: ydn-mail@yahoogroups.com
> > >Sent: Wednesday, August 12, 2009 12:04:19 PM
> > >Subject: [ydn-mail] Re: Question about accessing elements in ListFolders()
> > >
> > > >
> > >
> > >
> > >
> > >
> > >The PHP code samples give some help, but they don't really get into the
nitty-gritty of making ListMessage calls. I think having a few plain english
examples would help.
> > >
> > >>Also, I tried doing the trace, and I must have done something wrong with
that second parm, because now I get this...
> > >
> > >>Warning: SoapClient:: SoapClient( ) expects at most 2 parameters, 3 given
in /homepages/10/ d264766990/ htdocs/code/ test2.php5 on line 26
> > >
> > >>Fatal error: Uncaught SoapFault exception: [Client] SoapClient::
SoapClient( ) [<a href='soapclient. soapclient' >soapclient. soapclient< /a>]:
Invalid parameters in /homepages/10/ d264766990/ htdocs/code/ test2.php5: 26
Stack trace: #0 /homepages/10/ d264766990/ htdocs/code/ test2.php5( 26):
SoapClient-> SoapClient( 'http://mail. yah...', true, Array) #1 {main} thrown in
/homepages/10/ d264766990/ htdocs/code/ test2.php5 on line 26
> > >
> > >>A warning, then an error. Any ideas what I missed?
> > >
> > >>Thanks
> > >
> > >>--- In ydn-mail@yahoogroup s.com, Ryan Kennedy <rckenned@ .> wrote:
> > >>>
> > >>> Have you looked at the PHP code samples provided on developer.yahoo.
com?
> > >>>
> > >>>
> > >>> http://developer. yahoo.com/ mail/code/
> > >>>
> > >>>
> > >>> They're slightly verbose, but they do call ListFolders.
> > >>>
> > >>>
> > >>> Also, try enabling call tracing like I suggested in my last message to
see what's being sent back from the server.
> > >>>
> > >>> --
> > >>> Ryan Kennedy
> > >>> Technical Yahoo!
> > >>> rckenned@
> > >>>
> > >>>
> > >>> >
> > >>> >From: robsartgallery <robsartgallery@ ...>
> > >>> >To: ydn-mail@yahoogroup s.com
> > >>> >Sent: Tuesday, August 11, 2009 1:36:18 PM
> > >>> >Subject: [ydn-mail] Re: Question about accessing elements in
ListFolders( )
> > >>> >
> > >>> >
> > >>> >Was anyone with Y!Mail able to take a peek at this, to figure out why
my php is bombing? Again, what would really help is to see a comprehensive php
example of the ListFolders/ ListMessages, then I could compare this to what I've
written to try and determine where the code error is.
> > >>> >
> > >>> >>Thanks.
> > >>> >
> > >>> >>--- In ydn-mail@yahoogroup s.com, "robsartgallery" <robsartgallery@
...> wrote:
> > >>> >>>
> > >>> >>> Thanks for the reply. I'll reply to you with an email, since
there's a lot of code to past here, but for the most part, most all of the code
that I used was just the ready-bake stuff provided in the Yahoo code docs.
> > >>> >>>
> > >>> >>> I think what would help is seeing a php example somewhere (anywhere)
of doing the ListFolders - ListMessages - GetMessages flow of steps. Are there
any other examples, other than what's already out at developer.yahoo. com/mail?
> > >>> >>>
> > >>> >>> Thanks!
> > >>> >>>
> > >>> >>> Rob
> > >>> >>>
> > >>> >>>
> > >>> >>>
> > >>> >>>
> > >>> >>>
> > >>> >>> --- In ydn-mail@yahoogroup s.com, Ryan Kennedy <rckenned@> wrote:
> > >>> >>> >
> > >>> >>> > A few questions:
> > >>> >>> >
> > >>> >>> > 1) Can you reply with the code you're using to set up the $client
object? It may be that you're missing some information that needs to be passed
along (cookies, wssid and application ID must all be passed in as part of the
constructor) .
> > >>> >>> >
> > >>> >>> > 2) When you set up the SoapClient object, try enabling "trace"
(set "trace" => true in the second argument to the SoapClient constructor) and
call $client->__getLastR esponse() after the calls to ListFolders and
ListMessages, that will get you the raw responses coming back from the Yahoo!
Mail servers for further debugging.
> > >>> >>> > --
> > >>> >>> > Ryan Kennedy
> > >>> >>> > Technical Yahoo!
> > >>> >>> > rckenned@
> > >>> >>> >
> > >>> >>> > >From: robsartgallery <robsartgallery@ >
> > >>> >>> > >To: ydn-mail@yahoogroup s.com
> > >>> >>> > >Sent: Thursday, August 6, 2009 12:51:28 PM
> > >>> >>> > >Subject: [ydn-mail] Question about accessing elements in
ListFolders( )
> > >>> >>> > >
> > >>> >>> > >>
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > > Hi,
> > >>> >>> > >>
> > >>> >>> > >>I've gone through the authentication steps, constructed the SOAP
client, and now I'm trying to access the list of messages using the ListFolders
function w/ PHP. But I'm doing something wrong here, because I'm not seeing
anything coming back. Here's an example of what I'm trying to do: first, I want
to display the number of folders, then display the starting message id. In both
instances, nothing is displayed on the page. What am I doing wrong here? I'd
appreciate a hand.
> > >>> >>> > >>
> > >>> >>> > >> $folderList = $client->ListFolder s();
> > >>> >>> > >> $request = new stdclass();
> > >>> >>> > >> $request->fid = "Inbox";
> > >>> >>> > >> $request->startInfo = 0;
> > >>> >>> > >> $request->numInfo = 20;
> > >>> >>> > >> $messageList = $client->ListMessag es($request) ;
> > >>> >>> > >>
> > >>> >>> > >> $showNumFolders = $messageList- >numberOfFolders ;
> > >>> >>> > >> echo ("number of folders...<br />");
> > >>> >>> > >> echo $showNumFolders;
> > >>> >>> > >>
> > >>> >>> > >> $showStartMid = $messageList- >startMid;
> > >>> >>> > >> echo ("Starting message id...<br />");
> > >>> >>> > >> echo $showStartMid;
> > >>> >>> > >>
> > >>> >>> > >>
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> > >
> > >>> >>> >
> > >>> >>>
> > >>> >
> > >>> >
> > >>> >
> > >>> >
> > >>> >
> > >>> >
> > >>> >
> > >>>
> > >
> > >
> > > > >
> >
>





Wed Nov 4, 2009 4:55 am

robsartgallery
Offline Offline
Send Email Send Email

Forward
Message #651 of 655 |
Expand Messages Author Sort by Date

Hi, I've gone through the authentication steps, constructed the SOAP client, and now I'm trying to access the list of messages using the ListFolders function...
robsartgallery
Offline Send Email
Aug 6, 2009
7:51 pm

A few questions: 1) Can you reply with the code you're using to set up the $client object? It may be that you're missing some information that needs to be...
Ryan Kennedy
rckenned_at_...
Offline Send Email
Aug 6, 2009
8:34 pm

Thanks for the reply. I'll reply to you with an email, since there's a lot of code to past here, but for the most part, most all of the code that I used was...
robsartgallery
Offline Send Email
Aug 7, 2009
3:41 pm

Was anyone with Y!Mail able to take a peek at this, to figure out why my php is bombing? Again, what would really help is to see a comprehensive php example...
robsartgallery
Offline Send Email
Aug 11, 2009
8:36 pm

Have you looked at the PHP code samples provided on developer.yahoo.com? http://developer.yahoo.com/mail/code/ They're slightly verbose, but they do call...
Ryan Kennedy
rckenned_at_...
Offline Send Email
Aug 11, 2009
8:52 pm

The PHP code samples give some help, but they don't really get into the nitty-gritty of making ListMessage calls. I think having a few plain english examples...
robsartgallery
Offline Send Email
Aug 12, 2009
7:04 pm

What "nitty-gritty" are you looking for? Give some examples of some calls you want to make and I can tell you how to craft the request. As for setting trace on...
Ryan Kennedy
rckenned_at_...
Offline Send Email
Aug 21, 2009
8:52 pm

Hi Ryan: I tried your suggestion and added that trace code, but I think Yahoo! hates me now or something, because I just hit a "error-999" trying to run the...
Rob
robsartgallery
Offline Send Email
Sep 28, 2009
8:32 pm

Erm, "bump"?...
Rob
robsartgallery
Offline Send Email
Nov 4, 2009
4:56 am
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help