css - how to modify html on homepage (no home-page.php in my theme)

admin2025-06-03  2

I would like to modify the html in on my homepage from

<div id="slide-6996" class="slide slide-6996 cycle-slide-active slide-left light" style="background-image:url(http://18.205.33.160/wp-content/uploads/2019/02/ITData-Home-Page2018-01-edited.jpg);">
                <div class="slide-body">
                    <div class="container">
                        <div class="slide-caption">
                            <div class="slide-content">
                                <h1><strong>COMPREHENSIVE IT SERVICES YOU CAN TRUST</strong></h1>
                            </div>
                                <h2 class="slide-title"> Let us help you develop an IT Optimization Strategy and Define your technological priorities</h2>

        <a class="slide-link button button-medium" href="http://18.205.33.160/index.php/itone-method/"> Learn how we can help you succeed </a>
        <a class="post-edit-link" href="http://18.205.33.160/wp-admin/post.php?post=6996&amp;action=edit">Edit</a>                          </div>
            <div class="slide-image">
        </div>
    </div>
</div>

to the code that is located here ~> /

However, when I go to appearance > editor , I do not see a home page php file that is there for me to modify only page templates (which do not have the slider I am trying to modify)

What is the best way to go about trouble shooting/modifying my homepage HTML code?

I would like to modify the html in on my homepage from

<div id="slide-6996" class="slide slide-6996 cycle-slide-active slide-left light" style="background-image:url(http://18.205.33.160/wp-content/uploads/2019/02/ITData-Home-Page2018-01-edited.jpg);">
                <div class="slide-body">
                    <div class="container">
                        <div class="slide-caption">
                            <div class="slide-content">
                                <h1><strong>COMPREHENSIVE IT SERVICES YOU CAN TRUST</strong></h1>
                            </div>
                                <h2 class="slide-title"> Let us help you develop an IT Optimization Strategy and Define your technological priorities</h2>

        <a class="slide-link button button-medium" href="http://18.205.33.160/index.php/itone-method/"> Learn how we can help you succeed </a>
        <a class="post-edit-link" href="http://18.205.33.160/wp-admin/post.php?post=6996&amp;action=edit">Edit</a>                          </div>
            <div class="slide-image">
        </div>
    </div>
</div>

to the code that is located here ~> https://jsfiddle/2xb34dev/

However, when I go to appearance > editor , I do not see a home page php file that is there for me to modify only page templates (which do not have the slider I am trying to modify)

What is the best way to go about trouble shooting/modifying my homepage HTML code?

Share Improve this question asked Feb 13, 2019 at 18:48 blaublau 133 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 0

First, keep in mind that you aren't meant to edit a theme directly. WordPress's Appearance > Editor presents security risks, and can allow you to modify things in a way that breaks your site, so it is best to disable it entirely. Any time you modify a theme, and then update that theme, all of your changes will be lost.

Instead, create a child theme, where the only real required files are style.css with comments that let WP know it is a child theme, and then whatever files you want to override. This will allow you to continue using and updating your theme, but apply a few changes here or there as needed.

Different themes use different files to control the homepage, especially depending on whether you are using a Page as your front page or a traditional list of Posts. Some themes may use front-page.php or home.php if you are using a traditional list; if you are using a Page, there are a variety of Page templates such as plain old page.php, or more specific ones like page-slug.php, page-id.php, or even a template such as tpl-custom-page.php. The WP template hierarchy explains all the possible theme files and what order they are used in - the Visual Overview is especially helpful in cases like this where you're trying to track down which specific file is being used. It is also possible to use various plugins which can show you what template is being used for a particular URL's display.

转载请注明原文地址:http://conceptsofalgorithm.com/Algorithm/1748910602a314740.html

最新回复(0)