Hi All,
For passing the user's id from my database to orkut I've employed
below logic. But it fails!!

1) I've declared the Array "arrName" in JS file
2) Populated "arrName" in Match.asp and also define a div "match" in
this asp page
3) In the callback function, I'm tracing for the presence of the above
div and if it is present, I'm calling a JS function "ShowMatch()" by
passing it the arrName
4) This function is being called but the size of the array is showing
as 0
5) For debugging I've filled the array in JS file instead of filling
it in ASP page and called the "ShowMatch()"
6) now this function is showing me the right size of array and also
printing the correct details of the passed user id
7) From this I came to know that the JS array which is being declare
in JS file is not getting populated in ASP page. Though if I view the
source code of the ASP page, I can see the Js array being populated
correctly.
8) It means my ASP page is correct and also my JS function, if I
populate the array in JS itself.
9) But I want to get the data from the database, as this is the actual
requirement!!!

Can anyone help me as how to populate the JS array in ASP page and
then use that in a JS function!!!
Please guys help me soon as I'm running out of time and my API will be
of no use if I'm not able to do this module.

Regards,
Javed

On Oct 10, 12:48 pm, Javediq143 <javediq_...@yahoo.com> wrote:
> Hi All,
> This post is related to my earlier below 
> posthttp://groups.google.com/group/opensocial-orkut/browse_thread/thread/...
>
> The flash is working on orkut and I'm able to store user preferences.
> Here I must disclose my API fully so that anyone can help me out
> further. One section of my API will store user choices in the database
> and the other will list all those user from orkut, who have added my
> API but may or may not be friend of this user, with whom this user's
> choices are similar. I'm sure you all must have got the objective of
> my API... Users with matching choices can send friend request and...
> social network will grow large and large!!!
>
> As I've mentioned I'm able to store user choices but now got stuck in
> the other section. I need to fetch those user's open social ids from
> my database and return them to orkut so that orkut can return their
> THUMBNAIL, DISPLAY NAME & PROFILE URL which I will list to the user.
> For doing this I'm able to plot the below logic:
>
> 1)Fetch and store ids in an ASP array
> 2)Create Javascript array through ASP and assign the ASP array values
> to Js array
> 3)Call a JS function "ShowMatch" on BODY ONLOAD event and pass JS
> array to this function
> 4)ShowMatch will create a REQUEST object and send the array to ORKUT
> and the Callback function "HandleMatch" will finally list those
> returned info
>
> I'm able to do step 1 & 2 but not able to call the function on orkut!!
> I mean the event isn't firing due to which the function is not being
> called. Further query:
>
> 1) Is this the right way to call a function in Orkut, at Body OnLoad
> event!!! I dont think so
> 2) Or should I define a div with an Id in the Match List page and look
> out for the presence of this div in Javascript Callback function and
> if the div is present I should call ShowMatch function. But for this,
> I think, I need to declare the JS array at GLOBAL and just populate it
> in the Match List Page so that the ShowMatch function could use it
>
> Also, is this the right code for creating a request object with
> passing array of IDs
> function showMatch(matchIDs)
> {
>      var req = opensocial.newDataRequest();
>      req.add(req.newFetchPeopleRequest(matchIDs), 'matchUsr');
>      req.send(handleMatchList);
>
> }
>
> Can anyone guide me in the right direction!!! Anyone!!! Please... My
> work is almost complete but I want to complete it completely. Please
> help me as how to pass the ASP array to JS and use it in JS function
> and create Request Object for orkut.
>
> Thanks & Regards to all,
> Javed
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Orkut Developer Forum" group.
To post to this group, send email to opensocial-orkut@googlegroups.com
To unsubscribe from this group, send email to 
opensocial-orkut+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/opensocial-orkut?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to