Results 1 to 5 of 5
  1. #1
    Join Date
    Apr 2008
    Posts
    446
    Plugin Contributions
    1

    Default popup_coupon_help not working - window too small

    Hello. I apologize if this was already discussed or solved. I've tried all afternoon to look for a solution but couldn't find any that would work.

    I'm currently using ZC 1.5.7d. On One Page Checkout or the native ZC checkout system in the discount coupon box, if one enters a coupon code, the coupon code entered, after processing the form, appears as a link that when clicked opens up a popup window. The popup window however is a tiny one no bigger than 100px by 100px.

    I thought by modifying the code in the includes/modules/popup_coupon_help/jscript_main.php would do the trick, but that didn't work either. I tried commenting the code in that file and replaced it with any other from the other popup pages but for some bizarre reason I cannot make the window much bigger than approximately 300px by 300px, and no matter what it's always a square window which I find odd, since the height and width are set for a rectangular window.

    Is there anything I'm missing, doing wrong for this window to behave in this manner? Anyone else having the same issue or it's just me?

    Thank you for any help.

  2. #2
    Join Date
    Jan 2004
    Location
    N of San Antonio TX
    Posts
    9,154
    Plugin Contributions
    11

    Default Re: popup_coupon_help not working - window too small

    Perhaps a link to play?

  3. #3
    Join Date
    Apr 2008
    Posts
    446
    Plugin Contributions
    1

    Default Re: popup_coupon_help not working - window too small

    Quote Originally Posted by dbltoe View Post
    Perhaps a link to play?
    So sorry! I've been stuck with work. Father's day sale is keeping us very busy. Website www.byvalenti.com Thank you!

  4. #4
    Join Date
    Apr 2008
    Posts
    446
    Plugin Contributions
    1

    Default Re: popup_coupon_help not working - window too small

    And I just realized without a code you can't play to figure out what's happening. Sorry, super overwhelmed at the moment. Use code ILOVEBVO to play around with the module and see the behavior of the popup. No need to register for an account. Thank you!

  5. #5
    Join Date
    Apr 2008
    Posts
    446
    Plugin Contributions
    1

    Default Re: popup_coupon_help not working - window too small

    Finally I've had some time, so I've been playing around with this popup window trying to make it work, and boy am I frustrated. NO matter what I cannot make it work, the way it should. I've borrowed pieces of code from other popup windows, even tried zen_colorbox and it worked on desktop, but failed on iPhone.

    The most I was able to accomplish was enlarge the window to 452 x 393 pixels, funny numbers I have not the slightest idea where they come from. That was done by changing the includes/modules/pages/popup_coupon_help/jscript_main.php

    from this
    PHP Code:
    <script type="text/javascript">
    var 
    i=0;
    function 
    resize() {
      if (
    navigator.appName == 'Netscape'i=10;
      if (
    document.images[0]) {
      
    imgHeight document.images[0].height+45-i;
      
    imgWidth document.images[0].width+30;
      var 
    height screen.height;
      var 
    width screen.width;
      var 
    leftpos width imgWidth 2;
      var 
    toppos height imgHeight 2;
      
    window.moveTo(leftpostoppos);
      
    window.resizeTo(imgWidthimgHeight);
      }
      
    self.focus();
    }
    </script> 
    to this
    PHP Code:
    <!--<script type="text/javascript">
    var 
    i=0;
    function 
    resize() {
      if (
    navigator.appName == 'Netscape'i=10;
      if (
    document.images[0]) {
      
    imgHeight document.images[0].height+45-i;
      
    imgWidth document.images[0].width+30;
      var 
    height screen.height;
      var 
    width screen.width;
      var 
    leftpos width imgWidth 2;
      var 
    toppos height imgHeight 2;
      
    window.moveTo(leftpostoppos);
      
    window.resizeTo(imgWidthimgHeight);
      }
      
    self.focus();
    }
    </script>-->
    <script type="text/javascript">
    function couponpopupWindow(url) {
      window.open(url,'couponpopupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,copyhistory=no,width=450,height=320,screenX=150,screenY=150,top=150,left=150')
    }
    </script> 
    Even changing the width and height the window remains the same size 452 x 393 pixels.

    I'm tempted to remove the link for the popup completely from the actual ot_coupon file, and leave it as a text as a reference of the code being used.

    My limited php knowledge seems to be not enough to tackle this on my own. If someone could help me out, it would be really appreciated.

 

 

Similar Threads

  1. v151 Banner set to No new window not working
    By EC web in forum Basic Configuration
    Replies: 10
    Last Post: 14 Jan 2016, 12:59 PM
  2. Pop up image size.. image right size, window too small
    By grayceworks in forum Templates, Stylesheets, Page Layout
    Replies: 15
    Last Post: 18 Dec 2011, 06:25 AM
  3. "Larger image" window is too small
    By FastEddie in forum Setting Up Categories, Products, Attributes
    Replies: 6
    Last Post: 25 May 2011, 12:56 AM
  4. Popup images window too small - doesn't resize
    By davenz in forum Setting Up Categories, Products, Attributes
    Replies: 0
    Last Post: 15 Oct 2010, 03:44 AM

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