Back to top

Visualizza post

Questa sezione ti permette di visualizzare tutti i post inviati da questo utente. N.B: puoi vedere solo i post relativi alle aree dove hai l'accesso.


Topics - frullino

Pagine: [1]
1
Gestione e-commerce / Modificare Prodotti in offerta
« il: 06 Lug 2012, 18:56:38 »
Qualcuno sa dirmi perchè continua a metterli in verticale anzichè in orizzontale?
Le ho provate tutte.
Potete vedere qui l'effetto: http://www.sweetart.it/shop/vmchk/product-search.html?keyword=sangallo

e qui il codice che sto modificando per farli mettere in orizzontale in una griglia 3x3

file: featuredProducts.tpl.php

Codice: [Seleziona]
<?php if( !defined'_VALID_MOS' ) && !defined'_JEXEC' ) ) die( 'Direct Access to '.basename(__FILE__).' is not allowed.' ); 

$iCol 3;
//Number of featured products to show per row
$featured_per_row 3;
//Set the cell width
$cellwidth 210;

if( empty( 
$featured_products )) {
    return; 
// Do nothing, if there are no Featured!
}
echo 
"<h3>".$VM_LANG->_('VM_FEATURED_PRODUCT')."</h3>";
foreach( 
$featured_products as $featured ) {
    
?>

       <div class="related">
    <div class="module" style="width:<?php echo $cellwidth ?>px; height:auto;">           
    <div style="width:<?php echo $cellwidth ?>px; height:auto;" ><div><div><br>
         <center>
         
         <a title="<?php echo $featured["product_name"?>" href="<?php $sess->purl(URL."index.php?option=com_virtuemart&amp;page=shop.product_details&amp;flypage=".$featured["flypage"]."&amp;product_id=".$featured["product_id"]) ?>">
            <h4><?php echo $featured["product_name"?></h4></a>
            <?php echo $featured['product_price'?><br />
            <?php
            
if ( $featured["product_thumb"] ) { ?>

                <a title="<?php echo $featured["product_name"?>" href="<?php $sess->purl(URL."index.php?option=com_virtuemart&amp;page=shop.product_details&amp;flypage=".$featured["flypage"]."&amp;product_id=".$featured["product_id"]) ?>">
                <?php echo ps_product::image_tag$featured["product_thumb"], " border=\"0\" alt=\"".$featured["product_name"]."\"");
                
?>
</a><br /><br/>
            <?php
            
}?>

            <?php //echo $featured['product_s_desc'] ?>
           
            <?php echo $featured['form_addtocart'
            
?>

           
            </center><br />
    </div></div></div></div></div>
    <?php
    
// Do we need to close the current row now?
    
if ($iCol == $featured_per_row) { // If the number of products per row has been reached
        
echo "<br style=\"clear:both;\" />\n";
        
$iCol 1;
    }
    
}

?>

<br style="clear:both;" />


Grazie in anticipo

2
Ho provato ad aggiungere questa riga al file product.product_inventory.php (VM 1.1.7):
percorso file: /administrator/components/com_virtuemart/html
riga 145

Codice: // inizio modifica

    $listObj->addCell( $db->f("product_sku") );
    $listObj->addCell( '<input type="text" class="inputbox" size="3" name="qta" value="'.$db->f("product_in_stock").'" onchange="document.adminForm'.$i.'.product_in_stock.value = this.value; this.value;document.adminForm'.$i.'.changed.value=\'1\';">                 
            <input type="button" class="button" onclick="if(document.adminForm'. $i .'.changed.value!=\'1\') else adminForm'.$i.'.submit();" name="Submit" value="Aggiorna" />'    );
    //$listObj->addCell( $db->f("product_in_stock") );

    // fine modifica

ora ho la possibilità di vedere la quantità e di poterla editare, solo che quando premo il tasto Aggiorna non aggiorna la quantità...

Consigli ??
Grazie

Pagine: [1]


Web Design Bolzano Kreatif