Results 1 to 4 of 4
  1. #1
    Join Date
    Dec 2007
    Posts
    54
    Plugin Contributions
    0

    Default Credit Card Sidebox - adding link to image?

    Please help, how to add a www link to the images in the following code:

    $content = '';
    $content .= '<div id="' . str_replace('_', '-', $box_id . 'Content') . '" class="sideBoxContent">'

    . "\n";
    $content .= '<img id="ccMC" class="cc_img" src="images/cc_logos/logo_ccMC.gif" />'

    . "\n" .'<img id="ccVisa" class="cc_img" src="images/cc_logos/logo_ccVisa.gif" />' . "\n" .
    '<img id="ccAmex" class="cc_img" src="images/cc_logos/logo_ccAmex.gif" />' . "\n" .
    '<img id="ccDiners" class="cc_img" src="images/cc_logos/logo_ccEcheck.gif" />' . "\n" .
    '<img id="ccOPG" class="cc_img" src="images/cc_logos/logo_ccEcheck.gif" />' . "\n";
    $content .= '</div>' . "\n";
    ?>


    Thank you!

    BR,
    ivan

  2. #2
    Join Date
    Sep 2008
    Location
    London UK
    Posts
    101
    Plugin Contributions
    0

    Default Re: Credit Card Sidebox - adding link to image?

    same as you would any other link ... e.g.
    Code:
    $content .= '<img id="ccMC" class="cc_img" src="images/cc_logos/logo_ccMC.gif" />'
    change to
    Code:
    $content .= '<a href="url here"><img id="ccMC" class="cc_img" src="images/cc_logos/logo_ccMC.gif" /></a>'
    unless misreading your question ?

  3. #3
    Join Date
    Dec 2007
    Posts
    54
    Plugin Contributions
    0

    Default Re: Credit Card Sidebox - adding link to image?

    I tried with this:

    Code:
    <a href="http://www.something.com/" onclick="window.open(this.href,'newwin'); return false;"><img id="ccMC" class="cc_img" src="images/cc_logos/logo_ccMC.gif" /></a>
    but it didn't work, made everything after the sidebox containing this code disappear, including the center content.


    Your simpler code works fine, thank you!

  4. #4
    Join Date
    Sep 2008
    Location
    London UK
    Posts
    101
    Plugin Contributions
    0

    Default Re: Credit Card Sidebox - adding link to image?

    sorry .. why using onclick to open a new window ?

    just add
    Code:
    target="_blank"
    to the <a href

    if you really need to use onclick then change to
    Code:
    onclick="window.open(this.href,\'newwin\');
    unless ... as I said am misreading your question

 

 

Similar Threads

  1. Credit Card Image in sidebox
    By joemind in forum Basic Configuration
    Replies: 1
    Last Post: 11 Jun 2009, 04:55 PM
  2. Credit Card Sidebox & shopping cart with image
    By deemurphy in forum Basic Configuration
    Replies: 1
    Last Post: 25 Aug 2007, 03:59 PM
  3. Credit card sidebox image and box height
    By beasleybub in forum Basic Configuration
    Replies: 19
    Last Post: 24 May 2007, 07:17 PM
  4. Adding ScanAlert to Credit Card Sidebox
    By gems14k in forum Basic Configuration
    Replies: 0
    Last Post: 27 Nov 2006, 08:01 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR