[Webinar] Streamline your web hosting managementRegister Today

x
?
Solved

For prakashk or ozo, please

Posted on 1999-12-23
11
Medium Priority
?
260 Views
Last Modified: 2010-07-27
Michel Plungjan and I have been working on this situation.  He developed some outstanding Javascripts for the order form but we ran into a problem with the email output on this double submit order form and he suggested that I ask either prakashk or ozo to help.

Each of the two outputs (product order email and credit card processing) is controlled by a different cgi script.  I have control over the email script (it's a modified Matt script), but not over the credit card processing script (it's Virtual Merchant's).  At this point, if you fill out the order at www.imagebakers.com/neworder.html and order some merchandise, then click on "Continue to delivery & credit card info", you'll be transferred to the credit card form which will include a listing of your order.  If you then fill out the credit card info (you'll need to use real cc info, but the VM script is a testcgi script so your card wouldn't be charged), the next screen that comes up is one that tells you your card's been authorized, the amount of the authorization, etc. etc. For a brief moment, though, a thankyou.html page comes up (then gets hidden by the cc authorization screen).

Problems:

1. The email output (which goes to orders@imagebakers.com) contains the delivery instructions but not the order itself.

2. The email output has no "From" name.

3.  I'd also love for the rewritten order info on cc.html to all be in the same font instead of two different fonts and two different sizes!

If you want to tackle this, email me at carol@cdclark.com and I'll email you the cgi/Perl script that controls the email output.  Like I said before, I have no control over the VM script (which controls the credit card processing).

Thanks!

Carol
0
Comment
Question by:CarolClark
  • 4
  • 3
  • 2
  • +1
11 Comments
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 2313489
Question is currently being answered offline

Michel
0
 
LVL 25

Expert Comment

by:clockwatcher
ID: 2313789
Michel,

I may have a solution for your perl question-- if things don't work out with whoever's working on it now.  Basically, a script simply acts as the go-between the virtual merchant script and your page.  You call it, it calls the the virtual merchant script, parses the results (if needed-- you may just want to dump the results back to the user), sends out the appropriate email, and displays the results.

You can test out a similar script I wrote for someone else which handles an amazon.com query at:

 http://experts-exchange.yahright.com/10224657/amazon.htm

The following performs a experts-exchange search (the results are pretty much just dumped back to the browser-- you'll notice the addition of the BASE tag and a slight text change):

 http://experts-exchange.yahright.com/10224657/
0
 

Author Comment

by:CarolClark
ID: 2313802
Thanks, clockwatcher.  I'll run your comments by the two other people who are working on this.

Carol
0
Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 2314393
Thanks!!

Does it do SSL too?

Michel
0
 

Author Comment

by:CarolClark
ID: 2315569
clockwatcher, can you contact me at carol@cdclark.com?  We have some questions for you about your script.

Thanks.

Carol
0
 
LVL 25

Expert Comment

by:clockwatcher
ID: 2315599
Carol,

Now that Michel has mentioned SSL, doing it with a "bridging" script would kind of ruin the whole point of using SSL-- unless you could place the bridging script under the SSL umbrella as well-- which I'm guessing isn't the case.

But, the script itself can make and handle the SSL request.  It's only a ten liner or so.

Check out the sample out:

http://experts-exchange.yahright.com/imagebakers/neworder.html

Please DO NOT include real credit card information, bogus information is good enough to show you that it is actually submitting the request to VM.  I'm not interested in knowing anyone's credit card info.

Here's the move.pl script that actually does everything.

  use HTTP::Request::Common qw(POST);
  use LWP::UserAgent;
  use CGI;
  $myCGI = new CGI;
  $ua = new LWP::UserAgent;

  print "Content-type: text/html\n\n";
  print "<HTML><BODY><h2>I was sent the follow params:</h2><ol>";
# Create a hash of the retrieved parameters
  foreach ($myCGI->param) {
      $myparams{$_} = $myCGI->param($_);
      print "<li>$_ : ".$myCGI->param($_)."\n";
  }
  print "</ol><hr>";
 
  my $req = POST 'https://www.thevmsecure.com/cgi-bin/remotedemo.cgi', [ %myparams ];
 
  my $page = $ua->request($req)->as_string;
  @entirepage = split("\n{2}|\n\r{2}", $page);
 
  $header = shift(@entirepage);
  $content = join("\n\n", @entirepage);
 
  print "<h2>Here's what Virtual Merchant said:</h2> <dir>".$content."</dir></p>";
 
  print "<hr><h2>If you wanted to send an email out based on the above params you could do it here or earlier</h2>";
 
  print "</body></html>";

----------------------------------------

If you'd like to contact me, you can do so at mark@yahright.com

0
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 2315615
Excellent show, Mark!

Michel
PS: Damn - it shows 100 in the date field AAAAAAAARRRRRRGGGGGG I am sooooooo embarrased
0
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 2315619
Oh no I'm not - not my script - I will fix it tho ;-)

Michel
0
 
LVL 2

Expert Comment

by:cadabra
ID: 2316006
Good night. (morning ???)
0
 
LVL 2

Accepted Solution

by:
cadabra earned 800 total points
ID: 2338792
PayDay ;)
0
 

Author Comment

by:CarolClark
ID: 2338956
I'd like to give cadabra 400 points, and I'd like to give clockwatcher 400 points.

Thanks.

Carol
0

Featured Post

Receive 1:1 tech help

Solve your biggest tech problems alongside global tech experts with 1:1 help.

Question has a verified solution.

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

A year or so back I was asked to have a play with MongoDB; within half an hour I had downloaded (http://www.mongodb.org/downloads),  installed and started the daemon, and had a console window open. After an hour or two of playing at the command …
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Six Sigma Control Plans
Suggested Courses

590 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