Jump to content


Photo

Test of PayPal script says "possible typos" ?


  • This topic is locked This topic is locked
5 replies to this topic

#1 cithelp

cithelp

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 12 January 2003 - 12:20 AM

Fellow Developers,

I am trying to create a content subscription web site with individual login IDs and passwords. My web host is operating in a Linux environment.

SUCCESSES:
* IPN passwords and login IDs successfully generated.
* Payments, refunds, and subscriptions cancellations work fine.
* Email notifications to subscriber and us (the provider) work fine.

PROBLEMS:
* Primary - I am getting a PERL test results from our web host, ValueWeb, that says "possible typo" (on lines 29-36).
* Secondary - Although I have added the "password" variable to the IPN PERL script, it is not logging correctly. This and other problems may be resolve if we correct the primary problem above.

NOTE: As a web host, ValueWeb provides a specific test of a PERL script once it has been uploaded to a web site. I have confirmed the path to their PERL processing and the test states that syntax is OK.


INSTRUCTIONS FOR YOUR INPUT/REVIEW/ADVICE:
1) First, review the code lines below of the PayPal PERL script that are causing the error messages.
2) Review the ValueWeb error messages generated by the test of the PayPal PERL script.

The complete PERL script is provided at the following URL:
https://www.paypal.c...cl/rec/ipn-code


PAYPAL-PROVIDED PERL SCRIPT ********************************

# assign posted variables to local variables
# note: additional IPN variables also available -- see IPN documentation
$item_name = $variable{'item_name'};
$receiver_email = $variable{'receiver_email'};
$item_number = $variable{'item_number'};
$invoice = $variable{'invoice'};
$payment_status = $variable{'payment_status'};
$payment_gross = $variable{'payment_gross'};
$txn_id = $variable{'txn_id'};
$payer_email = $variable{'payer_email'};


WEB HOST SCRIPT TEST *************************************

Perl Validation Results


Name "main::txn_id" used only once: possible typo at /m1/needmore/cgi-bin/ipn_perl.htm line 35.
Name "main::payer_email" used only once: possible typo at /m1/needmore/cgi-bin/ipn_perl.htm line 36.
Name "main::invoice" used only once: possible typo at /m1/needmore/cgi-bin/ipn_perl.htm line 32.
Name "main::item_name" used only once: possible typo at /m1/needmore/cgi-bin/ipn_perl.htm line 29.
Name "main::item_number" used only once: possible typo at /m1/needmore/cgi-bin/ipn_perl.htm line 31.
Name "main::payment_gross" used only once: possible typo at /m1/needmore/cgi-bin/ipn_perl.htm line 34.
Name "main::payment_status" used only once: possible typo at /m1/needmore/cgi-bin/ipn_perl.htm line 33.
Name "main::receiver_email" used only once: possible typo at /m1/needmore/cgi-bin/ipn_perl.htm line 30.
/m1/needmore/cgi-bin/ipn_perl.htm syntax OK

********************************

What the heck am I missing?!!! I am getting extremely frustrated :-(

Thank you very, very much for any assistance!


Best regards,

Todd Ruffaner
Clearly I.T. ( www.clearlyit.com )
toddr@clearlyit.com


#2 paypal_pb

paypal_pb

    Advanced Member

  • Members
  • 2,960 posts

Posted 12 January 2003 - 04:49 PM

I think it's jsut a soft error warning you that you've assigned a variable but then didn't use it. It reports the syntax as OK so you probably need not worry about it. Or you could delete all the variable assignments that you do not use elsewhere in the script.

Also, it's good practice to name perl scripts with either a .cgi or .pl extension instead of .htm as it appears you have.

Patrick Breitenbach
PayPal, Inc.
Dev Net: https://www.paypal.com/pdn

#3 cithelp

cithelp

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 15 January 2003 - 02:32 AM

Thanks, Patrick.

Your comments were helpful, but I feel like I'm still missing a piece of the puzzle. Maybe you (or others) could provide some additional insight.

WHAT IS WORKING:
* I can process orders and refunds easily.
* PayPal's password management feature successfuly creates login IDs and passwords.
* PayPal successfully sends emails to customers and the web site administrator.

PROBLEM:
* The login IDs and passwords are not getting posted to my web site server.

WHAT I HAVE DONE:
* Using the PayPal button wizard, I created a PayPal subscription button with automatic monthly renewals and placed it on my web page. NOTE: I selected to have PayPal perform password management.

* From a PayPal development page ( https://www.paypal.c...cl/rec/ipn-code ), I copied the PayPal Perl script for IPN and saved it as a separate file in my web site titled "ipn_perl.cgi" . NOTE: The complete URL that I use in my PayPal IPN setup is correct. The only change that I made to the PayPal Perl script was to change the path to my web host's Perl script from " #!/usr/bin/local/perl " to " #!/usr/bin/perl ".

* Even if I had the "password" variable into the PayPal Perl script (mentioned above), there are no passwords being posted to my web site.

* On my web site, I suspect that I need a second script page for password management --- in addition to the IPN Perl script page. Is this correct and how would I code it?

I feel that I am very close to success, but just can't seem to get there. I have read the PayPal Manuals for IPN and Subscriptions numerous times; much of it is well written and helpful. However, there are certain posting and password management techniques that are vague as to what specific file types to create. Heck, most of the variables are listed...I just need to know what SPECIFIC files to put them in.

I am doing some serious stressing on this because I just don't know what course to pursue. H-E-L-P !!!


Best regards,

Todd Ruffaner
Clearly I.T. ( www.clearlyit.com )
toddr@clearlyit.com


#4 paypal_pb

paypal_pb

    Advanced Member

  • Members
  • 2,960 posts

Posted 15 January 2003 - 11:48 AM

It sounds like you should be using our Password Management service that includes a PERL script which automatically updates your .htpasswd file. Log in to PayPal and go to "Sell > Subscriptions".

Patrick Breitenbach
PayPal, Inc.
Dev Net: https://www.paypal.com/pdn

#5 cithelp

cithelp

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 16 January 2003 - 09:56 AM

Patrick,

THANKS! I believe the link that you provided and the other PayPal Perl script will do the trick.

NOTE: The "Subscriptions Password Management" link on the following page does not work:

https://www.paypal.c...aypal-solutions

I think it would be a big help to others if it directed them to the information (manual and script) that you referred to me.

Best regards,
Todd

#6 paypal_pb

paypal_pb

    Advanced Member

  • Members
  • 2,960 posts

Posted 16 January 2003 - 11:53 AM

You can get to that page without logging in at http://www.paypal.co...lutions-outside

The PERL script can be found if you log in and go to "Sell > Subscriptions > Password Management".

Patrick Breitenbach
PayPal, Inc.
Dev Net: https://www.paypal.com/pdn




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users