WordPress.org

Ready to get started?Download WordPress

Forums

Text editing capability? (10 posts)

  1. derrick.derrick
    Member
    Posted 1 year ago #

    First off, this is the site I'm working on: http://kelarobinson.com/wordpresstest/

    I've been coding websites by hand in notepad for over 10 years. On this page it's easy to see a simple code error that displays: "if; ?>"

    I've been able to click on "view source" from my browser, and it's easy to see the offending line of code. But how would I go about removing it? How do I edit lines of code?

    I logged into wp-admin, and under appearance I found "Editor." It's fantastic, in that it gives me the ability to edit some pages, but none of them are the homepage.

    It's incredibly frustrating. If I just knew the name of the file or had some way to edit it I'd be happy. Any advice is greatly appreciated.

  2. derrick.derrick
    Member
    Posted 1 year ago #

    Also, I would like to edit or delete the "sample page".

    On the sample page on the bottom it say: "As a new WordPress user, you should go to your dashboard to delete this page and create new pages for your content. Have fun!"

    However, in my dashboard, there is nowhere to delete the sample page. It seems like it should be easy, but it just doesn't exist. Any ideas?

  3. ModularBase
    Member
    Posted 1 year ago #

    Home Page is your index.php file in Appearance > Editor.

    For the Page, you can go to Pages. Click on the page and it opens in the Visual/Text Editor. You can select the text and delete it, then add your own.

    To change its Title, go to Pages and hover over the page name (don't click it). Under you will see "Quick Edit".
    Click this and change the Title and the slug underneath. The slug must have dashes "-" between each word and match the title. When done, click "Update" button on right.

  4. derrick.derrick
    Member
    Posted 1 year ago #

    Thanks for the reply, but I've already tried that unfortunately. When viewing the index.php file, this is all the code I see:

    <?php
    get_header();
    query_posts( 'posts_per_page='.get_option_tree('blog_posts_nr').'&paged='.$paged.'&cat='.$cat.'&author='.$author.'&tag='.$tag );
    ?>
    
    <div class="inner">
    
        <?php
    
        $the_template = get_option_tree('blog_template');
    
        if($the_template){
            $the_template = strtolower((str_replace (" ", "-", $the_template)));
            include "templates/blog/".$the_template.".php";
        }else{
            include "templates/blog/right-sidebar-1.php";
        }
    
        ?>    
    
    <?php
    get_footer();
    ?>

    Unfortunately none of this code contains the offending code that I wish to remove. It must be a different file other than the index.php. Any ideas?

  5. ModularBase
    Member
    Posted 1 year ago #

    Seems to be on all your pages and posts.
    Check: header.php and footer.php. If not there, see if you have a loop.php and carefully check that.

    If you can't find it, then contact the theme designers : http://themeforest.net/item/purity-responsive-clean-minimal-bold-wp-theme/639774

  6. derrick.derrick
    Member
    Posted 1 year ago #

    The offending code was in header.php. Thanks! I'm having some other issues though. Whenever I make a new blog post, the header on the page changes to the title of the blog post. Ex, "Test1" or "Test2". I'd like to be able to make blog posts but have the header at the top of the page just remain static and not change. Is there any way to edit this?

    Also, I don't want comments. Is there a way to turn comments off in the blog?

  7. ModularBase
    Member
    Posted 1 year ago #

    The header is above "Test1" or "Test2". These are the individual titles for the posts. These can be eliminated, but you would have to create a Child Theme to do it.

    "Also, I don't want comments. Is there a way to turn comments off in the blog?"

    Go to Settings > Discussion and deselect "Allow people to post comments on new articles". If comments still show up in the posts you already have, go to each post and deselect Discussion for the post.

    btw "The offending code was in header.php." - this may reappear when the theme is updated. You should contact the theme developer with this error.

  8. derrick.derrick
    Member
    Posted 1 year ago #

    I'll have to do some research into Child Themes, thanks for the tip!

    I went into Discussion and deselected "Allow people to post comments on new articles", however it's still possible to leave comments. Where should I look next?

    I contacted the developer and let him/her know of the issue, I'm sure it's just a small oversight.

    Thanks again!
    -Derrick

  9. ModularBase
    Member
    Posted 1 year ago #

    Did you "If comments still show up in the posts you already have, go to each post and deselect Discussion for the post."?

    You should see "Comments are closed." below the post.

  10. Christiaan Conover
    Member
    Posted 1 year ago #

    derrick.derrick,

    Disabling comments in Settings -> Discussion will only apply to posts created after you changed the setting. Each individual post and page has its own comment settings. For posts and pages created before you made the change you'll need to disable commenting on each of those manually.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.