Paypal 变量未正确发布
我正在为客户构建一个完全自定义的购物车,并且会话(“Payment_Amount”)也没有任何内容发布到贝宝。 http://www.julianrycecreations.com/cprof/ucprof/store_front.aspx您可以在那里查看她的购物车。它仍在开发中,很多东西我都没有正确排列。如果需要,我可以提供代码,但由于这是自定义的并且是购物车,因此我受到限制,但我会看看我能做什么。先感谢您。
这是将其带到结帐页面 order.aspx 的代码,
Protected Sub OrderBtn_Click(sender As Object, e As System.EventArgs) Handles OrderBtn.Click
If OrderSummaryLit.Text = "" Then
ErrorMessageLbl.Text = "Must Customize Product before Checkout."
Else
InsertOrderDS.Insert()
Dim comm = db.selectcommand(db.conn, "TOP 1 column_name", "table_name", "column_name = '" & Session("session") & "' ORDER BY column_name DESC")
Dim sqlda As New SqlDataAdapter(comm)
Dim dt As New DataTable
sqlda.Fill(dt)
Session("session") = dt.Rows(0)("column_name")
Response.Redirect("order.aspx?ord_id=" & dt.Rows(0)("column_name"))
End If
End Sub
这是您进入订单页面后按钮的代码。此使用应将会话发送到 paypal 提供的expresscheckout.aspx 页面的操作。它应该给出一个错误或其他东西,但没有。
<form action='expresscheckout.aspx' method='post'>
I am building a completely custom shopping cart for a client, and the session("Payment_Amount") nor anything is posting to paypal. http://www.julianrycecreations.com/cprof/ucprof/store_front.aspx is where you can go to view her shopping cart. It is still in development and alot of things my not line up correctly. I can provide code if needed, but since this is custom and a shopping cart that my be limited but I will see what I can do. Thank you in advance.
this is the code that takes it to the checkout page order.aspx
Protected Sub OrderBtn_Click(sender As Object, e As System.EventArgs) Handles OrderBtn.Click
If OrderSummaryLit.Text = "" Then
ErrorMessageLbl.Text = "Must Customize Product before Checkout."
Else
InsertOrderDS.Insert()
Dim comm = db.selectcommand(db.conn, "TOP 1 column_name", "table_name", "column_name = '" & Session("session") & "' ORDER BY column_name DESC")
Dim sqlda As New SqlDataAdapter(comm)
Dim dt As New DataTable
sqlda.Fill(dt)
Session("session") = dt.Rows(0)("column_name")
Response.Redirect("order.aspx?ord_id=" & dt.Rows(0)("column_name"))
End If
End Sub
here is the code for the button once you get the the order page. this uses and action that should send the session to the expresscheckout.aspx page provided by paypal. It should give an error or something but doesn't.
<form action='expresscheckout.aspx' method='post'>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
导致问题的原因是没有引用 api 代码。我只是从expresscheckout 中调用了该函数,它就起作用了。
What was causing the problem was not referencing the api code. I simply called the function from the expresscheckout and it worked.