1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Need Help Adding PayPal Button To Page

Discussion in 'PHP' started by AdBuck, Feb 8, 2008.

  1. AdBuck

    AdBuck Banned

    Messages:
    142
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #21
    Still the button doesn't shows.
     
    AdBuck, Feb 8, 2008 IP
  2. The Critic

    The Critic Peon

    Messages:
    392
    Likes Received:
    7
    Best Answers:
    0
    Trophy Points:
    0
    #22
    How much of it is showing? Does the "Your message has been sent correctly" message display? When you view the HTML source does it show any of the form elements? Are you getting any errors? The more information you provide the easier it will be to fix your problem.
     
    The Critic, Feb 8, 2008 IP
  3. kmap

    kmap Well-Known Member

    Messages:
    2,215
    Likes Received:
    29
    Best Answers:
    2
    Trophy Points:
    135
    #23
    is the problem solved or not otherwise generate the button code from your paypal account and add the code below where php ends like this


    <%


    php code


    %>

    paypal code
     
    kmap, Feb 9, 2008 IP
  4. AdBuck

    AdBuck Banned

    Messages:
    142
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #24
    Yes, the only message that was showing was "Your message has been sent correctly."

    When I view the html source code it doesn't show the PayPal Button code there.

    No, I'm not getting any errors.
    -----------------------------------------------------------------------------
    The Critic, the code you have provided for me won't work, because Dreamweaver detected that the code is incorrect.
     
    AdBuck, Feb 9, 2008 IP
  5. The Critic

    The Critic Peon

    Messages:
    392
    Likes Received:
    7
    Best Answers:
    0
    Trophy Points:
    0
    #25
    You're thinking ASP; PHP uses <? and ?>. Besides, the OP already said that he doesn't want it placed outside of the tags for some reason, and since I don't know what the rest of the code looks like I'll just assume he's right somehow.

    And I don't suppose it said why...? Really, the more information you can provide the easier it will be to figure out why it isn't working properly. I'm guessing it doesn't understand heredoc syntax, so if you have no option but to use Dreamweaver then just echo it all out.

    
    $business=include('paypal.php');
    echo "Your message has been sent correctly.<br />
    <form action=\"https://www.paypal.com/cgi-bin/webscr\" method=\"post\">
    <input type=\"hidden\" name=\"cmd\" value=\"_xclick\">
    <input type=\"hidden\" name=\"business\" value=\"{$business}\">
    <input type=\"hidden\" name=\"item_name\" value=\"Premium Membership\">
    <input type=\"hidden\" name=\"amount\" value=\"{$rowe['price']}\">
    <input type=\"hidden\" name=\"no_shipping\" value=\"0\">
    <input type=\"hidden\" name=\"no_note\" value=\"1\">
    <input type=\"hidden\" name=\"currency_code\" value=\"USD\">
    <input type=\"hidden\" name=\"lc\" value=\"MX\">
    <input type=\"hidden\" name=\"bn\" value=\"PP-BuyNowBF\">
    <input type=\"image\" src=\"https://www.paypal.com/en_US/i/btn/x-click-but6.gif\" border=\"0\" name=\"submit\" alt=\"Make payments with PayPal - it's fast, free and secure!\"></form>";
    
    PHP:
     
    The Critic, Feb 9, 2008 IP