Önsöz: Bu sadece bir fikir.
Brian Litzinger Yayıncısı'nı ( http://devot-ee.com/add-ons/publisher ) exp: kanal: form
üzerinde ızgara çevirilerine izin vermek için.
Üstbilgileri ve düğmeleri değiştirmek için, ızgarayı Kanal Formuna ekleyebilir, oluşturulmuş kodu yakalayabilir ve doğrudan şablona yapıştırabilirsiniz (alanı HTML’i anında oluşturmasına izin vermek yerine) ve daha sonra Yayıncı'nın dil etiketlerini üstbilgileri çevirmek için kullanabilirsiniz. ve düğmeler.
Örneğin, bir Kanal Formu oluşturabilir ve ızgarayı oluşturmasını söyleyebilirim. Kod baktığını göreceğim ...
<table id="testing" class="grid_field_container" cellspacing="0" cellpadding="0">
<tr>
<td class="grid_field_container_cell">
<table class="grid_field" cellspacing="0" cellpadding="0">
<thead>
<th class="grid_handle"> </th>
<th width="0%">Column 1</th>
<th width="0%">Column 2</th>
</thead>
<tbody class="grid_row_container">
<tr class="grid_row blank_row">
<td class="grid_handle"> </td>
<td width="0%" data-fieldtype="text" data-column-id="1">
<div class="grid_cell">
<input type="text" name="testing[rows][new_row_0][col_id_1]" value="" dir="ltr" field_content_type="all" maxlength="256" />
</div>
</td>
<td width="0%" data-fieldtype="text" data-column-id="2">
<div class="grid_cell">
Delete Row
<input type="text" name="testing[rows][new_row_0][col_id_2]" value="" dir="ltr" field_content_type="all" maxlength="256" />
</div>
</td>
</tr>
<tr class="empty_field">
<td colspan="3" class="empty_field first">You have not added any rows of data yet. Add some data?</td>
</tr>
</tbody>
</table>
</td>
<td class="grid_delete_row_gutter"> </td>
</tr>
<tr>
<td>
Add Row
</td>
</tr>
Well you could now change that to use Publisher "Phrases" (https://boldminded.com/add-ons/publisher/phrases)
<table id="testing" class="grid_field_container" cellspacing="0" cellpadding="0">
<tr>
<td class="grid_field_container_cell">
<table class="grid_field" cellspacing="0" cellpadding="0">
<thead>
<th class="grid_handle"> </th>
<th width="0%">{phrase:form_col1}</th>
<th width="0%">{phrase:form_col1}</th>
</thead>
<tbody class="grid_row_container">
<tr class="grid_row blank_row">
<td class="grid_handle"> </td>
<td width="0%" data-fieldtype="text" data-column-id="1">
<div class="grid_cell">
<input type="text" name="testing[rows][new_row_0][col_id_1]" value="" dir="ltr" field_content_type="all" maxlength="256" />
</div>
</td>
<td width="0%" data-fieldtype="text" data-column-id="2">
<div class="grid_cell">
{phrase:form_delete}
<input type="text" name="testing[rows][new_row_0][col_id_2]" value="" dir="ltr" field_content_type="all" maxlength="256" />
</div>
</td>
</tr>
<tr class="empty_field">
<td colspan="3" class="empty_field first">{phrase:form_no-rows} {phrase:form_add-data}</td>
</tr>
</tbody>
</table>
</td>
<td class="grid_delete_row_gutter"> </td>
</tr>
<tr>
<td>
{phrase:form_add-row}
</td>
</tr>
You would then just set those phrases in your Publisher's control panel and it should do the job.
Bare in mind: this is a bit of a hacky solution, and if Grid's markup changes you'll have to rinse and repeat.