Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Editar las plantillas

NomakNomak New
edited October 2012 in Vanilla 2.0 - 2.8

Estoy creando mi primer theme de vanilla, copie el archivo "default.master.tpl" en la carpeta "views" de mi theme, el problema es el siguiente:

las variables asset no se como editarlas ejemplo:

{asset name="Content"}

{module name="MeModule"}

{asset name="Panel"}

{searchbox}

{asset name="Head"}

{discussions_link}

{activity_link}

{custom_menu}
,etc

intente buscar archivos php con esas variables pero no las puedo encontrar :(

Best Answer

  • KasperKasper Vanilla Staff
    edited October 2012 Answer ✓

    Thank God for Google Translate! Anywho, these variables are "Smarty" variables (http://www.smarty.net) and as such, you cannot directly edit their output.

    If you want to do so though, you'll need to find the "views" that handles the output of each variable - sometimes one variable will be associated with several views. All of the views you'll need can be found within the applications directory of your installation. Simply copy any and all views you'll want to edit to a views directory in your own theme.

    For example, if you wanted to directly edit each individual discussion page, you'd need this file: https://github.com/vanillaforums/Garden/blob/master/applications/vanilla/views/discussion/index.php
    This is found within applications/vanilla/views but you can also find several views within applications/dashboard/views that might be of interest.

    However, it's a good idea to only edit default.master.tpl and custom.[js/css].

    Kasper Kronborg Isager (kasperisager) | Freelance Developer @Vanilla | Hit me up: Google Mail or Vanilla Mail | Find me on GitHub

Answers

  • KasperKasper Vanilla Staff
    edited October 2012 Answer ✓

    Thank God for Google Translate! Anywho, these variables are "Smarty" variables (http://www.smarty.net) and as such, you cannot directly edit their output.

    If you want to do so though, you'll need to find the "views" that handles the output of each variable - sometimes one variable will be associated with several views. All of the views you'll need can be found within the applications directory of your installation. Simply copy any and all views you'll want to edit to a views directory in your own theme.

    For example, if you wanted to directly edit each individual discussion page, you'd need this file: https://github.com/vanillaforums/Garden/blob/master/applications/vanilla/views/discussion/index.php
    This is found within applications/vanilla/views but you can also find several views within applications/dashboard/views that might be of interest.

    However, it's a good idea to only edit default.master.tpl and custom.[js/css].

    Kasper Kronborg Isager (kasperisager) | Freelance Developer @Vanilla | Hit me up: Google Mail or Vanilla Mail | Find me on GitHub

Sign In or Register to comment.