VirtueMart two price display

So i had a problem, in Virtuemart, but it’s easy way to display near your price price in euros.

Just go to: /components/com_virtuemart/themes/YOUR-THEME/templates/common/price.tpl.php find line:

<!--?php echo $text_including_tax ?-->

and paste after

<!--?php 
$y=3.4528;
echo money_format('%i', $base_price / $y ) . "\n"; // outputs X.xx
echo ('&nbsp;&#8364;');
?-->

Open cart dvi ir daugiau valiutos

kaina
Taip atrodys kainos po jų pakeitimo. Veikia su 1.4 ir 1.5 visom versijom, netestuota su aukščiausia 1.5.6.4.

P.S. kas labai tingit redaguoti kodą ir turite įsidiegę į savo OpenCart’e, VQMod’ą galite atsisiūsti šį XML failiuką: product_currency.xml šį failiuką reiks patalpinti VQMod’o xml kataloge. Taip pat sukelti kalbos failiukus(prieš tai juos pasiredaguoti pagal savo OC kalbą) catalog

 

 

Atidarome failą: catalog/controller/product/product.php Susrandame:

$this->data['points'] = $product_info['points'];

Po ja įršome:

$this->data['clean_price'] =  $product_info['price'];
                        $this->data['clean_special'] =  $product_info['special'];

Atsidarome failą: catalog/view/theme/JŪSŲ-DIZAINAS/template/product/product.tpl Susirandame:

<!--?php echo $price; ?-->

Po ja įrašome:

<!--?php
                        $this--->language->load('product/product_currency');
                        $this->load->model('localisation/currency');
                        $currencies = $this->model_localisation_currency->getCurrencies();
                        $this->data['currencies'] = array();

            if (!empty($currencies)) {
                  foreach ($currencies as $currency) {
                      if ($currency['code'] == $this->session->data['currency']) {
                          continue ;
                          }
                   echo str_replace(array('{title}', '{price}'), array($currency['title'], $this->currency->format($this->data['clean_price'], $currency['code']),$currency['code']), $this->language->get('text_product_currency'));
                  }
               }
            ?>

Tame pačiame faile susirandame:

<!--?php echo $special; ?-->

Po ja įrašome:

<!--?php
                        $this--->language->load('product/product_currency');
                        $this->load->model('localisation/currency');
                        $currencies = $this->model_localisation_currency->getCurrencies();
                        $this->data['currencies'] = array();

            if (!empty($currencies)) {
                  foreach ($currencies as $currency) {
                      if ($currency['code'] == $this->session->data['currency']) {
                          continue ;
                          }
                   echo str_replace(array('{title}', '{price}'), array($currency['title'], $this->currency->format($this->data['clean_special'], $currency['code']),$currency['code']), $this->language->get('text_product_currency'));
                  }
               }
            ?>

Atsisiunčiame žemiau pateiktą failą: catalog Asidarome ir pasiredaguojame kalbą kad tiktų prie puslapio, kadangi visuose kalbos failiukuose tekstas pateiktas anglų kalba.

Taip pat galite naudoti ir: http://www.opencart.com/index.php?route=extension%2Fextension%2Finfo&extension_id=18188&filter_username=pepa

Enable Gzip Compression via .htaccess

 

# compress text, html, javascript, css, xml:
AddOutputFilterByType DEFLATE text/plain
AddOutputFilterByType DEFLATE text/html
AddOutputFilterByType DEFLATE text/xml
AddOutputFilterByType DEFLATE text/css
AddOutputFilterByType DEFLATE application/xml
AddOutputFilterByType DEFLATE application/xhtml+xml
AddOutputFilterByType DEFLATE application/rss+xml
AddOutputFilterByType DEFLATE application/javascript
AddOutputFilterByType DEFLATE application/x-javascript
AddType x-font/otf .otf
AddType x-font/ttf .ttf
AddType x-font/eot .eot
AddType x-font/woff .woff
AddType image/x-icon .ico
AddType image/png .png

Hide Metaslider in mobile

So if you need to hide display of Metaslider your mobile web just do these steps:

Find your Metaslider slider ID for example mine id is 71 then

Open your theme style.css file and paste code below just change your slider id from 71 to what ever you got

@media (max-width: 800px) {
    #metaslider_container_71 {
        display:none !important;
    }
}

Facebook OG property WordPress

It’s easy way how to create Facebook OG property WordPress : Open your theme header.php file and paste this code line after:

<!--?php wp_head(); ?-->
<meta property="og:title" content="<?php the_title(); ?>" />
<meta property="og:type" content="article" />
<meta property="og:image" content="<?php $thumb_id = get_post_thumbnail_id(); $thumb_url = wp_get_attachment_image_src($thumb_id,'thumbnail-size', true); echo $thumb_url[0]; ?>" />
<meta property="og:url" content="<?php the_permalink(); ?>" />
<meta property="og:description" content="<?php echo $description ?>" />
<meta property="og:site_name" content="<?php echo get_bloginfo('name'); ?>" />

qTranslate WordPress 3.9 or later

How to run qTranslate WordPress 3.9 or later version its easy just have latest version of qtranslate. Open /wp-content/plugins/qtranslate folder find qtranslate.php and open in your php editor for example PSPad or Notepad++ find line:

define('QT_SUPPORTED_WP_VERSION', '3.8.1');

and edit 3.8.1 change to your wordpress version for example 3.9.1 it looks like:

define('QT_SUPPORTED_WP_VERSION', '3.9.1');

This fix use at your own risk. I prefer to make MySQl DB and WP files backup.

WordPress change read more to dots

WordPress change read more to dots or other for example simbol >> or other. Its easy as 2×2 go to your theme directory, open functions.php and after function sbt_auto_excerpt_more( $more ) { return ‘…'; } add_filter( ‘excerpt_more’, ‘sbt_auto_excerpt_more’, 20 ); function sbt_custom_excerpt_more( $output ) {return preg_replace(‘/<a[^>]+>Continue reading.*?<\/a>/i’,“,$output); } add_filter( ‘get_the_excerpt’, ‘sbt_custom_excerpt_more’, 20 );

How to enable browser caching

Easy way how to enable browser caching

## EXPIRES CACHING ##
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/jpg "access 1 year"
ExpiresByType image/jpeg "access 1 year"
ExpiresByType image/gif "access 1 year"
ExpiresByType image/png "access 1 year"
ExpiresByType text/css "access 1 month"
ExpiresByType text/html "access 1 month"
ExpiresByType application/pdf "access 1 month"
ExpiresByType text/x-javascript "access 1 month"
ExpiresByType application/x-shockwave-flash "access 1 month"
ExpiresByType image/x-icon "access 1 year"
ExpiresDefault "access 1 month"
</IfModule>
## EXPIRES CACHING ##

WordPress security

For better security of your wordpress blog just open wp-config.php file in editor and add

define('DISALLOW_FILE_EDIT', true); //cant edit themes from control panel
define('DISALLOW_FILE_MODS',true); //cant install delete or modify plugins from admin panel

OneDrive

Logo_OneDriveKaip ir visiems vartotojams tenka naudotis Cloud tipo saugyklomis, dauguma naudoje DropBox, BOX.net, Google drive, tačiau viena didelė alternatyva tikriausiai geriausia kurią man teko naudoti ir naudosiu ateityje tai yra OneDrive.

Kodėl verta naudotis OneDrive? atsakymas paprastas, gaunate ne tik 7GB failams(gal kiek mažokai) tačiau dokumentams pakankamai. Ši Microsoft paslauga ypatinga tuo, kad galite redaguoti savo Word, Excel ir PowerPoint dokumentus online rėžimu nepriklausomai nuo operacinės sistemos. Taip pat galite naudotis online Outlook’u tikrai patogu. Taip pat pilnai funkcionuojanti skype ir dauk kitų super privalumų, ko negali pasiūlyti kiti panašių paslaugų tiekėjai.