What do you recommend for a homepage in Wordpress: - Make a page and use it as a cover? - Use the home.php or front-page.php? - Do it directly in index.php?
What would be the most convenient option ???
thanks !!
What do you recommend for a homepage in Wordpress: - Make a page and use it as a cover? - Use the home.php or front-page.php? - Do it directly in index.php?
What would be the most convenient option ???
thanks !!
WordPress does not work that way, you have to make a page inside the CMS, then Settings - > Reading you can select how you started a static page on the page you made.
If you want to change the appearance, then you should edit the page.php or front-page.php
For more information, you can consult the official documentation at: link
Wordpress works by templates or themes (Themes), these are located in the folder / wp-content / themes / to add a new template you just have to upload it via FTP or through a panel like Cpanel to that directory (Uncompressed, it does not work if you upload a file in .zip or .rar format). If what you want is to create your own template you just have to create a folder in that directory with the name you want and add the following:
styles.css <-- Aparte de ser la hoja de estilos de tu sitio da de alta tu tema en el sistema de wordpress (Pero no activa tu plantilla) -->
<--
Tu archivo styles.css deberá contener:
/*
Theme Name: Este es el nombre de tu plantilla
Theme URI: http://example.com
Description: Diseñoo #1 de mi propiedad
Author: Jorhel Reyes
Author URI: http://facebook.com/king.jorhel
Version: 1
*/
-->
index.php <-- Será la portada de tu página -->
header.php <-- La parte de arriba de todas tus páginas, si no se espefica, todas tus secciones deberán tener un diseño distinto, para agregar el contenido de este archivo debes agregar en el codigo de tu página (ej: index.php) wp_header(); -->
footer.php <-- la parte de abajo de tu página, las mismas condiciones que header, para incluir el contenido de este deberás agregar wp_footer(); -->
single.php <-- en donde se mostrarán tus entradas o posts, se manejan por bucles, investiga "the_post()" -->
category.php <-- Lista las entradas de una categoria en concreto (tambien maneja bucles) -->
page.php <-- las secciones de tu página, estas no se pueden anidar en categorías por eso tienen un archivo diferente, aunque su estructura es casi la misma que en single.php -->
These are the most used, here we have, comments, author, 404, etc., etc. If you do not specify any of these files (except header and footer) the system will show index.php
Here is a better explained example: link
I recommend that you make a page (it can be empty) and in Settings-> Read the selections as static.
In addition to the above, if you want a completely different design, create a page for example " cover " and your php / html design save it in the template directory with the name "< strong> page-portada.php "(page- {slug} .php), even with this option you must select it in Settings-> Reading as static.