test
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • apusweb Friend
    #133399

    Hello,

    I have the following problem in staffing ja_mesolite, I’m changing a little code in the following route:

    components com_virtuemart themes ja-mesolite templates common categoryChildlist.tpl.php.

    The modification is to that the sub categories are not placed in a horizontally form but in a vertically form, but I could not make it work.

    Could you help me form find the solution?

    Thank you

    Putting sub categories of VirtueMart in a vertically form.

    apusweb Friend
    #270851

    I have decided and I work well:

    templates/apusweb/css/templates.css

    Line: 322

    Previous

    .category {
    font-weight: bold;
    text-transform: uppercase;

    change

    .category {
    font-weight: bold;
    text-transform: uppercase;
    padding-left: 100px;
    }
    .category ul {
    margin: 0;
    padding: 0;
    }

    .category ul li {
    margin: 0;
    padding: 0 0 0 0px;
    }

    ——–
    componentscom_virtuemartthemesja-mesolitetemplatescommon

    line: 14 // Change is a table a css

    Previous

    <table width=”100%” cellspacing=”0″ cellpadding=”0″>
    <?php
    foreach( $categories as $category ) {
    if ($iCol == 1) { // this is an indicator wether a row needs to be opened or not
    echo “<tr>n”;
    }
    ?>

    <td align=”center” width=”<?php echo $cellwidth ?>%” >
    <br />
    <a class=”category” title=”<?php echo $category[“category_name”] ?>” href=”<?php $sess->purl(URL.”index.php?option=com_virtuemart&page=shop.browse&category_id=”.$category[“category_id”]) ?>”>
    <?php
    if ( $category[“category_thumb_image”] ) {
    echo ps_product::image_tag( $category[“category_thumb_image”], “alt=””.$category[“category_name”].”””, 0, “category”);
    echo “<br /><br/>n”;
    }
    echo $category[“category_name”];
    echo $category[‘number_of_products’];
    ?>
    </a><br/>
    </td>

    <?php
    // Do we need to close the current row now?
    if ($iCol == $categories_per_row) { // If the number of products per row has been reached
    echo “</tr>n”;
    $iCol = 1;
    }
    else {
    $iCol++;
    }
    }
    // Do we need a final closing row tag?
    if (sizeof( $categories ) < $categories_per_row) {
    echo “</tr>n”;
    }
    ?>
    </table>

    change

    <div>
    <?php
    foreach( $categories as $category ) {
    if ($iCol == 1) { // this is an indicator wether a row needs to be opened or not
    echo “<tr>n”;
    }
    ?>

    <td align=”center” width=”<?php echo $cellwidth ?>%” >
    <br />
    <a class=”category” title=”<?php echo $category[“category_name”] ?>” href=”<?php $sess->purl(URL.”index.php?option=com_virtuemart&page=shop.browse&category_id=”.$category[“category_id”]) ?>”>
    <?php
    if ( $category[“category_thumb_image”] ) {
    echo ps_product::image_tag( $category[“category_thumb_image”], “alt=””.$category[“category_name”].”””, 0, “category”);
    echo “<br /><br/>n”;
    }
    echo $category[“category_name”];
    echo $category[‘number_of_products’];
    ?>
    </a><br/>
    </td>

    <?php
    // Do we need to close the current row now?
    if ($iCol == $categories_per_row) { // If the number of products per row has been reached
    echo “</tr>n”;
    $iCol = 1;
    }
    else {
    $iCol++;
    }
    }
    // Do we need a final closing row tag?
    if (sizeof( $categories ) < $categories_per_row) {
    echo “</tr>n”;
    }
    ?>
    </div>

    I have performed well and appear in a vertically form

    I hope to help them

    apusweb Friend
    #270853

    I have decided and I work well:

    templates/apusweb/css/templates.css

    Line: 322

    Previous

    .category {
    font-weight: bold;
    text-transform: uppercase;

    change

    .category {
    font-weight: bold;
    text-transform: uppercase;
    padding-left: 100px;
    }
    .category ul {
    margin: 0;
    padding: 0;
    }

    .category ul li {
    margin: 0;
    padding: 0 0 0 0px;
    }

    ——–
    componentscom_virtuemartthemesja-mesolitetemplatescommon

    line: 14 // Change is a table a css

    Previous

    <table width=”100%” cellspacing=”0″ cellpadding=”0″>
    <?php
    foreach( $categories as $category ) {
    if ($iCol == 1) { // this is an indicator wether a row needs to be opened or not
    echo “<tr>n”;
    }
    ?>

    <td align=”center” width=”<?php echo $cellwidth ?>%” >
    <br />
    <a class=”category” title=”<?php echo $category[“category_name”] ?>” href=”<?php $sess->purl(URL.”index.php?option=com_virtuemart&page=shop.browse&category_id=”.$category[“category_id”]) ?>”>
    <?php
    if ( $category[“category_thumb_image”] ) {
    echo ps_product::image_tag( $category[“category_thumb_image”], “alt=””.$category[“category_name”].”””, 0, “category”);
    echo “<br /><br/>n”;
    }
    echo $category[“category_name”];
    echo $category[‘number_of_products’];
    ?>
    </a><br/>
    </td>

    <?php
    // Do we need to close the current row now?
    if ($iCol == $categories_per_row) { // If the number of products per row has been reached
    echo “</tr>n”;
    $iCol = 1;
    }
    else {
    $iCol++;
    }
    }
    // Do we need a final closing row tag?
    if (sizeof( $categories ) < $categories_per_row) {
    echo “</tr>n”;
    }
    ?>
    </table>

    change

    <div>
    <?php
    foreach( $categories as $category ) {
    if ($iCol == 1) { // this is an indicator wether a row needs to be opened or not
    echo “<tr>n”;
    }
    ?>

    <td align=”center” width=”<?php echo $cellwidth ?>%” >
    <br />
    <a class=”category” title=”<?php echo $category[“category_name”] ?>” href=”<?php $sess->purl(URL.”index.php?option=com_virtuemart&page=shop.browse&category_id=”.$category[“category_id”]) ?>”>
    <?php
    if ( $category[“category_thumb_image”] ) {
    echo ps_product::image_tag( $category[“category_thumb_image”], “alt=””.$category[“category_name”].”””, 0, “category”);
    echo “<br /><br/>n”;
    }
    echo $category[“category_name”];
    echo $category[‘number_of_products’];
    ?>
    </a><br/>
    </td>

    <?php
    // Do we need to close the current row now?
    if ($iCol == $categories_per_row) { // If the number of products per row has been reached
    echo “</tr>n”;
    $iCol = 1;
    }
    else {
    $iCol++;
    }
    }
    // Do we need a final closing row tag?
    if (sizeof( $categories ) < $categories_per_row) {
    echo “</tr>n”;
    }
    ?>
    </div>

    I have performed well and appear in a vertically form

    I hope to help them

    topmanx Friend
    #270949

    nice write up, thanks!

    apusweb Friend
    #271003

    sorry if I write badly, but I do not speak English well.

    The translation by the I google

Viewing 5 posts - 1 through 5 (of 5 total)

This topic contains 5 replies, has 2 voices, and was last updated by  apusweb 16 years, 3 months ago.

We moved to new unified forum. Please post all new support queries in our New Forum