File Manager
Editing: products.php
<?php require_once 'header.php'; ?> <!-- Products Header --> <section class="hero"> <div class="container"> <h1>Our Products</h1> <p>Browse our extensive collection of quality products tailored to your needs.</p> </div> </section> <!-- Products Grid --> <section class="section"> <div class="container"> <?php if (!empty($all_products)): ?> <div class="products-grid"> <?php foreach ($all_products as $product): ?> <div class="product-card" data-category="<?php echo htmlspecialchars($product['category'] ?? 'general'); ?>"> <div style="height: 150px; overflow: hidden; margin-bottom: 1rem;" class="product-image"> <?php if (!empty($product['image1'])): ?> <div> <img src="<?php echo htmlspecialchars($product['image1']); ?>" alt="<?php echo htmlspecialchars($product['title'] ?? 'Product'); ?>" style="width: 100%; height: 100%; object-fit: cover;"> </div> <?php else: ?> <div style="height: 150px; background: #f0f0f0; display: flex; align-items: center; justify-content: center; margin-bottom: 1rem;"> <i class="fas fa-image fa-2x" style="color: #ccc;"></i> </div> <?php endif; ?> </div> <div class="product-info"> <span class="product-category"><?php echo htmlspecialchars($product['category'] ?? 'General'); ?></span> <h3><?php echo htmlspecialchars($product['name'] ?? 'Product Title'); ?></h3> <!-- <p><?php echo htmlspecialchars($product['description'] ?? 'Product description goes here...'); ?></p> --> <div class="price">Tsh: <?php echo number_format($product['price'] ?? 99.99, 2); ?></div> <div class="product-actions"> <a href="https://eizononline.com/product?card_id=<?php echo htmlspecialchars($product['card_id']); ?>" class="btn">View Details</a> <button class="btn btn-secondary" onclick="window.location.href='https://wa.me/+255746868834?text=Habari!%20I%20am%20interested%20in%20your%20product%20<?= urlencode($product['name']) ?>%20on%20eizon%20:%20<?= urlencode('https://www.eizononline.com/product.php?card_id=' . $product['card_id']) ?>';"> Contact Seller </button> </div> </div> </div> <?php endforeach; ?> </div> <?php else: ?> <div class="no-products"> <div class="empty-state"> <i class="fas fa-box-open fa-4x"></i> <h3>No Products Available</h3> <p>There are currently no products listed for this account.</p> <a href="services.php" class="btn">View Our Services Instead</a> </div> </div> <?php endif; ?> <div class="text-center"> <a href="https://eizononline.com/profile.php?user=<?php echo htmlspecialchars($username); ?>" class="btn"> <i class="fas fa-external-link-alt"></i> See More on Eizon </a> </div> </div> </section> <?php require_once 'footer.php'; ?>
💾 Save
⬅ Back