Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Jimmy13anhelo/paginaweb2.github.io/llms.txt

Use this file to discover all available pages before exploring further.

Sentidos Café runs on a standard PHP + Apache + MySQL stack, which means you can have a fully working local copy running in under ten minutes using XAMPP or WAMP. No Composer dependencies, no build steps — just copy the files, import the schema, and open your browser.

Prerequisites

Before you begin, make sure you have the following available:
  • PHP 7.4 or higher — required for PDO named exceptions and str_contains usage
  • MySQL 5.7 or higher — the schema uses DECIMAL(10,2), DEFAULT CURRENT_TIMESTAMP, and ON DUPLICATE KEY UPDATE
  • Apache — the project uses standard require_once includes with relative paths; no .htaccess rewrite rules required
  • phpMyAdmin (optional but recommended) — bundled with both XAMPP and WAMP; makes importing script.sql one click
XAMPP (Windows/macOS/Linux) and WAMP (Windows) are the fastest ways to get all three services — Apache, MySQL, and phpMyAdmin — running together with a single installer. Download XAMPP at apachefriends.org or WAMP at wampserver.com.

Setup Steps

1

Install XAMPP or WAMP and start services

After installing your preferred stack, open the XAMPP Control Panel (or the WAMP tray icon) and start both the Apache and MySQL services. Both indicators should turn green before you proceed.Confirm Apache is running by visiting http://localhost — you should see the XAMPP or WAMP welcome page.
2

Copy the project files into your web root

Clone or download the repository, then place the entire project folder inside your web root:
# XAMPP (Windows default)
C:\xampp\htdocs\sentidos-cafe\

# XAMPP (macOS default)
/Applications/XAMPP/htdocs/sentidos-cafe/

# WAMP (Windows default)
C:\wamp64\www\sentidos-cafe\
After copying, your web root should look like this:
sentidos-cafe/
├── index.php
├── conexion.php
├── buscador.js
├── estilo.css
├── script.sql
├── logo.jpg
├── plaza.png
├── menu/
├── pedidos/
├── reservas/
└── Login/
3

Create the database and import the schema

  1. Open phpMyAdmin at http://localhost/phpmyadmin
  2. Click New in the left sidebar
  3. Enter the database name: sentidos_cafe_db and click Create
  4. Select the new database, then click the Import tab
  5. Click Choose File, select script.sql from your project folder, and click Go
phpMyAdmin will create all three tables (pedidos, reservas, usuarios) and insert the default admin user automatically.Alternatively, run the schema directly from the MySQL command line:
mysql -u root -p < C:\xampp\htdocs\sentidos-cafe\script.sql
4

Verify the database credentials in conexion.php

Open conexion.php in a text editor and confirm the four connection variables match your local MySQL setup. XAMPP and WAMP both use root with an empty password by default:
$host = "localhost";
$db_name = "sentidos_cafe_db";
$username = "root";
$password = ""; // If you set a password in MySQL Workbench, enter it here

try {
    $conexion = new PDO("mysql:host=$host;dbname=$db_name;charset=utf8", $username, $password);
    $conexion->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
} catch(PDOException $error) {
    die("Error de conexión: " . $error->getMessage());
}
If you set a custom MySQL root password during installation, enter it between the quotes on the $password line. Every PHP page in the project pulls this file in via require_once 'conexion.php', so you only need to change it in one place.
The default root user with an empty password is suitable only for local development. Never deploy conexion.php with these credentials to a public or production server. Always create a dedicated MySQL user with a strong password and the minimum required privileges before going live.
5

Open the site in your browser

Navigate to:
http://localhost/sentidos-cafe/index.php
You should see the full Sentidos Café homepage — the orange header with the circular logo, the navigation bar, the welcome section with the coffee cup image, the Google Maps embed showing the Cusco location, the four combo cards with WhatsApp order buttons, and the contact footer.To access the admin login, go to:
http://localhost/sentidos-cafe/Login/login.php
Log in with the seeded credentials: user admin / password admin123.

Troubleshooting

“Error de conexión” on page load This error is thrown directly by the catch(PDOException $error) block in conexion.php. The most common causes are:
  • MySQL is not running — go back to the XAMPP/WAMP control panel and start the MySQL service
  • Wrong password in $password — check whether you set a root password during MySQL installation
  • The database doesn’t exist yet — make sure you completed Step 3 and the sentidos_cafe_db database appears in phpMyAdmin
Blank white page with no output PHP is likely encountering a fatal error but suppressing output. Enable error display temporarily by adding these two lines to the very top of index.php (remove them before any deployment):
ini_set('display_errors', 1);
error_reporting(E_ALL);
Then reload the page to see the exact error message. You can also check the Apache error log at C:\xampp\apache\logs\error.log (XAMPP Windows) or /Applications/XAMPP/logs/error_log (XAMPP macOS). WhatsApp buttons open but send to the wrong number The WhatsApp phone number is hardcoded in buscador.js as 937604465 (Peru). If you are testing with a different number, find the numeroTelefono constant inside the DOMContentLoaded callback (Section 2 — WhatsApp logic) and update it:
const numeroTelefono = "937604465"; // Replace with your number (no + or spaces)

Build docs developers (and LLMs) love