Solved

Exchange rate in CGI

Posted on 2001-08-13
7
187 Views
Last Modified: 2013-12-25
Any help appreciated on this one.....

I currently have a UK based web site which accepts on-line payments in US dollars (via 3rd Party). The value of the payment is displayed on the page in UK pounds and I put the US dollar equivelant embedded in a CGI script which links to 'Paypal' (3rd Party payment).

The problem is going to be with currency variations the amount displayed in UK pounds will not be the same as the amount in the embedded link. I need some way to update this value which is passed across to 'Paypal' and to make things worse I have no knowledge of scripting so any replies please keep it simple....

Thanks

Paul
0
Comment
Question by:piddle61
  • 4
  • 2
7 Comments
 
LVL 51

Accepted Solution

by:
ahoffmann earned 300 total points
ID: 6383576
Are you using perl for CGI-scripts?
Then you may use
   use Finance::Currency::Convert;
just needs to add a line for UK pounds, then you can use
   $converter=new Finance::Currency::Convert;
   $pound=$converter->convert(100, "USD", "UKP");
to convert 100 US$ to UK punds
0
 

Author Comment

by:piddle61
ID: 6385299
I'm quickly trying to get my head around Perl & GCI scripts, your advice seems sound I will try it out with the help of some for our IT people and all being OK I think you'll get my points.... Thanks
0
 

Author Comment

by:piddle61
ID: 6410328
Sorry not to get back to this question... Have been away.. I am using a shell account on a unix box to learn perl and then basically put it on a web server supporting CGI scripts displaying info on HTML page.  I have put the above into a perl file and ran it on the server but it returned errors... I currently have the know-how of using variables and displaying variable on a web page... If you could just give me a little more help on the above script I would be a happy bunny.... Thanks
0
Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

 
LVL 51

Expert Comment

by:ahoffmann
ID: 6412181
> .. If you could just give me a little more help ..
If you post the errors/problems here.

Usualy you will not have the required modules installed.
Let me know.
0
 
LVL 8

Expert Comment

by:jhurst
ID: 6420597
I think that in view of your own assessment of your own abilities you need more help here than we are likely to be able to give you in this exchange.
0
 

Author Comment

by:piddle61
ID: 6430117
Possibly right, althugh I have nearly managed to get the modules installed and have made a working script that will save a manually entered exchange rate, then call it up for use in further HTML..... I'm gonna award the point for sending me in the right direction.... Thanks
0
 

Author Comment

by:piddle61
ID: 6430122
This has sent me in the right direction after finding the modules it should work.... Thanks
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

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

In this tutorial I will aim to show you how simple is making a small application in WhizBase, how to add, remove and update data in the DB. I will make a small address book application where you can add, browse, update and remove addresses. I wi…
Batch, VBS, and scripts in general are incredibly useful for repetitive tasks.  Some tasks can take a while to complete and it can be annoying to check back only to discover that your script finished 5 minutes ago.  Some scripts may complete nearly …
Learn the basics of modules and packages in Python. Every Python file is a module, ending in the suffix: .py: Modules are a collection of functions and variables.: Packages are a collection of modules.: Module functions and variables are accessed us…
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

803 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