Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls

How to add CVV2 help link and description?

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 02-14-2005, 11:29 AM
 
Ryano Ryano is offline
 

Senior Member
  
Join Date: Jun 2004
Posts: 192
 

Default How to add CVV2 help link and description?

I noticed that the new versions of x-cart, 4.0 and higher have the CVV2 code help link with the description included in their cart program.

I have been wanting to intergrate this into my version 3.5.8 and I was wondering if anyone would have the code from the 4.0 version that will work within the 3.5 versions. I'm sure a lot of other people would find lots of use of this as well who are using the older versions. Thanks in advance!
__________________
xcart v3.5.8 (Unix)
and
xcart v4.0.13
Reply With Quote
  #2  
Old 02-14-2005, 04:02 PM
 
markwhoo markwhoo is offline
 

X-Adept
  
Join Date: Nov 2003
Posts: 799
 

Default Re: How to add CVV2 help link and description?

Quote:
Originally Posted by Ryano
I noticed that the new versions of x-cart, 4.0 and higher have the CVV2 code help link with the description included in their cart program.

I have been wanting to intergrate this into my version 3.5.8 and I was wondering if anyone would have the code from the 4.0 version that will work within the 3.5 versions. I'm sure a lot of other people would find lots of use of this as well who are using the older versions. Thanks in advance!

Look at register_ccinfo.tpl

Around line 80 you will see something like this:

Code:
{if #safeCCNum# eq ""} <input type=text name=card_cvv2 size=4 maxlength=4 value=""> CVV2 {else} {#safeCCcvv2#} <input type=hidden name=card_cvv2 value="{#safeCCcvv2#}"> {/if} </td> </tr> {/if}

Change to:

Code:
{if #safeCCNum# eq ""} <input type=text name=card_cvv2 size=4 maxlength=4 value=""> <a target="_blank" href="https://www.your_name.com/ccInfo/cvv.htm"> <font color="#000080">CVV2 Help</font></a> {else} {#safeCCcvv2#} <input type=hidden name=card_cvv2 value="{#safeCCcvv2#}"> {/if} </td> </tr> {/if}

Create a file in the root called ccInfo and an htm or html page named cvv.htm and add your description, pics, info etc.

If the folder name is changed or the page name is changed remember to change this in the url.

Also remember to change the domain name to yours in the url.


Hope this helps. I posted this as an answer in here somewhere prior, but not sure where it is. I have slept since then.
__________________
vs 4.1.12
Reply With Quote
  #3  
Old 02-14-2005, 06:05 PM
 
Ryano Ryano is offline
 

Senior Member
  
Join Date: Jun 2004
Posts: 192
 

Default

Hi Mark,
Thanks a lot for your reply. I would like to basically copy exactly how the newer versions of x-cart have it set up with the little question mark icon to click on and the images already in place on the pop-up window that they have. Here is the link to the pop-up on their demo.

https://www.x-cart.com/demo/popup_info.php?action=CVV2

Is there a way that I can copy the exact look of the new one into my 3.5.8 cart? Thanks again!
__________________
xcart v3.5.8 (Unix)
and
xcart v4.0.13
Reply With Quote
  #4  
Old 02-14-2005, 06:15 PM
 
markwhoo markwhoo is offline
 

X-Adept
  
Join Date: Nov 2003
Posts: 799
 

Default

Quote:
Originally Posted by Ryano
Hi Mark,
Thanks a lot for your reply. I would like to basically copy exactly how the newer versions of x-cart have it set up with the little question mark icon to click on and the images already in place on the pop-up window that they have. Here is the link to the pop-up on their demo.

https://www.x-cart.com/demo/popup_info.php?action=CVV2

Is there a way that I can copy the exact look of the new one into my 3.5.8 cart? Thanks again!

You should have access to this in your file download area.

I see no problems doing this, you will just need to create the new labels in your languages area to have correct text where required in the tpl files.

You will need to add the pop up link w/pic from register_ccinfo.tpl and then have the skin1/main/popup_help_link.tpl as well as the inages used in the pop up which can be found in the images file.

Should be a piece of cake.
__________________
vs 4.1.12
Reply With Quote
  #5  
Old 02-14-2005, 07:57 PM
 
Ryano Ryano is offline
 

Senior Member
  
Join Date: Jun 2004
Posts: 192
 

Default

Thanks for the great advice Mark! I have it all working except for the popup. When I click on it, the writing and the CC pics are not there inside the popup.

So far I changed out my register_ccinfo.tpl code with the new one, and saved the skin1/main/popup_help_link.tpl into the correct directory. Uploaded the quesitons mark image from 4.11 as well. I also added the label lbl_popup_help. What am I missing here to get the info to show up inside the popup? Thanks once again!
__________________
xcart v3.5.8 (Unix)
and
xcart v4.0.13
Reply With Quote
  #6  
Old 02-14-2005, 08:13 PM
 
markwhoo markwhoo is offline
 

X-Adept
  
Join Date: Nov 2003
Posts: 799
 

Default

Quote:
Originally Posted by Ryano
Thanks for the great advice Mark! I have it all working except for the popup. When I click on it, the writing and the CC pics are not there inside the popup.

So far I changed out my register_ccinfo.tpl code with the new one, and saved the skin1/main/popup_help_link.tpl into the correct directory. Uploaded the quesitons mark image from 4.11 as well. I also added the label lbl_popup_help. What am I missing here to get the info to show up inside the popup? Thanks once again!

This may sound lame, but you copied the text seen in the demo into the new label didn't you?

And added the CC pics as well?
__________________
vs 4.1.12
Reply With Quote
  #7  
Old 02-14-2005, 08:15 PM
 
Ryano Ryano is offline
 

Senior Member
  
Join Date: Jun 2004
Posts: 192
 

Default

DO'OH! lol No I didn't. I didn't know where to copy that part. Wasn't sure what the label would be called that goes in the popup? I uploaded the images to the images folder, but they aren't showing up in the popup. Do I need to do something else with them besides upload them? I can post the coding for all of what I have done if you need it. Thanks a lot Mark.
__________________
xcart v3.5.8 (Unix)
and
xcart v4.0.13
Reply With Quote
  #8  
Old 02-14-2005, 08:33 PM
 
Ryano Ryano is offline
 

Senior Member
  
Join Date: Jun 2004
Posts: 192
 

Default

Here is the coding for anyone else who wants to do this mod, and also to help find out what I am missing. This is what I have done so far.

Changed this code in register_ccinfo.tpl:

Code:
{if $config.disable_ccinfo eq "N"} <tr valign=middle> <td align=right>{$lng.lbl_cc_cvv2}</td> <td><font class=Star>{if $config.General.check_cc_number eq "Y"}*{else}{/if}</font></td> <td nowrap colspan=3> {if #safeCCNum# eq ""} <input type=text name=card_cvv2 size=4 maxlength=4 value=""> {else}

Change to:
Code:
{if $payment_cc_data.disable_ccinfo eq "N" || ($payment_cc_data.disable_ccinfo eq "" && $config.General.enable_manual_cc_cvv2 eq 'Y')} <TR valign="middle"> <TD align="right">{$lng.lbl_cc_cvv2}</TD> <TD><FONT class="Star"><SPAN id="cvv2_star">{if $config.General.check_cc_number eq "Y" || $smarty.get.mode eq 'checkout'}*{else}{/if}</SPAN></FONT></TD> <TD nowrap colspan="3"> {if #safeCCNum# eq ""} <TABLE cellspacing="0" cellpadding="0" border="0"> <TR> <TD valign="middle"><INPUT type="text" name="card_cvv2" size="4" maxlength="4" value="{if $smarty.get.err eq 'fields'}{$userinfo.card_cvv2}{/if}"></TD> <TD valign="middle">{include file="main/popup_help_link.tpl" section="cvv2"}</TD> {if $smarty.get.err eq 'fields' && $userinfo.card_cvv2 eq ''} <TD><FONT class="Star">&lt;&lt;</FONT></TD> {/if} </TR> </TABLE> {else}

Added skin1/main/popup_help_link.tpl which looks like this:
Code:
{* $Id: popup_help_link.tpl,v 1.4.2.1 2004/11/23 10:48:56 max Exp $ *} {if $config.UA.platform eq 'MacPPC' && $config.UA.browser eq 'MSIE'} [img]{$ImagesDir}/question_button.gif[/img] {else} [img]{$ImagesDir}/question_button.gif[/img]{/if}

Next I added lng_lbl_popup to the languages area, and then I uploaded question_button.gif into /images.
__________________
xcart v3.5.8 (Unix)
and
xcart v4.0.13
Reply With Quote
  #9  
Old 02-14-2005, 08:52 PM
 
Ryano Ryano is offline
 

Senior Member
  
Join Date: Jun 2004
Posts: 192
 

Default

I logged into the admin for the 4.11 demo and found the that they have a txt_what_is_cvv2 in languages with the CVV2 description so I have added that too. I think I am missing one more file or something that brings up the txt language and the images since neither is still showing.
__________________
xcart v3.5.8 (Unix)
and
xcart v4.0.13
Reply With Quote
  #10  
Old 02-14-2005, 09:02 PM
 
markwhoo markwhoo is offline
 

X-Adept
  
Join Date: Nov 2003
Posts: 799
 

Default

Quote:
Originally Posted by Ryano
DO'OH! lol No I didn't. I didn't know where to copy that part. Wasn't sure what the label would be called that goes in the popup? I uploaded the images to the images folder, but they aren't showing up in the popup. Do I need to do something else with them besides upload them? I can post the coding for all of what I have done if you need it. Thanks a lot Mark.

This is the code from the new version of the register_ccinfo.tpl we are speaking of.

Code:
{if $payment_cc_data.disable_ccinfo eq "N" || ($payment_cc_data.disable_ccinfo eq "" && $config.General.enable_manual_cc_cvv2 eq 'Y')} <TR valign="middle"> <TD align="right">{$lng.lbl_cc_cvv2}</TD> <TD><FONT class="Star"><SPAN id="cvv2_star">{if $config.General.check_cc_number eq "Y" || $smarty.get.mode eq 'checkout'}*{else}{/if}</SPAN></FONT></TD> <TD nowrap colspan="3"> {if #safeCCNum# eq ""} <TABLE cellspacing="0" cellpadding="0" border="0"> <TR> <TD valign="middle"><INPUT type="text" name="card_cvv2" size="4" maxlength="4" value="{if $smarty.get.err eq 'fields'}{$userinfo.card_cvv2}{/if}"></TD> <TD valign="middle">{include file="main/popup_help_link.tpl" section="cvv2"}</TD> {if $smarty.get.err eq 'fields' && $userinfo.card_cvv2 eq ''} <TD><FONT class="Star">&lt;&lt;</FONT></TD> {/if} </TR> </TABLE> {else} {#safeCCcvv2#} <INPUT type="hidden" name="card_cvv2" value="{#safeCCcvv2#}"> {/if} </TD> </TR> {/if}

Now the tidbit of info we are adding here is:
Code:
<TD valign="middle">{include file="main/popup_help_link.tpl" section="cvv2"}</TD>

Now this is the popup_help_link.tpl:
Code:
{* $Id: popup_help_link.tpl,v 1.4.2.1 2004/11/23 10:48:56 max Exp $ *} {if $config.UA.platform eq 'MacPPC' && $config.UA.browser eq 'MSIE'} [img]{$ImagesDir}/question_button.gif[/img] {else} [img]{$ImagesDir}/question_button.gif[/img]{/if}

lbl_popup_help description and value is:
Code:
What is it?

You will need to copy over the popup_info.php into your xcart/include folder.

You will need to copy over the skin1/help/popup_info.tpl

It makes a reference to the skin1_admin.css, if you do not have this, it refers to your skin1.css.

Ensure you have dialog_message.tpl in skin1

Ensure you have skin1/main/error_page_not_found.tpl

Add lbl_close_window (self explanitory)

Copy over close.gif

And you will need the skin1/help/hlp_cvv2.tpl



Take a look into some of these files and see if there is another image you may need or another label.

This should get you well underway to the CVV2 pop world though.


Hope this helps, if there is something else, I will try to look into it for you, otherwise follow the yellow brick road to success!
__________________
vs 4.1.12
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 03:27 PM.

   

 
X-Cart forums © 2001-2020