WordPress.org

Ready to get started?Download WordPress

Forums

Will an edited WP include php file get overwritten during next update? (5 posts)

  1. ixwa
    Member
    Posted 3 years ago #

    Sometimes WP's setup is utterly confounding.

    Almost everything is in some way customizable via css, template files or functions.php, but trying to customize the structure and layout of the "Reply" form (that follows a blog post) is buried in the deepest parts of wp-settings and wp-config files. I have no idea why this is different.

    In the "comment-template.php" include file (in wp-includes) the commented section says that you can add variables to the $defaults array...but is this change permanent or will it just be overwritten during the next WP update?

    Does anybody know?

  2. Any changes you make to WordPress CORE files will be overwritten when you upgrade. So don't ;)

    but trying to customize the structure and layout of the "Reply" form (that follows a blog post) is buried in the deepest parts of wp-settings and wp-config files. I have no idea why this is different.

    The comment form? Totally themable.

    http://ottopress.com/2010/wordpress-3-0-theme-tip-the-comment-form/

  3. ixwa
    Member
    Posted 3 years ago #

    Thanks. The $fields array mentioned in this link are precisely the ones I'm looking at...in the "comment-template.php" include file in /wp-includes...which is a core file. Huh? I don't get it.

    I had earlier tried copying just that function/array into functions.php and, predictably, it throws an error.

    Where is this new set of $field array variables entered? Into functions.php? Into the comments.php theme file? I'm definitely not following this.

  4. You saw this example, right?

    <?php comment_form(array('title_reply'=>'Leave a Reply, Stupid')); ?>

    Some of them can go right in your comments.php theme file. Which ones are you trying to edit?

    http://codex.wordpress.org/Function_Reference/comment_form has some examples too

  5. ixwa
    Member
    Posted 3 years ago #

    Yes but I couldn't get this working other than just changing the title. I tried his example of adding new vars to the array (in functions.php) but I couldn't get it to work. Then changing the outputted HTML in comment_form_before and _after didn't work either.

    Problem is it's not just an edit I need; at first I thought the comment_form_before and _after fields might be enough but I actually need to *insert* a couple of divs right after <div id="respond"> (and later on as well) which so far I haven't figured out.

    I don't understand why this particular element is so much more difficult to customize than any other WP-specific HTML elements. Strange.

Topic Closed

This topic has been closed to new replies.

About this Topic