Page 1 of 4 123 ... LastLast
Results 1 to 10 of 31
  1. #1
    Join Date
    Jul 2005
    Posts
    220
    Plugin Contributions
    0

    Default Why no support on this site - Sidebox image size question - need help please

    Have asked this question and after doing a search through this site it seems that far to many requests for help go unanswered as well.

    Trying to get some support to determine how how to change the sidebox image size using this code from the template file

    $content .= '<div align="center"><a href="' . zen_href_link(zen_get_info_page($random_whats_new_sidebox_product->fields['products_id']), 'products_id=' . $random_whats_new_sidebox_product->fields['products_id']) . '">' . zen_image(zen_get_small_image($random_whats_new_sidebox_product->fields['products_image']), $random_whats_new_sidebox_product->fields['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a><br /><a href="' . zen_href_link(zen_get_info_page($random_whats_new_sidebox_product->fields['products_id']), 'products_id=' . $random_whats_new_sidebox_product->fields['products_id']) . '">' . $random_whats_new_sidebox_product->fields['products_name'] . '</a><br />' . $whats_new_price . '</div>';
    ?>


    In this code, it uses SMALL_IMAGE_WIDTH

    We do not want to change this in our admin but instead specify MANUALLY and image size here or use the image size used in the shopping cart

    Tried replacing those variables with the IMAGE_SHOPPING_CART_WIDTH and this had no effect.

    Can someone please assist with this question?

    Thank You

  2. #2
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: Why no support on this site - Sidebox image size question - need help please

    what exact size do you want ?

    Since you don't want to have admin control over it, and want to change just the function of this file, why not just replace the constant with the exact number?

    Code:
    ...ucts_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a><b...
    becomes:
    Code:
    ...ucts_name'], 85, 130 ) . '</a><b...
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Jul 2005
    Posts
    220
    Plugin Contributions
    0

    Default Re: Why no support on this site - Sidebox image size question - need help please

    Thank You very much for responding

    I did change this to the figure as you suggested and it still just displayed the image the other size (100X80)

    I changed it to 50X40

    Not sure what is causing the problem

  4. #4
    Join Date
    Mar 2004
    Posts
    16,042
    Plugin Contributions
    5

    Default Re: Why no support on this site - Sidebox image size question - need help please

    Have asked this question and after doing a search through this site it seems that far to many requests for help go unanswered as well.
    You are aware that everyone here is a volunteer,

    Sometimes it takes the right person to come across the question,
    If you want it to use the same size image as in the product you can also change
    SMALL_IMAGE_WIDTH
    to
    MEDIUM_IMAGE_WIDTH
    Zen cart PCI compliant Hosting

  5. #5
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: Why no support on this site - Sidebox image size question - need help please

    aha ... more information ... that always helps.


    Perhaps you can supply the URL where this is happening?

    EDIT: I clicked on the links in your signature, and they took me elsewhere. Seems you need to update them. Typing them manually takes me to a Zen Cart v1.2.x site.
    What are your settings for Proportional Images?
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  6. #6
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,761
    Plugin Contributions
    9

    Default Re: Why no support on this site - Sidebox image size question - need help please

    JLA,

    I am just one of the community posters..but take issue with your Post title...

    You post a specific Code question in "First Steps & General Customization Issues", and then expect immediate assistance...

    You should have posted in a more appropriate area. JMO
    Last edited by kobra; 17 Aug 2006 at 01:56 AM.
    Zen-Venom Get Bitten

  7. #7
    Join Date
    Jul 2005
    Posts
    220
    Plugin Contributions
    0

    Default Re: Why no support on this site - Sidebox image size question - need help please

    Sorry but yesterday we made several posts in one thread and have made a few posts in the recent past - all of which went unanswered.

    I do understand that there are all volunteers but after being around for awhile it seems that there responses were much quicker in the past.

    I guess I just am used to the faster pace of some other projects and their support

    I do apologize.

    I fixed the signature - apparently it was messed up and went the same place all my private messages went when the board did the switch

    As far as demo

    We currently have box on our forum at http://www.jlaforums.com

    that are pulling data from our store at http://www.jlaenterprises.net

    We have one which is a 468X60 (which in the one we are having trouble with) and two more on the index page (one in the right side bar - scroll down) and the other on the left side bar further down

    The two sidebar ones are functioning properly for the most part but we had to disable the image on the top one since we could not get the image to be smaller.

    I will create a demo page with the suggest code change to show the image has not changed

    Will post the link in a min

    Thanks

    Thanks

  8. #8
    Join Date
    Jul 2005
    Posts
    220
    Plugin Contributions
    0

    Default Re: Why no support on this site - Sidebox image size question - need help please

    Ok

    Here is a test page

    http://www.jlaforums.com/test1.php

    As you see, the image that appears is 100X80 even though we changed the code in the template (and yes, we are positive we used the correct template file - it was checked and double checked)

    to this

    $content .= '<div align="center"><a href="' . zen_href_link(zen_get_info_page($random_whats_new_sidebox_product->fields['products_id']), 'products_id=' . $random_whats_new_sidebox_product->fields['products_id']) . '">' . zen_image(zen_get_small_image($random_whats_new_sidebox_product->fields['products_image']), $random_whats_new_sidebox_product->fields['products_name'], 50, 40) . '</a><br /><a href="' . zen_href_link(zen_get_info_page($random_whats_new_sidebox_product->fields['products_id']), 'products_id=' . $random_whats_new_sidebox_product->fields['products_id']) . '">' . $random_whats_new_sidebox_product->fields['products_name'] . '</a><br />' . $whats_new_price . '</div>';
    ?>


    But as you can see on the test URL, it is displaying the product at 100X80 pixels

    Not sure why this is

    Also, looking to display more than 1 product. I assume that the code is here, but not sure what to change

    switch (true) {
    case (SHOW_NEW_PRODUCTS_LIMIT == '0'):
    $display_limit = '';
    break;
    case (SHOW_NEW_PRODUCTS_LIMIT == '1'):
    $display_limit = " and date_format(p.products_date_added, '%Y%m') >= date_format(now(), '%Y%m')";
    break;
    case (SHOW_NEW_PRODUCTS_LIMIT == '30'):
    $display_limit = ' and TO_DAYS(NOW()) - TO_DAYS(p.products_date_added) <= 30';
    break;
    case (SHOW_NEW_PRODUCTS_LIMIT == '60'):
    $display_limit = ' and TO_DAYS(NOW()) - TO_DAYS(p.products_date_added) <= 60';
    break;
    case (SHOW_NEW_PRODUCTS_LIMIT == '90'):
    $display_limit = ' and TO_DAYS(NOW()) - TO_DAYS(p.products_date_added) <= 90';
    break;
    case (SHOW_NEW_PRODUCTS_LIMIT == '120'):
    $display_limit = ' and TO_DAYS(NOW()) - TO_DAYS(p.products_date_added) <= 120';
    break;
    }

    $random_whats_new_sidebox_product_query = "select SQL_CACHE p.products_id, p.products_image, p.products_tax_class_id, p.products_price
    from " . TABLE_PRODUCTS . " p
    where p.products_status = '1' and p.products_quantity >= '1' " . $display_limit . "
    limit " . MAX_RANDOM_SELECT_NEW;

    $random_whats_new_sidebox_product = zen_random_select($random_whats_new_sidebox_product_query);



    if ($random_whats_new_sidebox_product->RecordCount() > 0 ) {
    $whats_new_price = zen_get_products_display_price($random_whats_new_sidebox_product->fields['products_id']);
    $random_whats_new_sidebox_product->fields['products_name'] = zen_get_products_name($random_whats_new_sidebox_product->fields['products_id']);
    $random_whats_new_sidebox_product->fields['specials_new_products_price'] = zen_get_products_special_price($random_whats_new_sidebox_product->fields['products_id']);
    require($template->get_template_dir('tpl_whats_new_banner1.php',DIR_WS_TEMPLATE, $current_page_base,'sideboxes'). '/tpl_whats_new_banner1.php');
    $title = BOX_HEADING_WHATS_NEW;
    $left_corner = false;
    $right_corner = false;
    $right_arrow = false;
    $title_link = FILENAME_PRODUCTS_NEW;
    require($template->get_template_dir($column_box_default, DIR_WS_TEMPLATE, $current_page_base,'common') . '/' . $column_box_default);



    }
    ?>

  9. #9
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,761
    Plugin Contributions
    9

    Default Re: Why no support on this site - Sidebox image size question - need help please

    JLA,

    Point taken...but realize that when you post and also specify the solution that you want. i.e.
    We do not want to change this in our admin but instead specify MANUALLY and image size here or use the image size used in the shopping cart
    That this limits the number of individuals that can answer this.. You need some one who knows code with more expertise than you have. And I suppose that these are far and few between.
    Zen-Venom Get Bitten

  10. #10
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: Why no support on this site - Sidebox image size question - need help please

    What are your settings for Proportional Images in Admin->Config->Images ?
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

 

 
Page 1 of 4 123 ... LastLast

Similar Threads

  1. Need help with this question
    By Flex37 in forum General Questions
    Replies: 2
    Last Post: 5 Sep 2009, 01:53 PM
  2. Desperately need help on this please
    By karenkte in forum General Questions
    Replies: 6
    Last Post: 29 May 2008, 07:22 PM
  3. Please Help!!! This Is My Last Question!!!
    By personalisedpresent in forum Templates, Stylesheets, Page Layout
    Replies: 6
    Last Post: 13 Aug 2006, 10:59 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