Pagina 2 di 2 primaprima 1 2
Visualizzazione dei risultati da 11 a 16 su 16
  1. #11
    grazie. questo funziona anche con pagina ASP classic?

  2. #12
    Amministratore L'avatar di Vincent.Zeno
    Registrato dal
    May 2003
    residenza
    Emilia-Romagna (tortellini und cappelletti land!)
    Messaggi
    20,657
    Quote Originariamente inviata da marco.agelao Visualizza il messaggio
    grazie. questo funziona anche con pagina ASP classic?
    dici a me?
    si, è scritto per asp

  3. #13
    guardo. grazie

  4. #14
    salve, scusate se non mi sono potuto collegare, ho avuto delle difficoltà.
    ho visto lo script che certamente funzionerà.
    però come lo utilizzo?
    ossia in che pagina lo metto?
    dopo aver inviato il form paypal fa il resto e dopo aver disposto il pagamento paypal manda ad una propria pagina in cui comunica l'avvenuto pagamento
    poi dovrebbe riportare alla pagina che ho indicato nel form quale pagina cui rimandare l'utente.
    quindi lo script dove va messo?
    forse è la pagina verso cui indirizzo le risposte di paypal?
    grazie anticipatamente
    Ultima modifica di marco.agelao; 17-07-2020 a 17:17

  5. #15
    allora, ho inserito lo script ed ho stampato a video i dati di ritorno di paypal ma non ricevo alcun dato

    <%
    Dim Item_name, Item_number, Payment_status, Payment_amount
    Dim Txn_id, Receiver_email, Payer_email
    Dim objHttp, str
    ' read post from PayPal system and add 'cmd'
    str = Request.Form & "&cmd=_notify-validate"
    ' post back to PayPal system to validate
    set objHttp = Server.CreateObject("Msxml2.ServerXMLHTTP")
    ' set objHttp = Server.CreateObject("Msxml2.ServerXMLHTTP.4.0")
    ' set objHttp = Server.CreateObject("Microsoft.XMLHTTP")
    objHttp.open "POST", "https://www.paypal.com/cgi-bin/webscr", false
    objHttp.setRequestHeader "Content-type", "application/x-www-form-urlencoded"
    objHttp.Send str
    ' assign posted variables to local variables
    Item_name = Request.Form("item_name")
    Item_number = Request.Form("item_number")
    Payment_status = Request.Form("payment_status")
    Payment_amount = Request.Form("mc_gross")
    Payment_currency = Request.Form("mc_currency")
    Txn_id = Request.Form("txn_id")
    Receiver_email = Request.Form("receiver_email")
    Payer_email = Request.Form("payer_email")
    ' Check notification validation
    if (objHttp.status <> 200 ) then
    ' HTTP error handling
    elseif (objHttp.responseText = "VERIFIED") then
    ' check that Payment_status=Completed
    ' check that Txn_id has not been previously processed
    ' check that Receiver_email is your Primary PayPal email
    ' check that Payment_amount/Payment_currency are correct
    ' process payment
    response.Write("Item_name = " & Item_name & "<br />" & "Item_number = " & Item_number & "<br />" & "Payment_status = " & Payment_status & "<br />" & "Payment_amount = " & Payment_amount & "<br />" & "Payment_currency = " & Payment_currency & "<br />" & "Txn_id = " & Txn_id & "<br />" & "Receiver_email = " & Receiver_email & "<br />" & "Payer_email = " & TxnPayer_email_id)
    elseif (objHttp.responseText = "INVALID") then
    ' log for manual investigation
    else
    ' error
    response.Write("errore")
    end if
    set objHttp = nothing
    %>

    dove sbaglio?
    ovviamente la pagina è ASP
    Ultima modifica di marco.agelao; 17-07-2020 a 18:12

  6. #16
    salve, qualcuno sa dirmi qualcosa in merito al problema?

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2024 vBulletin Solutions, Inc. All rights reserved.