+
1 2 2
  1. #1
    Status
    Offline
      Rise Company
    Engineering and Technology
    Apr 2014
    Egypt
    4,637
    10

    Whmcs / language flags


    Whmcs / language flags
    How to add country flags? - how to change flag? - to change language flags on v8
    How to use icons in WHMCS to select the language in client area




    WHMCS has flags for the following currencies as standard; AUD, CAD, EUR, GBP, INR, JPY, USD and ZAR. If any of these currencies are configured, a flag will appear on the shopping cart for new signups to select as shown above.

    In this example I will be adding Chinese Yuan (CNY) and modifying the Modern template,
    but you can also follow this same technique with the Slider template.

    :

    So to add flags for more currencies, first obtain or create a flag image measuring 16px by 11px and then upload it to the whmcs/assets/img/flags directory.
    Next we need to copy the order form template to give us one we can customize.
    So duplicate the /templates/orderforms/modern directory and name it whatever you like,



    for this example I will call it 'moderncustom'.

    :
    Open /templates/orderforms/moderncustom/products.tpl and look for line 26:
    {elseif $curr.code eq "EUR"}eu
    {elseif $curr.code eq "GBP"}gb
    {elseif $curr.code eq "INR"}in
    {elseif $curr.code eq "JPY"}jp
    {elseif $curr.code eq "USD"}us
    {elseif $curr.code eq "ZAR"}za
    {else}na{/if}.png" border="0" alt="" /> {$curr.code}


    Replace it with:

    {elseif $curr.code eq "EUR"}eu
    {elseif $curr.code eq "GBP"}gb
    {elseif $curr.code eq "INR"}in
    {elseif $curr.code eq "JPY"}jp
    {elseif $curr.code eq "USD"}us
    {elseif $curr.code eq "ZAR"}za

    {elseif $curr.code eq "EGP"}eg
    {else}na{/if}.png" border="0" alt="" /> {$curr.code}


    Where my flag image is called ch.png. I've highlighted the code added in the screenshot below.
    The end result is a block of code on line 26 which looks like:


    legacy modern
    :
    whmcs/templates/orderforms/legacy_modern/products.tpl
    and made the exact same modification to line 47 of this file too.

    Now upload the two templates files we just edited. Login to your WHMCS admin area to
    select the moderncustom order form template from the Setup > General Settings > Ordering tab and you're done!

    A flag image will now be displayed to visitors on the order form next to the CNY currency option.
    It would just be a case of adjusting the "CNY" variable and "ch" filename in order to add as many different flags as desired.




    :

    0-
    1- whmcs order template
    2- order template products.tpl

    3- us
    4- whmcs/assets/img/flags

    :
    products.tpl

    :
    http://3.12.123.82/96174/whmcs-insig...currency-flags
    https://whmcs.community/topic/305858...e-flags-on-v8/
    https://whmcs.community/topic/168593...o-change-flag/
    https://domainregister.international...ient-area.html

    ------------------------------------------------------------------------
    Rise Company for Engineering & Technology
    ------------------------------------------------------------------------
    Web Hosting | Web Designing | E-Marketing

    # 1 Business Services

    Web Hosting - Business Emails

    Web Design - Google Adwords

    www.rise.company | www.rise.company/emails

    :
    ! .



  2. #2
    Status
    Offline
      Rise Company
    Engineering and Technology
    Apr 2014
    Egypt
    4,637
    10

    : Whmcs / language flags



    {elseif $curr.code eq "SAR"}sa

    else sa

    ----------------------------------------



    :
    <img src="{$BASE_PATH_IMG}/flags/{if $curr.code eq "AUD"}au{elseif $curr.code eq "CAD"}ca{elseif $curr.code eq "EUR"}eu{elseif $curr.code eq "GBP"}gb{elseif $curr.code eq "INR"}in{elseif $curr.code eq "JPY"}jp{elseif $curr.code eq "USD"}us{elseif $curr.code eq "EGP"}eg{elseif $curr.code eq "SAR"}sa{elseif $curr.code eq "QAR"}qa{elseif $curr.code eq "AED"}ae{else}na{/if}.png" border="0" alt="" />
    ------------------------------------------------------------------------
    Rise Company for Engineering & Technology
    ------------------------------------------------------------------------
    Web Hosting | Web Designing | E-Marketing

    # 1 Business Services

    Web Hosting - Business Emails

    Web Design - Google Adwords

    www.rise.company | www.rise.company/emails

    :
    ! .



  1. Whmcs Currency in a link
    Rise Company Whmcs
    : 0
    : 20-11-2021, 22:06
  2. Whmcs / / home button
    Rise Company Whmcs
    : 0
    : 05-11-2020, 16:40
  3. Whmcs / / languages
    Rise Company Whmcs
    : 0
    : 20-09-2019, 23:46
  4. Seo Whmcs -
    Rise Company Whmcs
    : 0
    : 04-05-2018, 01:12
  5. : 0
    : 16-04-2018, 00:20