Template Fluorspar

Results 1 to 20 of 297
02 Mar 2019, 12:44
#1
adb34 avatar

adb34

Totally Zenned

Join Date:
Mar 2008
Posts:
825
Plugin Contributions:
0

Template Fluorspar

I have spent a couple of days looking for this template on the forum, I cannot find it. I would like to turn 'on' the right column, can someone please let me know how?

Thank you
15 Mar 2019, 18:09
#3
silver_kamel avatar

silver_kamel

New Zenner

Join Date:
Oct 2006
Posts:
39
Plugin Contributions:
0

Re: Template Fluorspar

v156 w/ PHP 7.0.3
Greetings I recently did a new install of the Fluorspar template and everything is going well: https://www.kritterkams.com , however I can't seem to get the 'social media' links to work.
In the fluorspar/header.php I tried just the url itself and then this:
/*bof connect with us urls*/
define('FACEBOOK','<a href="https://www.facebook.com/Silver.Kamel" target="_blank"><i class="fa fa-facebook"></i></a>');
But I still don't see the FB icon.
I want to add FB, YouTube, and Instagram icons.

Any Thoughts?

Kamel....

Love is my religion.
16 Mar 2019, 15:02
#4
silver_kamel avatar

silver_kamel

New Zenner

Join Date:
Oct 2006
Posts:
39
Plugin Contributions:
0

Re: Template Fluorspar

Still having no luck with the 'social media' buttons.. I will come back to that later..
Tidying up the home page I see my 'search icon' is missing I think there is an error in the code. I have tried a few mods but I keep getting a blank page after my mods.

Here is the code in tpl_search_header.php :
$content = "";
$content .= zen_draw_form('quick_find_header', zen_href_link(FILENAME_ADVANCED_SEARCH_RESULT, '', 'NONSSL', false), 'get');
$content .= zen_draw_hidden_field('main_page',FILENAME_ADVANCED_SEARCH_RESULT);
$content .= zen_draw_hidden_field('search_in_description', '1') . zen_hide_session_id();
$content .= zen_draw_input_field('keyword', '', 'size="6" maxlength="30" value="' . HEADER_SEARCH_DEFAULT_TEXT . '" onfocus="if (this.value == \'' . HEADER_SEARCH_DEFAULT_TEXT . '\') this.value = \'\';" onblur="if (this.value == \'\') this.value = \'' . HEADER_SEARCH_DEFAULT_TEXT . '\';"');
$content .= '<input type="image" src="' . $template->get_template_dir('',DIR_WS_TEMPLATE, $current_page_base,'images/data').'/'.BUTTON_IMAGE_SEARCH_MAIN .'"' .' alt="Search" class="search_input" />';
$content .= "</form>";

When I do 'view source' on the page it states an error: does not exist, I think this refers to, .BUTTON_IMAGE_SEARCH_MAIN. so in it's place I put 'search-nav.jpg' but as I said before this caused the whole Home page to go blank. I can find no file BUTTON_IMAGE_SEARCH_MAIN in the v1.5.6 or Fluorspar directories..

How do I change this to pull the image up?

Thanx in advance...

Bless...…….. Kamel
Love is my religion
22 Mar 2019, 15:09
#5
silver_kamel avatar

silver_kamel

New Zenner

Join Date:
Oct 2006
Posts:
39
Plugin Contributions:
0

Re: Template Fluorspar

v1.5.6a PHP 7.0.3

FYI I am getting NO response from peejay who uploaded the FLUORSPAR template. Plus it does not work.
I found the source of this template at www zenofobe com but when I tried to download it my McAfee blocked and deleted the download warning that it contained a virus. So buyer beware! I also left a message at that site and as of yet have had no reply.
I have been trying some of the responsive templates. The ZC Responsive 156a works. Just got to work on it a bit..

Bless.... Kamel

P.S. I will be donating $100.02... $100.00 for the 1.5.6a template and $0.02 for my rant...
08 Jun 2019, 14:30
#6
peejay avatar

peejay

New Zenner

Join Date:
Aug 2018
Posts:
23
Plugin Contributions:
0

Re: Template Fluorspar

Was unaware of this thread, sorry for delay in replying.

In Zen Cart admin ->Configuration-> Layout Settings -> Column Right Status - Global
set to 1
As this template is responsive and designed for only a left column you will need to test by resizing your browser to see if it fits ok.
08 Jun 2019, 14:36
#7
peejay avatar

peejay

New Zenner

Join Date:
Aug 2018
Posts:
23
Plugin Contributions:
0

Re: Template Fluorspar

Was unaware of this thread, sorry for delay in replying.
There are no social media links in this template, so all social media definitions in - includes/languages/english/fluorspar/header.php are
redundant and could be deleted.

The Font Awesome icons used in the template are version 5 and are hosted locally for faster rendering.
If you are modifying say the footer menu to display branded Font Awesome icons you will need to use the new class names.

e.g. edit file - includes/templates/fluorspar/common/tpl_footer_menu.php

delete or edit last column and replace with something like this:-

<div class="footerColumn">
<div id="footerCustomHtml" class="footerMenu noLine">
<div id="customSuppNav">
<ul class="fa-ul">
<li class="footer-media"><a href="https://www.facebook.com/Silver.Kamel" target="_blank"><i class="fab fa-facebook"></i></a></li>
<li class="footer-media"><a href="#"><i class="fab fa-twitter"></i></a></li>
</ul>
</div>
</div>
</div>
08 Jun 2019, 14:51
#8
peejay avatar

peejay

New Zenner

Join Date:
Aug 2018
Posts:
23
Plugin Contributions:
0

Re: Template Fluorspar

The search button is defined as - define('BUTTON_IMAGE_SEARCH_MAIN', 'search-3-24.jpg');
found in the file - includes/languages/english/fluorspar/button_names.php
the image is in - includes/templates/fluorspar/images/data/search-3-24.jpg
I can only conclude the image failed to upload during installation, try reinstalling.

By editing tpl_search_header.php you must have made a syntax error to cause 'the whole Home page to go blank'.
Have a look in your error log!
08 Jun 2019, 14:52
#9
peejay avatar

peejay

New Zenner

Join Date:
Aug 2018
Posts:
23
Plugin Contributions:
0

Re: Template Fluorspar

The file you attempted to download from my website is perfectly safe and virus free, your McAfee software is giving a 'false positive'.
The comment 'So buyer beware!' is misplaced but thanks for bringing this anomaly to my attention.
27 Jun 2019, 22:03
#10
don_wagner avatar

don_wagner

New Zenner

Join Date:
Jan 2009
Posts:
65
Plugin Contributions:
0

Re: Template Fluorspar

I would really like to use the Fluorspar Template but am running into a problem: The large Product Images are being forced into an odd perspective which looks to be based on the width and height of the first Product Image. So if the first Product Image is square, all the other product images are forced to be square, etc. This only happens when Fluorspar Template is selected. Maybe I have my Images configured wrong but have not found the Admin setting change which fixes this ("Image - Use Proportional Images on Products and Categories" sounds related but does not have any effect whether zero or one).

Attachment 18522
28 Jun 2019, 10:53
#11
peejay avatar

peejay

New Zenner

Join Date:
Aug 2018
Posts:
23
Plugin Contributions:
0

Re: Template Fluorspar

Template Fluorspar uses Photoswipe to display the large product image which requires all
images to be the same dimensions (the preference of most Zen Cart users). However I have found a
solution here https://stackoverflow.com/questions/40515667/photoswipe-image-size-ratio
which may solve your problem. Open file :-

includes/templates/fluorspar/jscript/photoswipe_init.js

replace the code with this :-
( function( $ ) {
"use strict";
  
  var $pswp = $('.pswp')[0];
    var image = [];
    $('.product-images-wrap').each( function() {
      var $pic     = $(this),
      getItems = function() {
        var items = [];
        $pic.find('a').each(function() {
          var $href   = $(this).attr('href'),
              $size   = $(this).data('size').split('x'),
              $width  = $size[0],
              $height = $size[1];
          var item = {
              src : $href,
              w: 0,
               h: 0
          }
          items.push(item);
        });
        return items;
      }
      var items = getItems();
      $.each(items, function(index, value) {
        image[index]     = new Image();
        image[index].src = value['src'];
      });
      $pic.on('click', 'figure', function(event) {
        event.preventDefault();
        var $index = $(this).find('a').data('index');
        var options = {
            index: $index,
            bgOpacity: 0.7,
            showHideOpacity: true, 
            captionEl : false,
            fullscreenEl : true,
            shareEl : false,
            tapToClose : true,
            tapToToggleControls : false,
            closeOnScroll: false,
            history:false,
            closeOnVerticalDrag:false,
            zoomEl: true,
            counterEl: true,
            arrowEl: true,
            shareButtons: [
         {id:'facebook', label:'Share on Facebook', url:'https://www.facebook.com/sharer/sharer.php?u={{url}}'},
         {id:'twitter', label:'Tweet', url:'https://twitter.com/intent/tweet?text={{text}}&url={{url}}'},
         {id:'pinterest', label:'Pin it', url:'http://www.pinterest.com/pin/create/button/?url={{url}}&media={{image_url}}&description={{text}}'},
      ],
        }
        var lightBox = new PhotoSwipe($pswp, PhotoSwipeUI_Default, items, options);
lightBox.listen('gettingData', function(index, item) {
        if (item.w < 1 || item.h < 1) { // unknown size
        var img = new Image(); 
        img.onload = function() { // will get size after load
        item.w = this.width; // set image width
        item.h = this.height; // set image height
           lightBox.invalidateCurrItems(); // reinit Items
           lightBox.updateSize(true); // reinit Items
        }
    img.src = item.src; // let's download image
    }
});

        lightBox.init();
      });
    });
  $('.tabs-nav li a').click(function(ev){
      ev.preventDefault();
      var tab_id = $(this).attr('href');
      $('.tabs-nav li a').removeClass('active');
      $('.tab-content').removeClass('active');
      $(this).addClass('active');
      $(tab_id).addClass('active');
    });
} )( jQuery );


Please let me know if this works.

https://zenofobe.com
28 Jun 2019, 23:54
#12
don_wagner avatar

don_wagner

New Zenner

Join Date:
Jan 2009
Posts:
65
Plugin Contributions:
0

Re: Template Fluorspar

Wow - Thanks peejay! Yes, this worked perfectly. I really appreciate your documenting this fix. This was far beyond anything I could have figured out on my own.
29 Jun 2019, 09:28
#13
peejay avatar

peejay

New Zenner

Join Date:
Aug 2018
Posts:
23
Plugin Contributions:
0

Re: Template Fluorspar

A note about the Mega Menu

the file :- includes/templates/fluorspar/stylesheet_header_menu.css contains the rule :-

.level4 {display:none}

delete this if you want to display the next sub-level category.

Change to :-

.level3 {display:none}

If you want to hide all sub-categories.

https://zenofobe.com
06 Jul 2019, 23:35
#14
don_wagner avatar

don_wagner

New Zenner

Join Date:
Jan 2009
Posts:
65
Plugin Contributions:
0

Re: Template Fluorspar

First let me say that the Fluorspar Template has been my #1 choice for my responsive rewrite project since the first time I first laid eyes on it. I am very happy with the look and feel. Now I seem to have written myself into a small corner here and if it is a true problem with misuse of the intent of the Fluorspar Template then I will just disable the particular option in question and proceed.

I am running a vastly simplified version of a ZC Store: Showcase with Prices - no Shopping Cart, no signup/log in, no shipping calculator, no inventory management and no Invoice/Payment function within ZC. (Buyer uses Contact link to get shipping quote, emailed invoice, etc.). So the bulk of my work in adapting a template is turning options off.

So anyway, link to New Products, which results in New Products pictured, works fine. However link to Home Page, which results in Categories, with New Products listed beneath, shows a Buy Now Shopping Cart Button for each New Product. I am guessing there is a simple condition that needs to be set somewhere - in fluorspar/new_product.php?

Thanks PeeJay - It's a minor nit and I am happy to just turn this feature off on the home page.

Attachment 18543

Attachment 18544

Attachment 18545

Attachment 18546
07 Jul 2019, 04:59
#15
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Posts:
9,707
Plugin Contributions:
6

Re: Template Fluorspar

I am assuming but, I take it your store status is set to 1? (My Store)

And, Categories - Always Show on Main Page to 0? (Layout Settings)
07 Jul 2019, 12:50
#16
peejay avatar

peejay

New Zenner

Join Date:
Aug 2018
Posts:
23
Plugin Contributions:
0

Re: Template Fluorspar

Template Fluorspar was designed to display buy now buttons on main page and currently there is now way to change this in admin.
To hide buy now button either:-

open file stylesheet_css_buttons.css and write span.normal_button.BUTTON_IMAGE_BUY_NOW {display:none}

or

copy file includes/modules/new_products.php and overwrite includes/modules/fluorspar/new_products.php

regards peejay
http://zenofobe.com
07 Jul 2019, 17:17
#17
don_wagner avatar

don_wagner

New Zenner

Join Date:
Jan 2009
Posts:
65
Plugin Contributions:
0

Re: Template Fluorspar

dbltoe:

I am assuming but, I take it your store status is set to 1? (My Store)

And, Categories - Always Show on Main Page to 0? (Layout Settings)


Store Status is: 2 = Showcase with Prices
Categories - Always Show on Main Page is: 1= On
07 Jul 2019, 17:29
#18
don_wagner avatar

don_wagner

New Zenner

Join Date:
Jan 2009
Posts:
65
Plugin Contributions:
0

Re: Template Fluorspar

Thanks PeeJay! - I will do it that way. I am eternally grateful for your help.
08 Jul 2019, 16:47
#19
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Posts:
9,707
Plugin Contributions:
6

Re: Template Fluorspar

Template Fluorspar was designed to display buy now buttons on main page and currently there is now way to change this in admin.
Perhaps it might be best to re-insert into the template code the controls provided by the database and the Admin menu choices. The whole idea of database driven is that, in setting a flag that the store is showcase only, there would never be an Add to Cart button. Apparently that is removed and the control moved to the stylesheet.

That was part of code to keep from having to set such important things in more than one spot. IMHO stylesheet use of display:none should be a last resort and used only when an override inclusion/exclusion cannot be accomplished.

Submitted as something to consider. You could modify the product_info code to have the button appear on the main page as well but, only if the person is authorized and the store is set to sell.
<!--bof Add to Cart Box --><?php
if (CUSTOMERS_APPROVAL == 3 and TEXT_LOGIN_FOR_PRICE_BUTTON_REPLACE_SHOWROOM == '') {
  // do nothing
} else {
?>
<?php
    $display_qty = (($flag_show_product_info_in_cart_qty == 1 and $_SESSION['cart']->in_cart($_GET['products_id'])) ? '<p>' . PRODUCTS_ORDER_QTY_TEXT_IN_CART . $_SESSION['cart']->get_quantity($_GET['products_id']) . '</p>' : '');
    if ($products_qty_box_status == 0 or $products_quantity_order_max== 1) {
      // hide the quantity box and default to 1
      $the_button = '<input type="hidden" name="cart_quantity" value="1" />' . zen_draw_hidden_field('products_id', (int)$_GET['products_id']) . zen_image_submit(BUTTON_IMAGE_IN_CART, BUTTON_IN_CART_ALT);
    } else {
      // show the quantity box
      $the_button = '<div class="max-qty">' . zen_get_products_quantity_min_units_display((int)$_GET['products_id']) . '</div><span class="qty-text">' . PRODUCTS_ORDER_QTY_TEXT . '</span><input type="text" name="cart_quantity" value="' . (zen_get_buy_now_qty($_GET['products_id'])) . '" maxlength="6" size="4" />' . zen_draw_hidden_field('products_id', (int)$_GET['products_id']) . zen_image_submit(BUTTON_IMAGE_IN_CART, BUTTON_IN_CART_ALT);
    }
    $display_button = zen_get_buy_now_button($_GET['products_id'], $the_button);
?>
<?php if ($display_qty != '' or $display_button != '') { ?>
    <div id="cartAdd">
    <?php
      echo $display_qty;
      echo $display_button;
?>
          </div>
<?php   } // display qty and button ?>
<?php } // CUSTOMERS_APPROVAL == 3 ?>
<!--eof Add to Cart Box-->
09 Jul 2019, 16:22
#20
peejay avatar

peejay

New Zenner

Join Date:
Aug 2018
Posts:
23
Plugin Contributions:
0

Re: Template Fluorspar

dbltoe:

Perhaps it might be best to re-insert into the template code the controls provided by the database and the Admin menu choices. The whole idea of database driven is that, in setting a flag that the store is showcase only, there would never be an Add to Cart button. Apparently that is removed and the control moved to the stylesheet.


I should have advised to just delete file:- includes/modules/fluorspar/new_products.php.
Then the template would use the core file includes/modules/new_products.php.
This file does not have any buttons, so I have not removed any code. The code used to display the BUY_NOW button
is from a mod found here :-https://www.zen-cart.com/downloads.php?do=file&id=998
Perhaps you could submit an improved version using your code.

Template Fluorspar does not use mobile_detect (I found it unreliable) and so relies heavily on {display:none} in css media queries.
I know I'm swimming against the tide with this but it seems to work alright.
Best not to use this template if you are not a fan of {display:none}.

Something to peruse:- https://www.quora.com/What-are-the-pros-and-cons-of-media-queries-vs-http-user-agent

peejay
http://zenofobe.com