• 赤色のリンクは、まだ日本語Codexに存在しないページ・画像です。英語版と併せてご覧ください。(詳細

このWikiはいつでも誰でも編集できます

「FAQ/トラブルシューティング」の版間の差分

提供: WordPress Codex 日本語版
< FAQ
移動先: 案内検索
(en:FAQ Troubleshooting 2008年4月2日 (水) 02:17 MichaelH 版)
 
(内容を「このページは https://ja.wordpress.org/support/article/faq-troubleshooting/ へ移動しました。」で置換)
 
(5人の利用者による、間の15版が非表示)
1行目: 1行目:
[[FAQ|Back to FAQ]]
+
このページは https://ja.wordpress.org/support/article/faq-troubleshooting/ へ移動しました。
__TOC__
+
<div style="clear:both">
+
</div>
+
 
+
 
+
==Why can't I see my posts? All I see is ''Sorry, no posts match your criteria''?==
+
 
+
Clearing your browser cache and cookies may resolve this problem.  Also, check your <tt>search.php</tt> and <tt>index.php</tt> template files for errors.
+
 
+
See also:
+
 
+
* [[I Make Changes and Nothing Happens]]
+
 
+
==How do I find more help?==
+
 
+
There are various resources that will help you find more help with WordPress, in addition to these [[FAQ]].  You can also increase your search capabilities by adding the [http://asymptomatic.net/2005/07/20/1765/codex-searcher/ Codex and Forum Searcher Plugin] and search both the Codex and Forum from your WordPress Administration Panels. Click on one of the search results and the page will open in a new window or tab so you can have the article or discussion open while working on WordPress.
+
 
+
* [[Troubleshooting]]
+
* [[Finding WordPress Help]]
+
* [[Using the Support Forums]]
+
* [[Technical Articles|Resources and Technical Articles about WordPress]]
+
* [[Troubleshooting#Installation_Problems|Installation Problems]]
+
 
+
===Where can I find help with the CSS problems I'm having?===
+
 
+
The following are articles that will help you troubleshoot and solve many of your [[CSS]] problems:
+
 
+
* [[Blog Design and Layout]]
+
* [[Finding Your CSS Styles]]
+
* [[CSS Fixing Browser Bugs]]
+
* [[CSS Troubleshooting]]
+
* [[CSS|WordPress CSS Information and Resources]]
+
 
+
==Why does the password emailed to me look weird?==
+
If the password emailed to you looks strange, see [http://allnarfedup.com/2004/11/10/solving-garbled-text/ Solving Garbled Text].
+
 
+
==How to fix my site statistics problem on a WordPress 2.x blog hosted at Dreamhost?==
+
 
+
Dreamhost has a kb/wiki post about this called, [http://wiki.dreamhost.com/index.php/Making_stats_accessible_with_htaccess Making stats accessible with htaccess].
+
 
+
==Why do I get an error message about ''Sending Referrers''?==
+
If you got this message when trying to save a post, consider checking [[Administration_Panels|Administration]] > [[Administration_Panels#General|Settings]] > [[Settings_General_SubPanel|General]] and make sure both your '''WordPress address (URI)'''  and the '''Blog address (URI)''' do not use 'www'.  For example, instead of '''<nowiki>http://www.sample.com</nowiki>''' use '''<nowiki>http://sample.com</nowiki>''' in those fields.  This information orginally reported via http://wordpress.org/support/topic/72235
+
 
+
See also:
+
* [[Enable Sending Referrers]]
+
 
+
==Are there are any problems with using MySQL 4.1.7 for WordPress?==
+
 
+
See  [[FAQ_Installation#Can_I_install_WordPress_on_Windows_2000.3F|Can I install WordPress on Windows 2000?]]
+
 
+
==How do I empty a database table?==
+
See  also:
+
* [[Emptying a Database Table]]
+
 
+
==How do I fix the following error ''SQL/DB Error errcode 13 Can't create/write to file''?==
+
'''Problem:''' The MySQL variable <tt>tmpdir</tt> is set to a directory that cannot be written to when using PHP to access MySQL.
+
 
+
To verify this, enter MySQL at the command line and type <tt>show variables</tt>;
+
 
+
You'll get a long list and one of them will read: '''tmpdir = /somedir/''' (whatever your setting is.)
+
 
+
'''Solution:''' Alter the '''tmpdir''' variable to point to a writable directory.
+
 
+
'''Steps:'''
+
<ol>
+
<li>Find the '''my.cnf''' file. On *nix systems this is usually in '''/etc/'''.</li>
+
<li>Once found, open this in a simple text editor and find the '''[mysqld]''' section.</li>
+
<li>Under this section, find the '''tmpdir''' line. If this line is commented (has a '''#''' at the start), delete the '''#''' and edit the line so that it reads: '''tmpdir = /writable/dir''' where '''/writable/dir''' is a directory to which you can write. Some use '''/tmp''', or you might also try '''/home//'''.
+
</li>
+
<li>Save the file.</li>
+
<li>Shutdown MySQL by typing <tt>mysqlshutdown -u -p shutdown</tt>.</li>
+
<li>Start MySQL by going to the MySQL directory and typing <tt>./bin/safe_mysqld &</tt>. Usually the MySQL directory is in '''/usr/local''' or sometimes in '''/usr/''' on Linux systems.
+
</li>
+
</ol>
+
If none of this make sense and you have someone to administrate your system for you, show the above to them and they should be able to figure it out.
+
 
+
==How do I solve the ''Headers already sent'' warning problem?==
+
 
+
'''Description:''' You get a warning message on your browser that says:
+
 
+
<tt>Warning: Cannot modify header information - headers already sent by
+
(output started at</tt>
+
 
+
'''Reason and Solution :'''
+
 
+
It is usually because there are spaces, new lines, or other garbage
+
before an opening '''<tt><?php</tt>''' tag or after a closing '''<tt>?></tt>''' tag, typically in
+
'''wp-config.php'''. This could be true about some other file too, so please check the error message, as it will list the specific file name where the error occurred (see "Interpreting the Error Message" below).  Replacing the faulty file with one from your most recent backup or one from a fresh WordPress download is your best bet, but if neither of those are an option, please follow the steps below.
+
 
+
Just because you cannot see anything does not mean that PHP sees the same.
+
 
+
# Download the file mentioned in the error message.
+
# Open that file in a [[Glossary#Text editor|plain text editor]] ('''NOT''' MS Word or similar. Notepad or BBEdit are fine).
+
# Check that the ''very'' first characters are '''<tt><?php</tt>'''
+
# Check that the ''very'' last characters are '''<tt>?></tt>'''
+
 
+
To be sure about the end of the file, do this:
+
#Place the cursor between the ? and >
+
#Now press the DELETE key on your computer
+
#*Note to MAC users: The "DELETE" key on a PC deletes characters to the ''right'' of the cursor.  That is the key noted here.
+
#Keep that key pressed
+
#For at least 15 seconds
+
#Now type > and
+
#'''save''' without pressing any other key at all.
+
#If you press another key, you will bring the problem back.
+
 
+
'''Interpreting the Error Message:'''
+
 
+
If the error message states: <code>Warning: Cannot modify header information - headers already sent by (output started at /path/blog/wp-config.php:34) in /path/blog/wp-login.php on line 42</code>, then the problem is at line #34 of <code>wp-config.php</code>, not line #42 of <code>wp-login.php</code>.  In this scenario, line #42 of <code>wp-login.php</code> is the victim.  It is being affected by the excess whitespace at line #34 of <code>wp-config.php</code>.
+
 
+
If the error message states: <code>Warning: Cannot modify header information - headers already sent by (output started at /path/wp-admin/admin-header.php:8) in /path/wp-admin/post.php on line 569</code>, then the problem is at line #8 of <code>admin-header.php</code>, not line #569 of <code>post.php</code>.  In this scenario, line #569 of <code>post.php</code> is the victim.  It is being affected by the excess whitespace at line #8 of <code>admin-header.php</code>.
+
 
+
==Why can't I see the visual rich editor when using Apple's Safari browser?==
+
 
+
'''Description:''' The visual rich editor in the Write interface (aka "the WYSIWYG editor") does not display when using Apple's Safari browser.
+
 
+
'''Reason and Solution:'''
+
In early versions of Safari, the visual rich editor would cause the browser to crash immediately upon loading the Write interface.  This was due to a bug in Safari, not WordPress.  Since the WordPress developers had no way of correcting this, they chose to disable the visual rich editor for Safari users.  At this point in time, there are three alternatives for affected users.  One could '''upgrade to Safari 3.0.4 or higher and WordPress 2.3 or higher''', use [http://www.mozilla.com/firefox/ Firefox] or [http://caminobrowser.org/ Camino], or de-select "Users should use the visual rich editor by default" in [[Administration_Panels|Administration]] > [[Administration_Panels#Writing|Settings]] > [[Settings_Writing_SubPanel|Writing]]  and install [http://wordpress.org/extend/plugins/deans-fckeditor-for-wordpress-plugin/ Dean's FCKEditor For WordPress].
+
 
+
==Why can't I see the Quicktag buttons when using Apple's Safari browser?==
+
 
+
'''Description:''' The Quicktag buttons in the Write interface do not display when using Apple's Safari browser.
+
 
+
'''Reason and Solution:'''
+
In early versions of Safari, the Quicktag buttons would function, but not as intended.  This was due to a bug in Safari, not WordPress.  Since the WordPress developers had no way of correcting this, they chose to disable the Quicktag buttons for Safari users.  At this point in time, there are three alternatives for affected users.  One could '''upgrade to Safari 2.0.4 or higher and WordPress 2.0.7 or higher''', use [http://www.getfirefox.com Firefox] or [http://www.caminobrowser.org/ Camino], or (for earlier versions of WordPress) remove the <tt>if</tt> statement on line 1085 and the word "<tt>else</tt>" on line 1092 of <tt>/wp-admin/admin-functions.php</tt> .
+
 
+
For example, change this:
+
<pre>function the_quicktags() {
+
// Browser detection sucks, but until Safari supports the JS needed for this to work people just assume it's a bug in WP
+
if (!strstr($_SERVER['HTTP_USER_AGENT'], 'Safari'))
+
echo '
+
<div id="quicktags">
+
<script src="../wp-includes/js/quicktags.js" type="text/javascript"></script>
+
<script type="text/javascript">if ( typeof tinyMCE == "undefined" || tinyMCE.configs.length < 1 ) edToolbar();</script>
+
</div>
+
';
+
else echo '
+
<script type="text/javascript"></pre>
+
 
+
to this:
+
<pre>function the_quicktags() {
+
// Browser detection sucks, but until Safari supports the JS needed for this to work people just assume it's a bug in WP
+
echo '
+
<div id="quicktags">
+
<script src="../wp-includes/js/quicktags.js" type="text/javascript"></script>
+
<script type="text/javascript">if ( typeof tinyMCE == "undefined" || tinyMCE.configs.length < 1 ) edToolbar();</script>
+
</div>
+
';
+
echo '
+
<script type="text/javascript"></pre>
+
 
+
==E-mailed passwords are not being received==
+
'''Description:''' When users try to register with your blog or change their passwords by entering their username and email, WordPress indicates that their password has been emailed to them, but it is never received.
+
 
+
'''Reason and Solution:'''  WordPress uses the standard php mail function, which uses sendmail.  No account information is needed. This is not generally a problem if you are using a hosting service, but if you are using your own box and do not have an SMTP server, the mail will never send.  If you are using a *NIX box, you should have either postfix or sendmail on your machine; you will just need to set them up (Google for how-to's).  If you do not want to go through setting up a complete mail server on your *NIX box you may find [http://packages.debian.org/stable/mail/ssmtp ssmtp] useful -- it provides ''"A secure, effective and simple way of getting mail off a system to your mail hub"''.  On a Windows machine, try a sendmail emulator like [http://glob.com.au/sendmail/ Glob SendMail].
+
 
+
More help can be found on the forums at: http://wordpress.org/support/topic.php?id=24981
+
 
+
As a plugin-based alternative, you could try [http://www.coffee2code.com/archives/2004/06/28/plugin-wpphpmailer/ wpPHPMailer].  It ''"enables WordPress to send e-mail via SMTP instead of via PHP's mail() function (aka sendmail)."''
+
 
+
'''Windows Host Specific:'''  With the plugin mentioned above you can work around the issue of e-mails not being received. 
+
 
+
Another alternative is to edit the ''class-pop3.php'' file in wp-includes, there is a variable, ''$MAILSERVER'', which allows you to hard code your smtp server.  However, ''wp-php.php'' in the root directory actually loops through depending on the author to determine a value to set the from address on the e-mail and defaults to the admin address particularly in the case of users registering.
+
 
+
This is fine if your admin address is a valid e-mail address.  For example, if your admin e-mail is: ''admin@"yourhost.com"'', your smtp server must also be ''smtp."yourhost.com"''.  If the domains do not match your mail will not send.  (Your SMTP server may not require authentication however, your host in most cases still checks to make sure incoming SMTP traffic is still valid.  This is to prevent spam.)
+
 
+
When using the plugin wpPHPMailer the same applies, and there is an option to hard code the from address.
+
 
+
==How do I get the Quicktag <nowiki><!--nextpage--></nowiki> back?==
+
For some reason,  the <nowiki><!--nextpage--></nowiki> Quicktag button was "removed" in 1.5.1. To get it back, just do the following:
+
 
+
'''In Wordpress 1.5.x'''
+
 
+
Open ''wp-admin/quicktags.js'' in a text editor and locate this section (starting at line 135):
+
<pre>
+
/*
+
edButtons[edButtons.length] =
+
new edButton('ed_next'
+
,'page'
+
,'<!--nextpage-->'
+
,''
+
,'p'
+
,-1
+
);
+
*/
+
</pre>
+
Just remove the /* and */ lines to uncomment the block of code.  That should return the button to your editing windows.
+
 
+
'''In Wordpress 2.0.x'''
+
 
+
Open ''wp-includes/js/quicktags.js'' in a text editor and locate this section (starting at line 135):
+
<pre>
+
//
+
edButtons[edButtons.length] =
+
new edButton('ed_next'
+
,'page'
+
,'<!--nextpage-->'
+
,''
+
,'p'
+
,-1
+
);
+
//
+
</pre>
+
Just remove the two // lines after and before the block of code to uncomment it. 
+
 
+
Now Open '''wp-includes/js/tinymce/plugins/wordpress/editor_plugin.js'' in a text editor and locate this section (starting at line 15):
+
<pre>
+
var buttons = '<a href="javascript:tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcewordpressmore\')" target="_self" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcewordpressmore\');return false;"><img id="{$editor_id}_wordpress_more" src="{$pluginurl}/images/more.gif" title="'+titleMore+'" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" /></a>';
+
// Add this to the buttons var to put the Page button into the toolbar.
+
// '<a href="javascript:tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcewordpresspage\')" target="_self" onclick="javascript:tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcewordpresspage\');return false;"><img id="{$editor_id}_wordpress_page" src="{$pluginurl}/images/page.gif" title="'+titlePage+'" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" /></a>';
+
</pre>
+
 
+
On line 17 copy the text between the apostrophes and paste it at the end of line 15 exactly before the trailing '; as follows:
+
 
+
<pre>
+
var buttons = '<a href="javascript:tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcewordpressmore\')" target="_self" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcewordpressmore\');return false;"><img id="{$editor_id}_wordpress_more" src="{$pluginurl}/images/more.gif" title="'+titleMore+'" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" /></a> <a href="javascript:tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcewordpresspage\')" target="_self" onclick="javascript:tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcewordpresspage\');return false;"><img id="{$editor_id}_wordpress_page" src="{$pluginurl}/images/page.gif" title="'+titlePage+'" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" /></a>';
+
</pre>
+
 
+
This will show the the Quicktag <nowiki><!--nextpage--></nowiki> again. You can also enable the hotkey access by doing just one more thing. Open '''wp-includes/js/tinymce/plugins/wphelp/editor_plugin.js'' with a text editor. Note that it's not the same file as the one from the previous step, as although it has the same name it is on a different path. Locate the following lines (should be line 23 and 24):
+
<pre>
+
+ '<input type="button" accesskey="t" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcewordpressmore\');" />'
+
+ '<input type="button" accesskey="u" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Undo\',false);" />'
+
</pre>
+
Copy line 23, paste it as a new line just below line 23, and edit it as follows:
+
<pre>
+
+ '<input type="button" accesskey="t" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcewordpressmore\');" />'
+
+ '<input type="button" accesskey="p" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcewordpresspage\');" />'
+
+ '<input type="button" accesskey="u" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Undo\',false);" />'
+
</pre>
+
This will enable the Alt+P shortcut for the <nowiki><!--nextpage--></nowiki> tag.
+
 
+
==I used the Quicktag <nowiki><!--nextpage--></nowiki> in a post so why doesn't it work?==
+
In some [[Using Themes|Themes]], such as the WordPress Classic Theme, you may see the <nowiki><!--nextpage--></nowiki> work properly on your main page, but other [[Using Themes|Themes]], such as the WordPress default Theme,  may only show the ''page break'' when viewing the posts individually.  It may be necessary to change your Theme's [[Templates|template]] ''page.php'' or ''index.php'' file to make this feature work according to your wishes.  You'll need to add the following:
+
<pre><?php wp_link_pages(); ?> ?</pre>
+
 
+
== MySQL Error 28 ==
+
 
+
You get the following error:
+
 
+
Error code 28: No space left on device
+
 
+
This is a MySQL error and has nothing to do with WordPress directly; you should contact your host about it. Some users have reported that running a "repair table" command in [[phpMyAdmin]] fixed the problem.
+
 
+
[http://www.mysql.com/newsletter/2003-10/a0000000249.html Error 28, and how to avoid it]:
+
 
+
<pre>
+
If you get this error, check all filesystems in
+
which MySQL operates. If you followed recommendations
+
to split datadir, tmpdir and log files into dedicated
+
filesystems, more than one filesystem is involved. In
+
addition, be aware that MySQL often creates temporary
+
tables for some queries. Most of these are placed in
+
tmpdir; however, some may be found in the database
+
directory (e.g. ALTER TABLE). Also, ensure that
+
sufficient free disk space is available for MySQL.
+
</pre>
+
 
+
It could be because:
+
* you are out of space on /tmp (wherever tmpdir is), or,
+
* you have too many files in /tmp (even if there is lots of free space)
+
 
+
Relevant discussion threads:
+
* http://wordpress.org/support/3/1738
+
* http://wordpress.org/support/3/2923
+
* http://wordpress.org/support/3/2760
+
 
+
==Why are the Quote Marks escaped or not escaped?==
+
 
+
If you write plugins, or use a plugin like [http://www.nosq.com/2004/10/runphp-wordpress-plugin/ RunPHP], or make advanced custom templates, you may eventually find yourself dealing with data in the database.  WordPress <em>usually</em> manages this data for you in such a way that it is immediately usable.  There are circumstances though (especially if you are dealing directly with the database without using WordPress) where you will experience weirdness.
+
 
+
For example, quote marks cannot be stored directly in the MySQL database. MySQL uses quote marks in its SQL language. When a quote mark is used, for example, in a post, When the post is saved to the database, every quote mark gets escaped. That means a backslash character is prepended, which signifies that the next character should be taken as part of the input, and not as part of the SQL command. 
+
 
+
For example, if you are adding the following in your post:
+
 
+
<pre>...an article about "Happiness" is at
+
<a href="http://example.com/happy" title="Happiness">Happiness</a>
+
if you would like to read it...</pre>
+
 
+
Is actually imported into the database looking like this:
+
 
+
<pre>...an article about \"Happiness\" is at
+
<a href=\"http://example.com/happy\" title=\"Happiness\">Happiness</a>
+
if you would like to read it...</pre>
+
 
+
When pulling data out of the database, the backslashes may not always be automatically removed. If this becomes an issue, you can use the [http://www.php.net/stripslashes stripslashes()] PHP function on the text.
+
 
+
==Why do I get a blank page when I submit a comment?==
+
'''Description:''' When anyone tries to comment on a post, the window goes blank and the comment doesn't appear to have been recognised by WordPress.
+
 
+
'''Reason and Solution:'''
+
The Theme that you are using is missing a critical part of the comment form so WordPress doesn't know which post the comment refers to.  You need to check the comment.php in your Theme and ensure that the following code appears within the form.
+
<pre>
+
<input type="hidden" name="comment_post_ID" value="<?php echo $id; ?>" />
+
</pre>
+
 
+
Relevant discussion threads:
+
 
+
* http://wordpress.org/support/topic/38683
+
 
+
[[FAQ|Back to FAQ]]
+
 
+
[[Category:Troubleshooting]]
+
[[Category:WordPress Help]]
+
 
+
[[en:FAQ Troubleshooting]]
+

2020年3月17日 (火) 22:53時点における最新版

このページは https://ja.wordpress.org/support/article/faq-troubleshooting/ へ移動しました。