1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. This forum is for release discussion only. Discussions that do not relate specifically to the resource release should be discussed in another, more appropriate forum.
    Dismiss Notice
  3. This forum has been archived. New threads and replies may not be made. All add-ons/resources that are active should be migrated to the Resource Manager. See this thread for more information.

Flags of countries show

Discussion in 'Template Modifications [Archive]' started by lms, Jan 18, 2011.

  1. lms

    lms Well-Known Member

    The languaje spanish has hit not standar in internet. The images accentuateds and ñ has not load images.
    Make a addon not sense.
    Author: Gustavo Fernandez or DL Gushh_. I've only done some modification. All credit goes to him. Original mod in xenfacil.com


    15_1.png
    15_2.png

    Whoever wants to adapt it to your country, you have to change the text to be entered on the message_user_info template (example in xenfácil.com):
    PHP:
     <dd><a href="http://maps.google.com/maps?q={xen:urlencode {xen:string censor, $user.location}}" target="_blank" rel="nofollow" itemprop="address" class="concealed">
    <
    xen:if is="({xen:string censor, $user.location} == 'Espana')">
    <
    img src="@imagePath/xenforo/gushh_flags/Espana.png" alt="España" title="España" />
    <
    xen:elseif is="({xen:string censor, $user.location} == 'Peru')" />
    <
    img src="@imagePath/xenforo/gushh_flags/Peru.png" alt="Perú" title="Perú" />
    <
    xen:elseif is="({xen:string censor, $user.location} == 'Mexico')" />
    <
    img src="@imagePath/xenforo/gushh_flags/Mexico.png" alt="México" title="México" />
    <
    xen:else />
    <
    img src="@imagePath/xenforo/gushh_flags/{xen:string censor, $user.location}.png" alt="{xen:string censor, $user.location}" title="{xen:string censor, $user.location}" />
    </
    xen:if>
    </
    a></dd>
    Who wants to add any country of the accents to this list, you must replace <xen:else /> by
    PHP:
     <xen:elseif is="({xen:string censor, $user.location} == 'new_country')" />
    <
    img src="@imagePath/xenforo/gushh_flags/new_country.png" alt="new_country_accentuated" title="new_country_accentuated" />
    <
    xen:else />
    Search in the account_personal_details template:
    PHP:
     <dd><input type="text" name="location" value="{$visitor.location}id="ctrl_location" class="textCtrl OptOut" /></dd>
    Replace by
    text in attachments. File FlagsCountrys_Mod_lms.txt

    Search in the message_user_info template

    PHP:
    <dd><a href="http://maps.google.com/maps?q={xen:urlencode {xen:string censor, $user.location}}" target="_blank" rel="nofollow" itemprop="address" class="concealed">{xen:string censor$user.location}</a></dd>
    Replace by

    PHP:
          <dd><a href="http://maps.google.com/maps?q={xen:urlencode {xen:string censor, $user.location}}" target="_blank" rel="nofollow" itemprop="address" class="concealed">
    <
    xen:if is="({xen:string censor, $user.location} == 'Espana')">
    <
    img src="@imagePath/xenforo/gushh_flags/Espana.png" alt="España" title="España" />
    <
    xen:elseif is="({xen:string censor, $user.location} == 'Peru')" />
    <
    img src="@imagePath/xenforo/gushh_flags/Peru.png" alt="Perú" title="Perú" />
    <
    xen:elseif is="({xen:string censor, $user.location} == 'Mexico')" />
    <
    img src="@imagePath/xenforo/gushh_flags/Mexico.png" alt="México" title="México" />
    <
    xen:else />
    <
    img src="@imagePath/xenforo/gushh_flags/{xen:string censor, $user.location}.png" alt="{xen:string censor, $user.location}" title="{xen:string censor, $user.location}" />
    </
    xen:if>
    </
    a></dd>
    Leave the flags files in spanish without accents and España as Espana (Spanish) in attachments.

    Note: The names of the countries are in Spanish. The flags look the same. These are pictures!

    15.png

    Salud2
     

    Attached Files:

  2. Lqd

    Lqd Member

    I like the idea, but I don't understand the instructions.
     
  3. lms

    lms Well-Known Member

    Attached Files:

    The Matrix likes this.
  4. Gustavo Fernandez

    Gustavo Fernandez Active Member

    ¬¬ ni créditos ¬¬
     
  5. lms

    lms Well-Known Member

    I feel not having mentioned when all the credit is yours. Worth it as my recognition. Since in the post one.

    Salud2
     
    Gustavo Fernandez likes this.
  6. erich37

    erich37 Well-Known Member

    there should be an option in XF by default to have a list of countries in the user-profile-list.
     
  7. lms

    lms Well-Known Member

    It is a matter of taste.

    Salud2
     

Share This Page