Solved

Does anyone know how to stop Paypal buttons having a 'wide' border...?

Posted on 2004-08-21
6
171 Views
Last Modified: 2010-04-07
Hello,

Right, ive got my table of products and am putting a 'add to cart' button in the cell to the right of eack cell with the product info in, heres the code for the table...


<table width="498"  border="0" cellpadding="6">
                <tr>
                  <td width="150" height="152" align="left"><img src="images/Candle%20Lamps/candlelampclear.jpg" width="150" height="150"></td>
                  <td width="214" align="left" valign="baseline" class="text"><span class="style2">clear candle lamp bc </span></td>
                  <td align="left" valign="baseline" class="text">&nbsp;</td>
                </tr>
                <tr>
                  <td colspan="2" align="left" valign="top" class="titles">40w clear candle lamp </td>
                  <td width="90" align="center" valign="baseline"><form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post">
                        <input type="hidden" name="cmd" value="_cart">
                        <input type="hidden" name="add" value="1">
                        <input type="hidden" name="bn" value="webassist.dreamweaver.4_0_1">
                        <input type="hidden" name="business" value="checkout@sparkyselectrical.co.uk">
                        <input type="hidden" name="item_name" value="g">
                        <input type="hidden" name="item_number" value="g">
                        <input type="hidden" name="amount" value="5">
                        <input type="hidden" name="currency_code" value="GBP">
                        <input type="hidden" name="return" value="http://www.sparkyselectrical.co.uk/success">
                        <input type="hidden" name="cancel_return" value="http://www.sparkyselectrical.co.uk/cancel">
                        <input type="hidden" name="receiver_email" value="checkout@sparkyselectrical.co.uk">
                        <input type="hidden" name="mrb" value="R-3WH47588B4505740X">
                        <input type="hidden" name="pal" value="ANNSXSLJLYR2A">
                        <input type="hidden" name="no_shipping" value="0">
                        <input type="hidden" name="no_note" value="0">
                        <input type="image" name="submit" src="http://images.paypal.com/images/x-click-but10.gif" alt="Make payments with PayPal - it's fast, free and secure!">
                  </form></td>
                </tr>
                <tr>
                  <td colspan="2" align="left" valign="top" class="titles">40w clear candle lamp branded </td>
                  <td align="center" valign="baseline"><form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post">
                      <input type="hidden" name="cmd" value="_cart">
                      <input type="hidden" name="add" value="1">
                      <input type="hidden" name="bn" value="webassist.dreamweaver.4_0_1">
                      <input type="hidden" name="business" value="checkout@sparkyselectrical.co.uk">
                      <input type="hidden" name="item_name" value="d">
                      <input type="hidden" name="item_number" value="d">
                      <input type="hidden" name="amount" value="4">
                      <input type="hidden" name="currency_code" value="GBP">
                      <input type="hidden" name="return" value="http://www.sparkyselectrical.co.uk/success.htm">
                      <input type="hidden" name="cancel_return" value="http://www.sparkyselectrical.co.uk/cancel.htm">
                      <input type="hidden" name="receiver_email" value="checkout@sparkyselectrical.co.uk">
                      <input type="hidden" name="mrb" value="R-3WH47588B4505740X">
                      <input type="hidden" name="pal" value="ANNSXSLJLYR2A">
                      <input type="hidden" name="no_shipping" value="0">
                      <input type="hidden" name="no_note" value="0">
                      <input type="image" name="submit" src="http://images.paypal.com/images/x-click-but10.gif" alt="Make payments with PayPal - it's fast, free and secure!">
                  </form></td>
                </tr>
                <tr>
                  <td colspan="2" align="left" valign="top" class="titles">60w clear candle lamp </td>
                  <td align="center" valign="baseline"><form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post">
                      <input type="hidden" name="cmd" value="_cart">
                      <input type="hidden" name="add" value="1">
                      <input type="hidden" name="bn" value="webassist.dreamweaver.4_0_1">
                      <input type="hidden" name="business" value="checkout@sparkyselectrical.co.uk">
                      <input type="hidden" name="item_name" value="5">
                      <input type="hidden" name="item_number" value="5">
                      <input type="hidden" name="amount" value="6">
                      <input type="hidden" name="currency_code" value="GBP">
                      <input type="hidden" name="return" value="http://www.sparkyselectrical.co.uk/success.htm">
                      <input type="hidden" name="cancel_return" value="http://www.sparkyselectrical.co.uk/cancel.htm">
                      <input type="hidden" name="receiver_email" value="checkout@sparkyselectrical.co.uk">
                      <input type="hidden" name="mrb" value="R-3WH47588B4505740X">
                      <input type="hidden" name="pal" value="ANNSXSLJLYR2A">
                      <input type="hidden" name="no_shipping" value="0">
                      <input type="hidden" name="no_note" value="0">
                      <input type="image" name="submit" src="http://images.paypal.com/images/x-click-but10.gif"  >
                  </form></td>
                </tr>
                <tr>
                  <td colspan="2" align="left" valign="top" class="titles">60w clear candle lamp branded </td>
                  <td width="90" align="center" valign="baseline"><form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post">
                      <input type="hidden" name="cmd" value="_cart">
                      <input type="hidden" name="add" value="1">
                      <input type="hidden" name="bn" value="webassist.dreamweaver.4_0_1">
                      <input type="hidden" name="business" value="checkout@sparkyselectrical.co.uk">
                      <input type="hidden" name="item_name" value="t">
                      <input type="hidden" name="item_number" value="t">
                      <input type="hidden" name="amount" value="4">
                      <input type="hidden" name="currency_code" value="GBP">
                      <input type="hidden" name="return" value="http://www.sparkyselectrical.co.uk/success.htm">
                      <input type="hidden" name="cancel_return" value="http://www.sparkyselectrical.co.uk/cancel.htm">
                      <input type="hidden" name="receiver_email" value="checkout@sparkyselectrical.co.uk">
                      <input type="hidden" name="mrb" value="R-3WH47588B4505740X">
                      <input type="hidden" name="pal" value="ANNSXSLJLYR2A">
                      <input type="hidden" name="no_shipping" value="0">
                      <input type="hidden" name="no_note" value="0">
                      <input type="image" name="submit" src="http://images.paypal.com/images/x-click-but10.gif" alt="Make payments with PayPal - it's fast, free and secure!">
                  </form></td>
                </tr>
               
              </table>


I was wondering if anyone knows how to stop the buttons spreading the table, so it looks the same as it does when working on it in dreamweaver...?

If not i would appreciate any ideas of a different layout...?

many thanks

mat
0
Comment
Question by:mhaysom123
  • 4
  • 2
6 Comments
 

Author Comment

by:mhaysom123
ID: 11858192
Forgot to say, I am using DW MX, with the Webassist Paypal extension, if that is any help...?
0
 
LVL 15

Expert Comment

by:Colosseo
ID: 11858218
Hi

I just installed the paypal extension and tried your page

do you mean stop the spreading horizontally or vertically?

Regards

Scott
0
 

Author Comment

by:mhaysom123
ID: 11859758
I think its vertical mainly, i think there is a slight border on the horizontal aswell, ideally i would like it to have no borders....thats if its possible....

thanks for looking

mat
0
Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

 
LVL 15

Accepted Solution

by:
Colosseo earned 250 total points
ID: 11859850
Hi

the forms that you have inside the td were spacing the form

I have had a go at removing all the forms (you had 4) and putting one around the entire table. there were several hidden tags which were the same for each entry so they are fixed in the main form.

item_name,item_number,amount,no_shipping,no_note were the fields which either did or i thought were likely to change. Each Add to cart image for each row  now calls the javascript function add_Item and passes the values for the above fields. These hidden fields are then set and the form submits.

It seems to work for me but maybe you can give it a try.

At the very least having the forms inside the table is what was causing the problem with the spacing

Hope that at least points you in the write direction

<html>
<head>

</head>
<script language="JavaScript" type="text/JavaScript">
 
  function add_Item(item_name,item_number,amount,no_shipping,no_note) {
    document.getElementById("item_name").value = item_name
    document.getElementById("item_number").value = item_number
    document.getElementById("amount").value = amount
    document.getElementById("no_shipping").value = no_shipping
    document.getElementById("no_note").value = no_note
    frm_Main.submit();
  }

</script>

<body>
<form target="paypal" name="frm_Main" action="https://www.paypal.com/cgi-bin/webscr" method="post">
                      <input type="hidden" name="cmd" value="_cart">
                      <input type="hidden" name="add" value="1">
                      <input type="hidden" name="bn" value="webassist.dreamweaver.4_0_1">
                      <input type="hidden" name="return" value="http://www.sparkyselectrical.co.uk/success.htm">
                      <input type="hidden" name="cancel_return" value="http://www.sparkyselectrical.co.uk/cancel.htm">
                      <input type="hidden" name="receiver_email" value="checkout@sparkyselectrical.co.uk">
                      <input type="hidden" name="mrb" value="R-3WH47588B4505740X">
                      <input type="hidden" name="pal" value="ANNSXSLJLYR2A">
                      <input type="hidden" name="business" value="checkout@sparkyselectrical.co.uk">
                      <input type="hidden" name="currency_code" value="GBP">
                                
                                <input type="hidden" name="item_name" value="">
                      <input type="hidden" name="item_number" value="">
                      <input type="hidden" name="amount" value="">
                      <input type="hidden" name="no_shipping" value="">
                      <input type="hidden" name="no_note" value="">

<table width="454" border="0" cellpadding="0">
                <tr>
                  <td width="150" height="152" align="left"><img src="images/Candle%20Lamps/candlelampclear.jpg" width="150" height="150"></td>
                  <td width="214" align="left" valign="baseline" class="text"><span class="style2">clear candle lamp bc </span></td>
                  <td width="90" align="left" valign="baseline" class="text">&nbsp;</td>
                </tr>
                <tr>
                  <td colspan="2" align="left" valign="top" class="titles">40w clear candle lamp </td>
                  <td width="90" align="center" ><input onClick="add_Item('g','g','5','0','0');" type="image" src="http://images.paypal.com/images/x-click-but10.gif" alt="Make payments with PayPal - it's fast, free and secure!"></td>
                </tr>
                <tr>
                  <td colspan="2" align="left" valign="top" class="titles">40w clear candle lamp branded </td>
                  <td align="center" valign="baseline"><input onClick="add_Item('d','d','6','0','0');" name="add" type="image" src="http://images.paypal.com/images/x-click-but10.gif" alt="Make payments with PayPal - it's fast, free and secure!"></td>
                </tr>
                <tr>
                  <td colspan="2" align="left" valign="top" class="titles">60w clear candle lamp </td>
                  <td align="center" valign="baseline"><input onClick="add_Item('5','5','6','0','0');" name="add" type="image" src="http://images.paypal.com/images/x-click-but10.gif" alt="Make payments with PayPal - it's fast, free and secure!"></td>
                </tr>
                <tr>
                  <td colspan="2" align="left" valign="top" class="titles">60w clear candle lamp branded </td>
                  <td width="90" align="center" valign="baseline"><input onClick="add_Item('t','t','4','0','0');" name="add" type="image" src="http://images.paypal.com/images/x-click-but10.gif" alt="Make payments with PayPal - it's fast, free and secure!">
                 </td>
                </tr>
               
              </table>
                     </form>

</body>
</html>

Cheers

Scott
0
 

Author Comment

by:mhaysom123
ID: 11863427
Hi,

Thats great, thank you!!!!! The table works just as i wanted/needed it to...!

Thanks for your time and your solution!

Many thanks,

Mat.
0
 

Author Comment

by:mhaysom123
ID: 11869415
Hello again, hopefully you will see this post...

I have made the table, the original one part of a template and now you have shown me that code i cant find a way of adding it to my template page, this is the code..


<table width="498"  border="0" cellpadding="6">
                  <tr>
                    <td width="150" height="152" align="left"><!-- TemplateBeginEditable name="image" --><img src="../cableandacc/images/accessories/crimps/roundlugcrimps.jpg" width="150" height="150"><!-- TemplateEndEditable --></td>
                    <td width="214" align="left" valign="baseline" class="text"><!-- TemplateBeginEditable name="description" --><span class="style2">Brief description of product, not sure, im just typing anything to fill up the space so i can see what it looks like with lots of words in and ..uh yeah whatever : ) </span><!-- TemplateEndEditable --></td>
                    <td align="left" valign="baseline" class="text">&nbsp;</td>
                  </tr>
                  <!-- TemplateBeginEditable name="product" -->
                  <tr>
                    <td colspan="2" align="left" valign="top" class="titles">gfj jdj jkds fj jdsjf fdsj </td>
                    <td width="90" align="center" valign="baseline"><form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post">
                        <input type="hidden" name="cmd" value="_cart">
                        <input type="hidden" name="add" value="1">
                        <input type="hidden" name="bn" value="webassist.dreamweaver.4_0_1">
                        <input type="hidden" name="business" value="checkout@sparkyselectrical.co.uk">
                        <input type="hidden" name="item_name" value="g">
                        <input type="hidden" name="item_number" value="g">
                        <input type="hidden" name="amount" value="5">
                        <input type="hidden" name="currency_code" value="GBP">
                        <input type="hidden" name="return" value="http://www.sparkyselectrical.co.uk/success">
                        <input type="hidden" name="cancel_return" value="http://www.sparkyselectrical.co.uk/cancel">
                        <input type="hidden" name="receiver_email" value="checkout@sparkyselectrical.co.uk">
                        <input type="hidden" name="mrb" value="R-3WH47588B4505740X">
                        <input type="hidden" name="pal" value="ANNSXSLJLYR2A">
                        <input type="hidden" name="no_shipping" value="0">
                        <input type="hidden" name="no_note" value="0">
                        <input type="image" name="submit" src="http://images.paypal.com/images/x-click-but10.gif" alt="Make payments with PayPal - it's fast, free and secure!">
                    </form></td>
                  </tr>
                  <!-- TemplateEndEditable -->
                </table>


what it is, i was planning on splitting the bottom row into the amount needed for each product, they vary alot, and then i was going to add a 'add to cart' button in each of the new split cells... i think i need to make that table a form and will that then hold the buttons in the way the code you added....?

hope you can help.

mat
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
create a website 10 75
Google Maps 7 72
Grunt No Clean Targets 6 109
Widget to get customer remakrs in our website. 3 48
Now that Expression Web 4.0 (http://www.microsoft.com/expression/products/Upgrade.aspx) is free if you buy or have the full version of Expression Web 3.0, now is the best time to  migrate from FrontPage to Expression Web (http://www.frontpage-to-exp…
Introduction In this tutorial, I'll explain how to create an animated progress meter in a wireframe prototype developed using Axure RP 7.0 - a leading prototyping tool for designing web sites and software. (For more information about Axure and gett…
The purpose of this video is to demonstrate how to properly insert a Vimeo Video into a WordPress site or Blog. This will be demonstrated using a Windows 8 PC. Go to your WordPress login page. This will look like the following: mywebsite.com/wp…
The purpose of this video is to demonstrate how to integrate Mailchimp with Facebook. This will be demonstrated using a Windows 8 PC. Mailchimp and Facebook will be used. Log into your Mailchimp account. : Click on your name. Go to Account Setti…

867 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

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now