Hello,
The original script is as follows. In order to use it, just paste the script
in the address bar of the profile of the person, and one by one all the
pictures of the person appears.

javascript:alert("Wait for few seconds for pic`s to
load...");nb=document.all[0].innerHTML.match(/[0-9]*.jpg\)/g);nb=parseInt(nb);for(i=1;i<=100;i++){document.body.innerHTML+='
<img src="http://img3.orkut.com/images/milieu/'+i+'/0/'+nb+'.jpg
<http://img3.orkut.com/images/milieu/%27+i+%27/0/%27+nb+%27.jpg>"><br><br><br><br>';};void(0)


However, the above thing won't work in OS gadgets, as OS gadgets are inside
an iframe. But it gives an approach of how to get the thumbnail url. What i
have thought over is something like this


   1. Get the profile owner's id. Call it *prof_owner_id*
   2. Fetch the Thumbnail url of the *prof_owner_id*. The URL will look
   something like http://img3.orkut.com/images/small/410/4324410.jpg We
   are interested in the values *410 *(say *nb1*) and  *4324410* (say *
   nb2*), So a bit of javascript (StringObj.slice) will get us both the
   values.
   3. Now the thumbnails of pictures in the album looks something like

   http://img2.orkut.com/images/milieu/8/410/4324410.jpg

   4. The above URL can be generalized as
   http://img2.orkut.com/images/milieu/*[picture_number]*/*[nb1]*/*[nb2]*
   .jpg
   5. SInce orkut has a maximum 100 pictures limit, create a loop that
   will check all possible values of picture_number from 1 to 100. If no image
   is found, make an appropriate handler.

I have not created the gadget yet, and in the process of creating it.
However i thought it better to publish the approach first.
-- 
Pranav Prakash

http://codecontrol.blogspot.com

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Orkut Discussion" group.
To post to this group, send email to opensocial-orkut@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/opensocial-orkut?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to