Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

unable to retrieve  cookies  on google checkout notification url.

Posted on 2010-11-23
3
Medium Priority
?
363 Views
Last Modified: 2012-05-10
hi experts,

   Here i explain my scenario , i created a cookie on button click of google checkout button which has happened on my domain . I successfully created the cookie and i also able to view that cookie value on the every browser .

 i have two question  .. which explains in the code ?
 'wat strange is the process happening on notifcation url  i.e while clicking pay button
1.i could not able to read the cookie value which i generated on google check button click while process to sandbox confirmation page. ?
'2.if i create a cookie on the checkout page itself dat time i can able to read the cookie?


i got to use the use cookie value in order to update my table for backend process . is der anyother way of maintaining the cookie value dat google check out maintains ?



Meeran

Protected Sub GCheckoutButton2_Click(ByVal sender As Object, ByVal e As System.Web.UI.ImageClickEventArgs) Handles googleBTN.Click
dim httpcookie As New HttpCookie("google_click_cookie_creation") ' Cookie created and stores on the browser
httpcookie.Value = "random2342test"
Response.Cookies.Add(httpcookie)
Dim post = Req.GetPostUrl()
Req.AddItem(catid.InnerHtml, Categoryname.InnerHtml, baseprice, 1)
Dim Resp As GCheckoutResponse = Req.Send()
Response.Redirect(Resp.RedirectUrl, True)
end sub


--------------------**************************************************---
'on notification checkout page
 Public Sub chkout()
        ' Extract the XML from the request.
        Dim RequestStream As Stream = Request.InputStream
        Dim RequestStreamReader As New StreamReader(RequestStream)
        Dim RequestXml As String = RequestStreamReader.ReadToEnd()
        RequestStream.Close()
        Dim chk As String = ""
        Dim Content = ""
 'wat strange is the process happening on notifcation url i could not able to read dat cookie value . ?
        If Not Request.Cookies("google_click_cookie_creation") Is Nothing Then
            Content = Request.Cookies("google_click_cookie_creation").Value & Content & "if"
        Else
            Content = "else if"
        End If

'If i create a cookie on that page dat time i can able to read the cookie?
        Dim httpcookie As New HttpCookie("test")
        httpcookie.Value = "Cookie written on pay process which i received??"
        Response.Cookies.Add(httpcookie)
        Content = Content & Request.Cookies("test").Value

'I use email to receive wat happening in d mail which works well ..
    end sub

Open in new window

0
Comment
Question by:Rajar Ahmed
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 84

Accepted Solution

by:
Dave Baldwin earned 668 total points
ID: 34202808
Cookie info is Only exchanged when the page request is made from the browser so the server cannot read a cookie that it has just set.  You could use javascript to read the cookie in the browser.  Note that cookies can only be read on the domain that set them.
0
 
LVL 14

Assisted Solution

by:Dhanasekaran Sengodan
Dhanasekaran Sengodan earned 668 total points
ID: 34203886
0
 
LVL 29

Assisted Solution

by:Kumaraswamy R
Kumaraswamy R earned 664 total points
ID: 34203894
0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question