Bryce Jewelers

Link: http://brycejewelers.com

A custom Prestashop e-commerce site for a jewelery store in East Chicago, Indiana. Designed with JQuery/JS also. Did the pictures, too! (I know, they look great.) Total time: about 3 weeks, which includes design/layout, set up and putting in 60+ products.

 


Send feedback » more...

B2evo date error: system's timezone settings

The error:
warning: date() [function.date]: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'aaaaaa' for 'aaaaa' instead in /home/aaaaa/public_html/inc/_core/_misc.funcs.php
The fix: Put this line of code after you list of dependencies in /home/aaaaa/public_html/inc/_core/_misc.funcs.php

PHP:

So it should like this:

PHP:

/**
 * Dependencies
 */
load_funcs('antispam/model/_antispam.funcs.php');
load_funcs('files/model/_file.funcs.php');
date_default_timezone_set('UTC');

Send feedback » more...

Manual Twitter for B2evolution

One of the earlier problems that I had was getting Tweetmeme / Twitter to work for B2evolution - the Tweetmeme for B2evo was great, but it broke every so often (not sure if it was because of Tweetmeme, the skin itself, or B2evolution's code.)

So for those of you who need Twitter to work on B2evo, but can't get it to work, here's a manual hack of the code for your skin. (On that note, if you alternate skins, it would have to be hacked for every skin.)
  1. Go to the skin that you are using. The location should be something like "/b2blog/skins/skinname/" where "b2blog" is your b2evolution installation location, and "skinname" is the skin that you are using.
  2. Find the file "index.main.php". Open it up to edit.
  3. Scroll down to around line 74, where the content says: [codespan] [/codespan]
  4. Right underneath it, copy and paste your Twitter code.

    PHP:

    <script type="text/javascript">
     
    tweetmeme_screen_name 'yoursn';
    tweetmeme_style 'compact';
    </script>
    <script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js"></script>
     
     
        </div> <!-- end of id="content" -->
        </div> <!-- end of id="contentwrapper" -->
    Make sure it's before the div tags, and remember to edit "yoursn" to your Twitter screen name!


And that's it. This will show the Twitter twitting twits thing (say that 5x fast) for every post you have, including when you actually open up the pages.

Send feedback » more...

New Product module updated for Prestashop

I'm sorry, but Prestashop's modules can suck sometimes... especially since Smarty is involved. Case in point: new product module. I don't know about you, but why is the module written manually with 4 "li" tags rather than looped? You can have only 4 New Products listed then, manually added (the ids were put in straight into the code...) which completely defeats the purpose of having it dynamically change in the back-end.

Anyway, being frustrated enough, I have rewrote it. The module is located in /modules/blocknewproducts/.

This is the original (or close enough, the code is the same, I removed the 3 other "li" statements, so there is only one):

PHP:

<!-- MODULE Block new products -->
<div class="blocknewproducts">
    <h4><a href="{$base_dir}new-products.php"  title="{l s='See all' mod='blocknewproducts'}">{l s='New products' mod='blocknewproducts'}</a></h4>
    {if $new_products}
            {foreach from=$new_products item=product name=myLoop}
        {/foreach}
       <ul>
        <li class="li_info">
             <a href="{$new_products.0.link}">
              <img src="{$img_prod_dir}{$new_products.0.id_image}-medium.jpg" alt="{$new_products.0.legend|escape:htmlall:'UTF-8'}/>
             </a>
            <h5>
              <a href="{$new_products.0.link}title="{$new_products.0.name|escape:htmlall:'UTF-8'}">{$new_products.0.name|escape:htmlall:'UTF-8'|truncate:30}</a>
            </h5>
                <span class="price-discount">{displayWtPrice p=$new_products.0.price_without_reduction}</span>
                {if $new_products.0.reduction_percent}<span class="reduction">(-{$new_products.0.reduction_percent}%)</span>{/if}
                <span class="price">{displayWtPrice p=$new_products.0.price}</span>
        {if $product.description_short}
             <span class="{if $smarty.foreach.myLoop.first}first_item{elseif $smarty.foreach.myLoop.last}last_item{else}item{/if}">
              <a href="{$new_products.0.link}">{$new_products.0.description_short|strip_tags:htmlall:'UTF-8'|truncate:60}</a>
              <class="linkview" href="{$new_products.0.link}title="{$product.name|escape:htmlall:'UTF-8'}">&nbsp;</a>             
             </span>
            {/if}
         </li>
      </ul>
 
         {else}
        <p>{l s='No new product at this time' mod='blocknewproducts'}</p>
    {/if}
</div>
Remove the entire thing, and paste this bad boy up:

PHP:

<!-- MODULE Block new products -->
<div class="blocknewproducts">
    <h4><a href="{$base_dir}new-products.php"  title="{l s='See all' mod='blocknewproducts'}">{l s='New products' mod='blocknewproducts'}</a></h4>
 
    {if $new_products}
      <ul>
            {foreach from=$new_products item=product name=new}
 <li class="li_info">
                <a href="{$product.link}"><img src="{$img_prod_dir}{$product.id_image}-medium.jpg" alt="{$product.legend|escape:htmlall:'UTF-8'}title="{$product.name|escape:htmlall:'UTF-8'}"></a>
            
                <h5><a href="{$product.link}title="{$product.name|escape:htmlall:'UTF-8'}">{$product.name|escape:htmlall:'UTF-8'}</a></h5>
                <span class="price-discount">{displayWtPrice p=$product.price_without_reduction}</span>
                {if $product.reduction_percent}<span class="reduction">(-{$product.reduction_percent}%)</span>{/if}
                <span class="price">{displayWtPrice p=$product.price}</span>
            </li>
    {/foreach}
      </ul>
         {else}
        <p>{l s='No new product at this time' mod='blocknewproducts'}</p>
    {/if}
</div>
<!-- /MODULE Block new products -->
Das it. Compared to the original, you get an even shorter, dynamic loop that CAN be changed easily on the backend, no manual ids! Enjoy!
Send feedback » more...

Ooo, alpha!

So apparently b2evolution has an alpha 4 available now - for anyone using previous versions, I totally recommend upgrading your b2evo installation. My plugins actually work now. ~_~
Send feedback » more...
1 2 3 4 5 6 7 8 9 10 11 12 »