WordPress / Documentation-Issue-Tracker

Issue Tracker for the WordPress Documentation team.
https://make.wordpress.org/docs/
Other
84 stars 41 forks source link

FAQ's review content #426

Open estelaris opened 2 years ago

estelaris commented 2 years ago

Issue Description

there are several FAQ pages that need content review and decide if we keep them, move them to DevHub or delete them.

URL of the Page with the Issue

FAQ Working with WordPress FAQ installation FAQ troubleshooting FAQ troubleshooting 2 draft FAQ my site was hacked I make changes and nothing happens

Section of Page with the issue

Full articles

Why is this a problem?

Is the content helpful to end-users?

Suggested Fix

Review content and remove any developer jargon or links

github-actions[bot] commented 2 years ago

Heads up @femkreations @atachibana - the "user documentation" label was applied to this issue.

zzap commented 1 year ago

First URL: https://wordpress.org/support/article/faq-working-with-wordpress/

Removed:

How can I find out if I have mod_rewrite?

To get information about your server, you can use the phpinfo() function:

  1. Paste this into text editor
    <?php phpinfo(); ?>
  2. Save as info.php Upload to server. Visit in your browser (www.example.com/info.php)

The info.php file returns a page outlining the details of your PHP installation. You can see if mod_rewrite is loaded. Under the apache header, look in the Loaded Modules section and see if mod_rewiite is listed.


How do I change file and folder permissions?

See:

Changing File Permissions


Does the 644 permissions on wp-config.php compromise the username and password to all other users on my shared server?

This is a limitation of the way PHP is set up on your server. If you previously used Movable Type, Perl was probably set up with suexec so Movable Type executed as your user. In this case, PHP is running as the web server user, which is why it has to be at least 444. There is phpsuexec but it seems many hosts don’t use it.

However this is often not an issue on modern shared hosts because even though the file is “World” readable each account is set up with a “jailshell” which keeps people locked in their home directory, and PHP can be easily modified with an open_basedir restriction to keep people from writing PHP scripts to read your files. If you are really concerned, you should contact your host to see what measures they are taking.


How do I redirect users back to my blog's main page after they login?

By default, WordPress reroutes a registered user to the Administration Screens after they log into the blog. To change the page, there are WordPress Plugins that can handle the redirect, or you can set the Theme function to handle it. See wp_login_url.


How do I change permissions for my files so I can edit them using the Theme Editor?

See:

Changing File Permissions


How do I prevent my images from being hot-linked by another website?

You can use your .htaccess file to protect images from being hot linked, or, in other words, being linked-to from other websites. This can be a drain on your bandwidth, because if someone links directly to the image on your site, then you lose the bandwidth.


How do I backup and restore my WordPress database using phpMyadmin?

See:

Backing Up Your Database and Restoring Your Database From Backup


How do I prevent comment flooding?

Comment flooding is when a lot of comments (probably spam) are posted to your website in a very short duration of time. This is only one aspect of the broader problem of comment spam in general, but it can quickly overwhelm a moderator’s ability to manually delete the offending comments.

WordPress manages the worst floods automatically by default. Any commenters from the same IP or e-mail address (other than registered users with manage_options capabilities) that post within 15 seconds of their last comment gets their comment discarded. The time setting can be changed by a number of plugins that extend this functionality. You might also consider one of the many broader spam blocking plugins, such as Akismet, or even turning your comment system over to Disqus.

You could also just change the time setting by inserting the following filter into functions.php of your current theme. Or you may create and install a very basic plugin and insert the following code:

function dam_the_flood( $dam_it, $time_last, $time_new ) {
    if ( ($time_new - $time_last) < 300 ) // time interval is 300
        return true;                  // seconds
    return false;
}
add_filter('comment_flood_filter', 'dam_the_flood', 10, 3);

Creating plugins can be very easy, the above code actually has most of the work done for you.


How can I have a static front page and posts display on a page as Web site top page?

See:

Creating a Static Front Page This is the example Page Template if you want to display one latest post, instead of the Page content, on your static front page.

<?php
/*
Template Name: MyFront
*/
get_header(); ?>

    <div id="primary" class="content-area">
        <main id="main" class="site-main" role="main">

        <?php
        $args = array('posts_per_page' => 1, 'cat' => 1);
        $the_query = new WP_Query( $args );

        // The Loop
        while ( $the_query->have_posts() ) : $the_query->the_post();

                get_template_part( 'content', get_post_format() );

        // End the loop.
        endwhile;
        ?>       

        </main><!-- .site-main -->
    </div><!-- .content-area -->

<?php get_footer(); ?>

See also:

Stepping Into Templates Forum thread showing this in action


How can I change what appears between Categories when I post in more than one Category?

In Twenty Fifteen theme, the post’s multiple categories are displayed with commas between them. To configure the way the categories display,

Create a Child Themes of Twenty Fifteen theme. Copy twentyfifteen_entry_meta() function from parent’s inc/template-tags.php to child theme’s functions.php.

function twentyfifteen_entry_meta() {
    if ( is_sticky() && is_home() && ! is_paged() ) {
        :
    }
}

Replace ‘, ‘ in the argument of get_the_category_list call in twentyfifteen_entry_meta() function.

$categories_list = get_the_category_list( _x( ', ', 'Used between list items, there is a space after the comma.', 'twentyfifteen' ) );

If you change it by ‘ > ‘, ‘ • ‘ or ‘ | ‘ then you will see an arrow, a bullet or “pipe” (|) between the categories.

Activate the child theme.


How do I disable trackbacks and pingbacks?

Alternatively, you could run this MySQL query from the command line on a shell account or using phpMyAdmin, or through a wp-cli wp db query:

UPDATE wp_posts SET ping_status = 'closed';

How do I find the absolute path I need for uploading images?

  1. Open the below page from your Browser

    http://(site URL)/wp-admin/options.php
  2. Refer upload_url_path option value. If the value is blank, then the directory wp-content/upload is the default destination to save.

NOTE: I'm pretty sure there's a function for getting upload path. Regardless, this shouldn't be advice for end user.


Can I change the “Error establishing database connection” message to something more descriptive?

Just simply create a file to reside at wp-content/db-error.php, and in that file put the message you want displayed to users when WordPress determines the database connection is not available. That file will be used in place of “Error establishing database connection” message. You could even use the db-error.php to redirect users elsewhere. Here’s an example for db-error.php:

<?php
echo '<h2> This site is currently experiencing a problem with the database server.</h2>  Press your browser Reload button to try again!';
?>

How can I change URL-structure for my posts on a Windows server?

See Using Permalinks Without mod rewrite


How do I use WordPress Template Tags to change what is displayed on the blog?

See Template Tags


How do I get All links to open in a new window?

Put this inside the section of your Theme’s template header.php file:

<base target="_blank" />

See:

Using Themes W3 Schools base tag explanation


How can I add an image to my RSS feed?

See Add an image to your RSS 2.0 feed at wordlog.com

zzap commented 1 year ago

First URL: https://wordpress.org/support/article/faq-working-with-wordpress/

Needs updating:

How long is the release cycle of WordPress?

A major release of WordPress happens every 6 months or so. Suggest and vote on ideas for future releases at the WordPress Extend Ideas site.

Also refer WordPress Versions for the chronologically listed versions of WordPress along with the Change Log information on new features and improvements in each version. There are the future releases and links to their respective milestones in the bug tracker.


Why is there no Page Template option when writing or editing a Page?

If there is no Page Template option when writing or editing a Page it may because there is no template file with the proper structure. For the Page Template box to be available to assign to a Page there must be a least one template file in your theme that has a structure at the beginning of the template file that looks like this:

<?php
/*
Template Name: My Custom Page
*/
?>

Create a new PHP file with any name under the theme directory and put above codes into the file. You will see the Page Template box appears that includes “My Custom Page” option in the Page Edit Screen. For more detail about Custom Page Template, refer Page Templates.

NOTE: The code part should be deleted, as well as everything after the first sentence.


How do I disable comments?

Screenshot needs to be updated and remove everything after it.


How do I disable trackbacks and pingbacks?

Check if the content is still valid. Needs screenshots.

How do I change the site admin name?

We shouldn't advise hacky solutions. Username is not meant to be changed. Let's not point end users to change it in database. The proper advice here would be to create a new user with desired username, log in with this user and delete the other one.


What is The Loop?

See The Loop and The Loop in Action

This should be a more end-user-friendly explanation without links to anywhere. Or removed completely.

estelaris commented 1 year ago

There is still too much dev jargon on this article