News:

CPG Release 1.6.29
During HTML5 upload, keep pseudo blank code 200 messages from triggering error condition
added Russian language
correct failure to use theme menu icons in album manager
minor vulnerabilities mitigation

Main Menu

New Paypal Mod on a customizable page. For: cpg1 .3x and 1.4x - updated 11-12-05

Started by artistsinhawaii, October 03, 2005, 02:47:34 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

artistsinhawaii

Quote from: JudyW on November 29, 2005, 04:56:55 AM
I don't understand why that would make a difference.  I was able to download other files from the Coppermine forums with no problems.

I'm really confused, too.  I have no problem with either of the downloads.  With IE, Firefox, or  Opera.   Try these below:

Link for Simple ecart for cpg 1.3x

Link for Simple ecart for cpg 1.4x


Dennis
Learn and live ... In January of 2011, after a botched stent attempt, the doctors told me I needed a multiple bypass surgery or I could die.  I told them I needed new doctors.

JudyW

I'm using Firefox.  I can download the Simple ecart for cpg 1.4x.  When I click on the 1.3x version I get a new window where I become a Guest and it asks for login information.  After filling out the login info, I venture back to the download and the same thing happens.
Judy Woodruff

artistsinhawaii

Judy,

I re-attached the 1.3 file to the bottom of the post above.  Will you give that one a try?

Dennis
Learn and live ... In January of 2011, after a botched stent attempt, the doctors told me I needed a multiple bypass surgery or I could die.  I told them I needed new doctors.

JudyW

YEAH!!!!

Thanks Dennis, I was able to download the bottom link.  Too late to do anything more.  Will get an early start tomorrow.
Judy Woodruff

Joachim Müller

the issue with people using IE being randomly thrown back to the login screen when they try to download an attachment is a known issue with the bbs app we use, it's related to the way IE handles headers. I haven't heard of a fix. As this only seems to happen in IE,our only possible recomendation is to use another browser but IE. After all, IE sucks anyway. Use Firefox.

JudyW

Dennis,

Thank you for this Paypal Mod.  I'm a photographer, but I do more way more computer stuff than I would like.  You'll never know how much I appreciate the ease of installation and the clarity of your directions.  It was the easiest part of re-designing my web site so far.

Thank you, thank you, thank you!

JudyW
Judy Woodruff

artistsinhawaii

Judy,

Awww, thanks, I really appreciated that.  Hope to see you list your site here when it's done.

Dennis
Learn and live ... In January of 2011, after a botched stent attempt, the doctors told me I needed a multiple bypass surgery or I could die.  I told them I needed new doctors.

netfalls

Hi,

How can I setup several languages for the Purchase with confidence part?

I know I have to edit the language file and but I do not know how to extract the text in the orders.php

Thanx
In my view you cannot claim to have seen something until you have photographed it

artistsinhawaii

@netfalls

Actually there is an easier way.  Since the entire paypal file is in php, you can use a simple if/else routine to decide what language certain text will appear in.  Just under your last if/else statement in orders.php.

Use the form:  (You can add all the <tr>s and <td>s as necessary to complete the block or create separate if/else statements for each block of text and just replace each text section using a different defined variable.  The defined variable in the example below is $quote.)

Quote
if ($USER['lang'] == 'german') {$quote = "
   Willkommen <br /><br />
   Add what text you want in German.
   "}
elseif ($USER['lang'] == 'spanish') {$quote =  "
   Bienvenido<br /><br />
   Add what text you want in Spanish.
  "}
else {$quote = "
   Welcome<br /><br />
   add what text you want in English.
"}

Then replace the "Buy with Confidence" section with your newly defined variable '$quote'.    Just becareful not to use (") in the text section if you use (") to embrace the entire block.

Dennis
Learn and live ... In January of 2011, after a botched stent attempt, the doctors told me I needed a multiple bypass surgery or I could die.  I told them I needed new doctors.

netfalls

Thanx, I tried but couldn't find where to place the code you gave me :-(
In my view you cannot claim to have seen something until you have photographed it

artistsinhawaii

Netfalls,

Try placing the if/else routine right above: 
QuotePrint <<<EOT 


Dennis
Learn and live ... In January of 2011, after a botched stent attempt, the doctors told me I needed a multiple bypass surgery or I could die.  I told them I needed new doctors.

netfalls

Hello,

I tried it but where ever I place it I get some error.
Can you tell me between witch lines I have to place it (based on the original ordes.php file)
Thanx
In my view you cannot claim to have seen something until you have photographed it

Tranz

What is the error? Are you using a WYSIWYG editor or a regular text editor?

netfalls

I'm using Dreamweaver 8
I always get something like this
Parse error: parse error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING
In my view you cannot claim to have seen something until you have photographed it

Joachim Müller

as Thu suggested: don't use a WYSIWYG editor like Dreamweaver unless you really, relayy know your way around. Use a plain text editor instead (notepad.exe is fine).

netfalls

The multi lang still doesn't work...

Another question

How do I insert that code? It doesn't allow the user to order before the terms and conditions acceptation


      <SCRIPT language=JavaScript type=text/javascript><!--
function agreesubmit(el)
{
document.creator.regSubmit.disabled = !el.checked;
}
function defaultagree()
{
if (!document.creator.regagree.checked)
{
alert("Please read/accept terms to submit form.");
return false;
}
return true;
}
// --></SCRIPT>

      <FORM name=creator onSubmit="return defaultagree();"
      action=https://www.paypal.com/cgi-bin/webscr
      method=post>
        <TABLE class=tborder style="BORDER-TOP-WIDTH: 0px" cellSpacing=0
      cellPadding=5 width="100%" align=center border=0>
        <TBODY>
        <TR>
          <TD class=windowbg2
            style="PADDING-BOTTOM: 8px; PADDING-TOP: 8px">&nbsp;</TD>
        </TR>
        <TR>
          <TD class=windowbg2 align=middle><LABEL for=regagree><INPUT
            class=check id=regagree onclick=agreesubmit(this); type=checkbox
            name=regagree> <B>I Agree</B></LABEL> </TD></TR></TBODY></TABLE><BR>
      <DIV align=center><INPUT type=submit value=Register name=regSubmit>
      </DIV></FORM>
      <SCRIPT language=JavaScript type=text/javascript>
document.creator.regagree.checked = false;
document.creator.regSubmit.disabled = true;
</SCRIPT>
In my view you cannot claim to have seen something until you have photographed it

tgontz

I am having trouble customizing the pricing options with this PayPal mod. The problem is that I would like to have 16 different prices, but only ten of them show up.

This is what my modified section from the orders.php file looks like:


// third option or "Standards and empty fields"
if ($pricing_setup=="Standards"||$pricing_setup=="standards"||$user1=="")
   {
   $Option1    = " 4\" x 6\" Print Only @5.00 USD ";
   $Desc1      = " 4\" x 6\" Print Only - $5.00 USD ";
   $Option2    = " 4\" x 6\" Print with 5\" x 7\" Matte @10.00 USD ";
   $Desc2      = " 4\" x 6\" Print with 5\" x 7\" Matte - $10.00 USD ";
   $Option3    = " 5\" x 7\" Print Only @12.50 USD ";
   $Desc3      = " 5\" x 7\" Print Only - $12.50 USD ";
   $Option4    = " 5\" x 7\" Print with 8\" x 10\" Matte @18.50 USD ";
   $Desc4      = " 5\" x 7\" Print with 8\" x 10\" Matte - $18.50 USD ";
   $Option5    = " 8\" x 10\" Print Only @16.00 USD ";
   $Desc5      = " 8\" x 10\" Print Only - $16.00 USD ";
   $Option6    = " 8\" x 10\" Print with 11\" x 14\" Matte @24.00 USD ";
   $Desc6      = " 8\" x 10\" Print with 11\" x 14\" Matte - $24.00 USD ";
   $Option7    = " 8\" x 12\" Print Only @16.00 USD ";
   $Desc7      = " 8\" x 12\" Print Only - $16.00 USD ";
   $Option8    = " 8\" x 12\" Print with 11\" x 14\" Matte @24.00 USD ";
   $Desc8      = " 8\" x 12\" Print with 11\" x 14\" Matte - $24.00 USD ";
   $Option9    = " 11\" x 14\" Print Only @23.00 USD ";
   $Desc9      = " 11\" x 14\" Print Only - $23.00 USD ";
   $Option10   = " 11\" x 14\" Print with 16\" x 20\" Matte @32.00 USD ";
   $Desc10     = " 11\" x 14\" Print with 16\" x 20\" Matte - $32.00 USD ";
   $Option11   = " 12\" x 18\" Print Only @32.00 USD ";
   $Desc11     = " 12\" x 18\" Print Only - $32.00 USD ";
   $Option12   = " 12\" x 18\" Print with 18\" x 24\" Matte @40.00 USD ";
   $Desc12     = " 12\" x 18\" Print with 18\" x 24\" Matte - $40.00 USD ";
   $Option13   = " 16\" x 20\" Print Only @39.00 USD ";
   $Desc13     = " 16\" x 20\" Print Only - $39.00 USD ";
   $Option14   = " 16\" x 20\" Print with 20\" x 24\" Matte @46.00 USD ";
   $Desc14     = " 16\" x 20\" Print with 16\" x 224\" Matte - $46.00 USD ";
   $Option15   = " 20\" x 30\" Print Only @45.00 USD ";
   $Desc15     = " 20\" x 30\" Print Only - $45.00 USD ";
   $Option16   = " 8 Wallets @8.00 USD ";
   $Desc16     = " 8 Wallets - $8.00 USD ";
}

artistsinhawaii

@tqonz.

The basic setup is for 10 entries to be displayed.  To display more, you have to add more.

Look in the < FORM > section for the dropdown list that is supposed to display the 16 choices.  It should have lines that look like:

Quote<SELECT onchange="ReadForm (this.form, false);">
                    <OPTION value='$Option1'>        $Desc1</OPTION>


Add 11 - 16 using the same pattern. 


Dennis


@netfalls,

I'm still searching for an answer for your question.  So far, I can do it on a client-side setup, but not on a server-side setup.

Dennis
Learn and live ... In January of 2011, after a botched stent attempt, the doctors told me I needed a multiple bypass surgery or I could die.  I told them I needed new doctors.

artistsinhawaii

@netfalls,

Boy, did I wrestle with this one.  Like you, I explored all the more common ways to try to get this to work.  Then it dawned on me that the approach was all wrong.  Here's a simpler method.


To add an agreement checkbox that must be ticked before an order can be processed carry out the following changes:

In the JavaScript area for the paypal mod add this function:

Quote
function Validate()
{
    if (document.paypalform.chkbx.checked)
        return true;
    alert('You must agree to all terms and conditions before submitting this form');
    return false;
}

Then just below the end of the script,  at the start of the paypal <FORM> , change the <form ... > heading to:


Quote
<form name="paypalform" action="https://www.paypal.com/cgi-bin/webscr" method="post" onsubmit="return Validate()" > 

Next, replace your checkbox entry with this:
Quote
<div align="center">
        <input type="checkbox" name="chkbx" value= "I agree to all terms and conditions"> I agree with all terms and conditions.
            <br /><br />
</div>

Only the ( name="chkbx" ) must be preserved, the value="string" and displayed text that follows can be altered.

Finally, replace the purchase button with:

Quote
<td >
          <input type="submit" value="Place Order" border="0" name="Place Order"
                           onclick =  "return ReadForm(paypalform, true);
                                            this.target = 'paypal'; " >
            <input type="hidden" name="add" value="1">
              &nbsp;
</td>

The ( value="Place Order" ) and ( name="Place Order" ) can be changed to suit your needs.



That should do it.

Dennis

(PS.. regarding the language if/else block.  Didn't you create an if/else block for different users?  You should be able to put the if/else for the language just below that block.  )
Learn and live ... In January of 2011, after a botched stent attempt, the doctors told me I needed a multiple bypass surgery or I could die.  I told them I needed new doctors.

netfalls

Thanx a lot it works great.

For the languages IMO it would be better to place them in the language file.
This would allow to adapt the options in several languages as well.

Anyway I'll try again with what you gave me.

Thanx
In my view you cannot claim to have seen something until you have photographed it