Tag Archives: macros

Adding shop output on other pages (external shop macros)


there are several macros available to display shop output on other pages :

to add all this macros on other page, use ezgenerator 'insert html' function

1. to display vertical or horizonatl shop category list, add following code :
                                                                             
<script type="text/javascript" src="http://miro.image-line.com/max4_jquery/shop/shop.php?category_vlist"></script>

or

<script type="text/javascript" src="http://miro.image-line.com/max4_jquery/shop/shop.php?category_hlist"></script>

2. to display shop minicart, add :

<script type="text/javascript" src="http://miro.image-line.com/max4_jquery/shop/shop.php?action=minicartjs"></script>


notice, minicart has to be also used on shop main or category page

3. to display shop tag cloud, add:

<script type="text/javascript" src="http://miro.image-line.com/max4_jquery/shop/shop.php?action=tagcloud"></script>

4. to display random shop product, add following code:

<script type="text/javascript" src="http://miro.image-line.com/max4_jquery/shop/shop.php?action=random&count=2"></script>


available parameters :
count : number of random products to be displayed
dir:   dir=h (products will be displayed horizontaly)
root:    specify root=1  if  destination page is in website root
file: path to file with random macro template (you have to use this parameter if you don't have random macro included on shop main page)

--> create extra page in your project (you can made this page hidden in menu) and copy random macro to this page, then use page relative path as file parameter

example of random macro in this file :

random macro



notice: random macro has to be also used on shop main or category page

example page with external shop macros

 


Print  posted by miro   Shop/lister tags:  external • shop • macros • random   permalink
5 1

Blog (MySQL version) Related posts


New sidebar macro : % BLOG_RELATED%  is available since version 4.0.0.119..

A little explanation how this macros works:

Relation between posts is defined with post keywords (you can add comma separated keywords for each post in blog)

This macro collect all keywords defined for all posts currently displayed on page and search database for all other (not displayed) posts with same keywords = related posts

 

 


Print  posted by miro   Blogs/Rss tags:  blog • macros   permalink
2.5 2

Customizing blog/podcast sidebar macro objects


Following parameters can be used in all Blog/Podcast sidebar macros

(  BLOG_ARCHIVE(), BLOG_MOST_VISITED()  BLOG_TOP_RANK()  BLOG_FULLLIST()  )

 

% date%  % DATE[date parameters]% % free_field%  % excerpt% % title% % category% % image% % image[width,height]%  % item_url%
in podcast also %subtitle% miro are supported

 

in BLOG_FULLLIST() there is also additional macro:  % content%


Print  posted by miro   Blogs/Rss tags:  Blog • Podcast • macros • sidebar   permalink
2 1

How to use "Exchange rate" in shop pages


Exchange rates are just numbers which you can use in calculaton. They are not altrnative currency prices. 
The main indea of this section is to define the ratio of each exchange rate, and use it globally among the given shop subpages, thus saving time in replacing values for exchange rates on a daly basis.

  • Create exchange rates macros:
  1.  Go to shop online admin page and click on "SETTINGS" navigation tab.
  2.  Click on "exchange rate" button.
  3.  In Exchange Rate Options table you can add currencies with rates. You can only use lowercase characters and underscore for the currency name and floating point  numbers or whole numbers for the rate.
  4.  When finished adding currencies with rates click on "Save" button and now you have macros currencies in your database. Those currencies are available only for current shop page.
  • Use exchange rates in shop page (img.1):
  1. Open you project in Ezgenerator and go to the shop page for which you create Exchange Rates (currencies macros).
  2. Click on "categories", for example.
  3. in "CART" you can type: %EVAL(%your_currency_name%<*>%SHOP_TOTAL%)%  or other formula
  4. Publish your changes.
  5. In the end eval function multiplies current SHOP_TOTAL by your exchange rate.

Print  posted by miro   Shop/lister tags:  macros • tutorial • shop • settings   permalink
0 0

IF macro


The IF macro will check the logical condition of a statement and return one value if true and a different value if false.

 

syntax:

%IF(condition, value-if-true, value-if-false)%

 

available operators (in condition)  :

<> Not equal
<= Less than or equal to
=> Greater than or equal to
= equal
< Less than
> Greater than
&&      And
|| Or

 

only one condition at time is allowed

 

some examples:

%IF(%sale_price% = ,%price%,%price% SALE: %sale_price%)%

(display sale price when available, otherwise display normal price)

 

%IF(%%price%% < 1.00, Budget Price , )%

(displays text "Budget Price" when price is lower < 1)

 

%IF(%short_description%=,There is no short description for this item!,)%

(displays text when short_description field is empty)

 

 


Print  posted by miro   General tags:  macros • if   permalink
0 0


[home] 1-5 of 5


CATEGORIES



TAGS


RECENT ENTRIES