Jump to content

De Dokta

Members
  • Content count

    329
  • Joined

  • Last visited

  • Days Won

    15

Posts posted by De Dokta


  1. @@vampirehunter

     

    1. be careful with the brackets:  if((($PHP_SELF == 'index.php') and ($category_depth == 'top')) || ($PHP_SELF == 'shopping_cart.php'))

    also possible: if(($PHP_SELF == 'index.php' and $category_depth == 'top') || ($PHP_SELF == 'shopping_cart.php'))

    You just have to make sure that the program can "distinguish" which elements belong to one and which to the other condition.

    2. you can't use ($category_depth == 'top') in that case because there are no different levels in the shopping cart as in the categories. ;) With ($category_depth == 'top') the condition can never be true and therefore on the cart page the box will never disappear.

     

    J.J.


  2. @@gvv

     

    Try this: In application_top.php in  - case 'add_to_wishlist' - replace: 

                                  tep_redirect(tep_href_link('wishlist.php', tep_get_all_get_params($parameters)));
                                  break;
    /* /Wish List End */                         
    

    with:

                                  if(WISHLIST_REDIRECT ==  'Yes') tep_redirect(tep_href_link('wishlist.php', tep_get_all_get_params($parameters)));
                                  break;
    /* /Wish List End */                         
    

  3. @@gvv

     

    Yes! For includes/modules/new_products.php e.g. it should be something like this:

     

                          $new_prods_content .= tep_draw_button(TEXT_ADD_WISHLIST, 'glyphicon glyphicon-heart', tep_href_link('wishlist.php', tep_get_all_get_params(array('action')) . 'action=add_to_wishlist&products_id=' . $new_products['products_id']), NULL, NULL, 'btn-default btn-sm');

     

    Add it where you want the wishlist button to appear. And in other modules similar....

     

    J.J.
     


  4. Hi

     

    Is it possible to change the article images with the selection of options? I have found several addons, tested them, but could not get to work one of them.

    So, I tried myself to find a simple solution:
    I added a new column 'options_values_image' to table 'products_attributes', an ajax script to product_info.php and wrote a new file to select the appropriate image for each option.

    Work half done: In the frontend, apart from some minor (cosmetic) issues the image change works as intended - with a single product image the change is really easy (demo: http://www.video-stuff.de/demo/bootstrap/matrox-g200-p-1.html- option: Model), with a set of images it was a bit more complicated but also possible (demo: http://www.video-stuff.de/demo/bootstrap/samsung-galaxy-p-28.html - option:case). And the colorbox also works.

    But where I currently really stuck, is the question how to get the options images into the database in the admin area? It's surely possible to add something for that to the products_attributes menu. But is the products_attributes really worth the effort? You can use it if you have a handful of products with some attributes - but with hundreds of articles with a lot of different options using this menu is really a nightmare!
    Integrating the image upload into the Ajax AttributesManager (which I really like) would be perhaps a better solution, but not all store owners have this tool in use.
    Or would it a better idea to create a separate file for that purpose? I'm not sure!

    Any ideas?

     

    J.J.


  5. @ De Dokta

     

    two questions need your help please.

     

    1. save message, it doesn't show anywhere.

     

    2. can see the invoice/packingslip in html format, but error with pdf format

    FPDF error: Interlacing not supported: images/store_logo.png

     

    thanks!

     

    @@ce7

     

    1. No idea what went wrong. If you save the message and then generate a new pdf or html invoice/packingslip in the invoice editor the message should be displayed on your new invoice/packingslip. It does not work if you generate an invoice/packingslip in orders.php.

     

    2. This has nothing to do with the invoice Editor, but that you have saved your logo with the "Interlaced" option. FPDF supports no "Interlaced" and for today's high-speed Internet connections, this option is also unnecessary!

  6. @@Patty

     

    Ok, the version I use is a little bit different:

    // If all is well, make the changes to the database
        if ($pass == 1) {
          tep_db_query("update customers set customers_password='" . tep_encrypt_password ($new_password) . "' where customers_id='" . (int)$customer_id . "'");
    
    // Get the customer's information for the success message
          $customer_name_query = tep_db_query("select customers_firstname, customers_lastname, customers_guest from customers where customers_id='" . (int)$customer_id . "' and customers_guest = '0'");
          $customer_name = tep_db_fetch_array($customer_name_query);
    
          tep_mail($customer_name['customers_firstname'] . " " . $customer_name['customers_lastname'], $customer_name['customers_email_address'], EMAIL_PASSWORD_REMINDER_SUBJECT, nl2br(sprintf(EMAIL_PASSWORD_REMINDER_BODY, $new_password)), STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS);
         }
      }
    // End POST section
    

    And this part:

    define('EMAIL_PASSWORD_REMINDER_SUBJECT', STORE_NAME . ' - New Password');
    define('EMAIL_PASSWORD_REMINDER_BODY', 'A new password was requested for your account at ' . STORE_NAME . '.' . "\n\n" . 'Your new password to \'' . STORE_NAME . '\' is:' . "\n\n" . '   %s' . "\n\n");

    is moved to admin/includes/languages/Your_language/change_password.php - where it belongs to!

     

    J.J.


  7. @@ArtcoInc

     

    Hi Malcolm

     

    Yes I know that the email validation is a problem: Originally I had it completly taken out from account_pwa.php. Then I got a mail where someone complained, that when a customer logs in as a guest, but does not complete the checkout process (so the data are not deleted), and later wants to register as a customer, an error message comes that the email already exists.

    So I put back the email validation. Now the same problem appears if a guest leaves before the checkout process is completed: If he comes back later again and wants again to purchase as a guest he gets the same error message that the email already exists.

    I have thought to build in a routine which checks the DB regularly for guest entries older than e.g. 24 hours and deletes them automatically.
    It's not that complicated, but at the moment I just don't have time, to do this and especially to test thoroughly.
     
    J.J.

  8. @@element3

     

    You were searching in the wrong file for reason for this error. Your code snippets are from catalog/checkout_process, while the error message tells you that there's a mistake in catalog/includes/languages/english/checkout_process.php. There you should find something like:

    define('EMAIL_WARNING', 'NOTE: This email address has been submitted by a visitor to our online-shop. If you were not this visitor, please send a message to:  ' . STORE_OWNER_EMAIL_ADDRESS . 'Thank you for your purchase and have a nice day.');

     

    J.J.
     


  9. Hi again,

     

    after checking W3C i got 3 errors:

     

    The problem is when you insert links (<a>) in the news text.

     

    The entry is displayed as a fully link. When you insert a link you will have a double open a-tag.

     

    W3C Error: <a> Start tag a seen but an element of the same type was already open.

     

    Hi

     

    This is indeed a problem: the news rotator has already a built in link <a href> because I wanted to link from the displayed news in the rotator (which may be truncated) to the respective (complete) news in the news module.

    If you want to use the rotator for something different e.g. to display some new products with a link to the respective product page, you should remove this built in link ( $wrapper_slides .= '<a href="' . tep_href_link('latest_news.php', 'news_id=' . $latest_news['news_id'], $request_type) . '">'; and $wrapper_slides .= '</a>';) from the module!

     

    J.J.

     

     


  10. Yes @@burt - especially as I already had a style overriding it there. Now it's

    <style type="text/css"> @[member='import'] url("ext/colorbox/colorbox.css"); #cboxTitle{font-weight:bold; font-size:large; color:#000000;}</style>
    <div class="col-sm-<?php echo $content_width . ' ' . MODULE_CONTENT_PRODUCT_INFO_GALLERY_CAPTION_CONTENT_ALIGN . ' ' . MODULE_CONTENT_PRODUCT_INFO_GALLERY_CAPTION_CONTENT_VERT_MARGIN . ' ' . MODULE_CONTENT_PRODUCT_INFO_GALLERY_CAPTION_CONTENT_HORIZ_MARGIN; ?> productsimages">
        <?php echo $gallery_output; ?>
    </div>
    
    works a treat

     

     

    Thanks a lot for that! Of all the proposals made here, this is the first that actually works for me.

     

    Another question regarding css files for cm_ modules: where to put them? Into the catalog directory? The template directory? Create a new folder includes/modules/content/name/css?
     
    Any suggestions?
     
    J.J.

  11. Hi
     
    I made a new version of my Latest News Multilingual Addon (http://addons.oscommerce.com/info/9147) as content module for BS-Gold.

     

    It displays news in a sliding or fading carousel which you can install on the index page or in the header area.

    With the exception of the index.php, which by default has (still) no hook, no core files must be changed.
     

    Download here: http://addons.oscommerce.com/info/9314

    Demo here: http://www.video-stuff.de/demo/bootstrap

     

    Pls. report any problems, bugs etc. here.
     
    J.J.


  12. Hi

     

    In index.php look for:   <h1><?php echo $catname; ?></h1>

    Change it to something like:   <?php echo tep_image(DIR_WS_IMAGES .$image['categories_image'], $image['categories_image'], SUBCATEGORY_IMAGE_WIDTH, SUBCATEGORY_IMAGE_HEIGHT); ?> <h1><?php echo $catname; ?></h1>

    and you will see the subcategories image, if the subcategory is selected.

     

    J.J.
     

×