How to Customize, Modify or Change WordPress Database Connection Error Page »ç¿ëÀÚ ÁöÁ¤ÇÏ´Â ¹æ¹ý, ¼öÁ¤ ¶Ç´Â º¯°æ WordPress µ¥ÀÌŸº£À̽º ¿¬°á ¿À·ù ÆäÀÌÁö·Î
When ¾ðÁ¦ WordPress ¿öµå , a popular blog publishing platform built in PHP and uses MySQL database, cannot connect or having problem connecting to the database (such as when database is down), or the MySQL server has too many connections exceeding maximum connection allowed (especially when your post or article is been dugg on Digg.com) and rejects or denies new incoming connections, WordPress will display a default ¡°error establishing database connection¡± error message page. , ÀαâÀÖ´Â ºí·Î±×°¡ ÃâÆÇ Ç÷§Æû ±¸Ãà ¹× PHP¿¡¼ MySQL µ¥ÀÌÅͺ£À̽º¸¦ »ç¿ëÇÏ¿© ¿¬°áÇÒ ¼ö ¾ø°Å³ª µ¥ÀÌÅͺ£À̽º¿¡ ¿¬°áÇÏ´Â µ¥ ¹®Á¦ (¿¹ : µ¥ÀÌÅͺ£À̽º°¡ ´Ù¿îµÇ¸é) ¶Ç´Â MySQL ¼¹ö°¡ ³Ê¹« ¸¹Àº ¿¬°á °ü°è¸¦ ÃʰúÇÏ´Â ÃÖ´ë Çã¿ë (ƯÈ÷ ±ÍÇÏÀÇ °Ô½Ã¹°À» ¶§ ¶Ç´Â ¹®¼ Digg.com¿¡) duggµÇ¾î ÀÖ°í °ÅºÎÇϰųª »õ·Î µé¾î¿À´Â ¿¬°áÀ» °ÅºÎ, WordPressÀÇ ±âº»À» Ç¥½ÃÇÑ´Ù "¿À·ù"¶ó´Â ¿À·ù ¸Þ½ÃÁö°¡ ÆäÀÌÁöÀÇ µ¥ÀÌÅͺ£À̽º ¿¬°áÀ» ±¸ÃàÇß½À´Ï´Ù. However, the WordPress error page, some is shown below, is not visitor friendly or user friendly, and worse, the default database error page also reveals the SQL server address and name. ±×·¯³ª, WordPressÀÇ ¿À·ù ÆäÀÌÁö, ¾Æ·¡, ¹æ¹®ÀÚ Ä£È ¶Ç´Â »ç¿ëÀÚ Ä£ÈÀûÀÎ, ±×¸®°í ´õ ÀÖÁö ¾Ê´Ù¸é, ±âº» µ¥ÀÌÅͺ£À̽º ¿À·ù ÆäÀÌÁöµµ ¹àÈ÷Áö´Â SQL ¼¹öÀÇ ÁÖ¼Ò¿Í À̸§ÀÌ Ç¥½ÃµË´Ï´Ù.
Can¡¯t select database µ¥ÀÌÅͺ£À̽º¸¦ ¼±ÅÃÇÒ ¼ö¾ø½À´Ï´Ù
We were able to connect to the database server (which means your username and password is okay) but not able to select the localhost database. ¿ì¸®´Â µ¥ÀÌÅͺ£À̽º ¼¹ö¿¡ ¿¬°áÇÒ ¼ö ÀÖ¾ú´Ù (»ç¿ëÀÚ À̸§°ú ºñ¹Ð ¹øÈ£¸¦ ÀǹÌ)´Â ·ÎÄà µ¥ÀÌÅͺ£À̽º¸¦ ¼±ÅÃÇÒ ¼ö¾ø½À´Ï´ÙÇÏÁö¸¸ ±¦Âú½À´Ï´Ù.
* Are you sure it exists? * ´ç½ÅÀÌ Á¸Àç½Ã°Ú½À´Ï±î?
* On some systems the name of your database is prefixed with your username, so it would be like username_wordpress. µ¥ÀÌÅͺ£À̽ºÀÇ À̸§ÀÌ ±ÍÇÏÀÇ »ç¿ëÀÚ À̸§°ú Á¢µÎ»ç°¡ ÀϺΠ½Ã½ºÅÛ *, ±×·¸°Ô username_wordpressó·³ µÉ °ÍÀÌ´Ù. Could that be the problem? ±×°Ô ¹®Á¦°¡ µÉ ¼ö ÀÖÀ»±î¿ä?If you don¡¯t know how to setup a database you should contact your host. ¸¸¾à µ¥ÀÌÅͺ£À̽º¸¦ ¼³Ä¡ÇÏ´Â ¹æ¹ýÀº ¿©·¯ºÐÀÌ È£½ºÆ®¿¡ ¹®ÀÇÇØ¾ß ¸ð¸£°Ú¾î. If all else fails you may find help at the WordPress Support Forums. ´Ù¸¥ °Ç ´Ù ¸øÇÏ´õ¶óµµ ´ç½ÅÀº WordPressÀÇ Áö¿ø Æ÷·³¿¡¼ µµ¿òÀ» ¾òÀ» ¼öÀÖ½À´Ï´Ù ½ÇÆÐÇÕ´Ï´Ù.
Error establishing a database connection ¿À·ù°¡ µ¥ÀÌÅͺ£À̽º ¿¬°áÀ» ¼³Á¤
This either means that the username and password information in your wp-config.php file is incorrect or we can¡¯t contact the database server at localhost. À̰͵µ ´ç½ÅÀÇ Æ÷½ºÆ®¿¡¼ »ç¿ëÀÚ À̸§°ú ºñ¹Ð ¹øÈ£ Á¤º¸ - config.php ÆÄÀÏÀÇ Àǹ̰¡ ¿Ã¹Ù¸£Áö ¾Ê½À´Ï´Ù ¶Ç´Â ¿ì¸®°¡ ·ÎÄÿ¡¼ µ¥ÀÌÅͺ£À̽º ¼¹ö¿¡ Á¢¼ÓÇÒ ¼ö¾ø½À´Ï´Ù. This could mean your host¡¯s database server is down. ÀÌ ¿©·¯ºÐÀÇ È£½ºÆ®ÀÇ µ¥ÀÌÅͺ£À̽º ¼¹ö°¡ ´Ù¿î ¼öµµÀÖ´Ù´Â ¶æÀÌ´Ù.
Are you sure you have the correct username and password? ´ç½ÅÀº ¿Ã¹Ù¸¥ »ç¿ëÀÚ À̸§°ú ºñ¹Ð ¹øÈ£°¡ È®½ÇÇѰ¡¿ä?
Are you sure that you have typed the correct hostname? ´ç½ÅÀÇ ¿Ã¹Ù¸¥ È£½ºÆ®¸¦ ÀÔ·Â È®½ÅÇÏ´Ï?
Are you sure that the database server is running? ´ç½ÅÀº ±× µ¥ÀÌÅͺ£À̽º ¼¹ö°¡ ½ÇÇàµÇ°í ÀÖ´ÂÁöÀΰ¡¿ä?
These default Wordpress database error pages are more meant for website administrators or webmasters rather than the public visitors. ÀÌ·¯ÇÑ ±âº» WordPress µ¥ÀÌŸº£À̽º ¿À·ù ÆäÀÌÁö ÀÌ»óÀÇ À¥»çÀÌÆ® °ü¸®ÀÚ ¶Ç´Â À¥¸¶ ½ºÅͰ¡ ¾Æ´Ñ ±¹¹ÎÀÇ ¹æ¹®ÀÚ¿¡ ´ëÇÑ Àǹ̰¡¾ø½À´Ï´Ù. However, you can change the error page to another different error page by modifying or altering wordings and text in the error page by customizing the wp-db.php file located in wp-include directory. ±×·¯³ª, ´ç½ÅÀº ¶Ç ´Ù¸¥ ¿À·ù ÆäÀÌÁö¸¦ ¼öÁ¤Çϰųª ¿À·ù ÆäÀÌÁöÀÇ ÅØ½ºÆ®¸¦ º¯°æÇϰí wp¸¦ wordings - db.php wp¸¦¿¡ÀÖ´Â ÆÄÀÏ - Ä¿½º ÅÍ ¸¶ÀÌ¡ÇÏ¿© ¿À·ù ÆäÀÌÁö¸¦ º¯°æÇÒ ¼öÀÖ½À´Ï´Ù µð·ºÅ丮¿¡ Æ÷ÇԵ˴ϴÙ. Here¡¯s how you can hack the Wordpress default error message. ÀÌ·¸°Ô ´ç½ÅÀº Wordpress ±âº» ¿À·ù ¸Þ½ÃÁö¸¦ ÇØÅ·ÇÒ ¼öÀÖ¾î.
In wp-db.php (the file that handles the database connections that WordPress makes), you can see lines like ¡°DB Constructor - connects to the server and selects a database¡± and ¡°Select a DB (if another one needs to be selected)¡±. -°¡ ¿öµå wp¸¦ ¸¸µå´Â µ¥ÀÌÅͺ£À̽º ¿¬°áÀ» ó¸®ÇÏ´Â), "DB°¡ »ý¼ºÀÚ - °°Àº ¶óÀÎÀ» º¼ ¼öÀÖ½À´Ï´Ù (db.php ÆÄÀÏ ¼¹ö¿¡ ¿¬°áÇÏ°í µ¥ÀÌÅͺ£À̽º¸¦ ¼±ÅÃÇÕ´Ï´Ù"¿Í "DB¸¦ ¼±ÅÃÇÏ´Â °æ¿ì ÇϳªÀÇ ¿ä±¸ (¼±Á¤ÇØ¾ß ) ". That¡¯s where you can alter the text and word in the error page. ±×°Ç ¾îµð ¿À·ù ÆäÀÌÁöÀÇ ÅØ½ºÆ®¿Í ´Ü¾î¸¦ º¯°æÇÒ ¼öÀÖ½À´Ï´Ù. Just look carefully after the line, you will see exactly the some text and message as appeared on the database error page. ´ÜÁöÁÖÀÇ ±í°Ô ¶óÀÎ º¸¸é, ´ç½ÅÀº Á¤È®È÷ ¾î¶² ÅØ½ºÆ®¿Í ¸Þ½ÃÁö·Î ÆäÀÌÁö¿¡ °ÔÀçµÈ µ¥ÀÌÅͺ£À̽º ¿À·ù°¡ ³ªÅ¸³³´Ï´Ù. Edit them to your liking. ¸¶À½¿¡ µå´Â ±×µéÀ» ÆíÁýÇÕ´Ï´Ù.

Beside, from line 312 onwards is the header and footer output for the HTML of database connection error page, contains inside function named ¡°bail¡±, which specifies things like the title of ¡°WordPress: Error¡±. °Ô´Ù°¡, 312 ¶óÀο¡¼ ²÷ÀÓ¾øÀÌ ¸Ó¸®±Û°ú ¹Ù´Ú±Û µ¥ÀÌÅͺ£À̽º ¿¬°á ¿À·ù ÆäÀÌÁöÀÇ HTML¿¡ ´ëÇÑ Ãâ·Â, ³»ºÎ´Â "º¸¼®", ¿öµå "ÀÇ Á¦¸ñ : ¿À·ù °°Àº °ÍµéÀÇ À̸§À» ÁöÁ¤ÇÏ´Â ±â´É"ÀÌ Æ÷ÇԵǾîÀÖ½À´Ï´Ù. The ¡°bail¡± function is called whenever a database connection error is encountered, and does what it¡¯s name said - bails out the error and displays an error message instead to notify the users. "º¸¼®"±â´ÉÀ» ¼öÇàÇÒ ¶§¸¶´Ù µ¥ÀÌÅͺ£À̽º ¿¬°á ¿À·ù°¡ ¹ß»ýÇß½À´Ï´ÙÀÌ´Ù,¶ó´Â ±×°ÍÀÇ À̸§À» ¸»ÇÑ - bails ¾Ê´Â ¿À·ù°¡ ¹ÛÀ¸·Î Å뺸ÇÏ´Â ´ë½Å »ç¿ëÀÚ¿¡°Ô ¿À·ù ¸Þ½ÃÁö°¡ Ç¥½ÃµË´Ï´Ù. You can change them if you like too. ¸¸¾à ´ç½ÅÀÌ ³Ê¹« ÁÁ¾Æ ´ç½ÅÀº ±×µéÀ» º¯°æÇÒ ¼öÀÖ½À´Ï´Ù.
Please take a backup of wp-db.php file before you customize or alter it. wp¸¦ÇϽñ⠹ٶø´Ï´ÙÀÇ ¹é¾÷À» ¹Þ¾Æ - db.php ÆÄÀÏÀ»Çϱâ Àü¿¡ »ç¿ëÀÚ Á¤ÀÇÇϰųª º¯°æÇÒ ¼ö¾ø½À´Ï´Ù. If you break the code, your website visitors and surfers will get the PHP error instead. ¸¸¾à ´ç½ÅÀÇ À¥»çÀÌÆ® ¹æ¹®ÀÚ¿Í ¼ÆÛ ´ë½Å ¿À·ù¸¦ ¾òÀ» °ÍÀÌ´Ù´Â PHP ÄÚµå ÈÞ½Ä. Beside, be careful that when you upgrade your WordPress. °Ô´Ù°¡, ±× ¶§ ´ç½ÅÀÌ WordPressÀÇ ¾÷±×·¹ÀÌ µå¸¦ Á¶½ÉÇϼ¼¿ä. If you overwrite all files when upgrade the WordPress, the wp-db.php will be replaced back with the original unchanged version too, and you have to edit the file again. WordPressÀÇ °æ¿ì ¶§, ¸ðµç ÆÄÀÏÀ» µ¤¾î wp¸¦ - db.php ¾÷±×·¹ ÀÌµå ¹öÀüÀ¸·Î ´Ù½Ã ¿ø·¡ º¯µ¿µµ ±³Ã¼°¡ µÉ °ÍÀ̸ç, ´Ù½Ã ÆÄÀÏÀ» ÆíÁýÇØ¾ßÇÕ´Ï´Ù. Else, backup the wp-db.php before upgrading your WordPress and restore it after upgrading is done. ¶Ç, wp¸¦ - db.phpÇÏ¿© WordPressÀÇ ¾÷±×·¹ÀÌ µå¿Í ¾÷±×·¹ÀÌ µå ÈÄ º¹¿øÇϱâ Àü¿¡ ¹é¾÷ ÀÌ·ç¾îÁý´Ï´Ù.
IMPORTANT : This is a machine translated page which is provided "as is" without warranty. Áß¿ä :ÀÌ ±â°è´Â "º¸Áõµµ¾øÀÌÀÖ´Â ±×´ë·Î"Á¦°øµË´Ï´Ù ÆäÀÌÁö¸¦ ¹ø¿ªÇß´Ù. Machine translation may be difficult to understand. ±â°è ¹ø¿ªÀ» ÀÌÇØÇϱ⠾î·Á¿ï ¼öÀÖ½À´Ï´Ù. Please refer to À» ÂüÁ¶ÇϽñ⠹ٶø´Ï´Ù original English article ¿ø·¡ ¿µ¾î ¹®¼ whenever possible. ¾ðÁ¦µç °¡´ÉÇÕ´Ï´Ù.
Share and contribute or get technical support and help at °øÀ¯¿Í ±â¿©Çϰųª ±â¼ú Áö¿ø°ú¿¡ µµ¿òÀÌ My Digital Life Forums ³» µðÁöÅÐ »ýȰ Æ÷·³ .
Related Articles °ü·Ã ±â»ç
- How to Change the Frequency or Interval WordPress Auto Saves An Editing Post or Page ¾î¶»°Ô Á֯ļö¸¦ ÀÚµ¿À¸·Î ¼¼À̺긦 ÆíÁý ¶Ç´Â °£°Ý WordPressÀÇ Æ÷½ºÆ® ¶Ç´Â ÆäÀÌÁö¸¦ º¯°æÇÏ´Â ¹æ¹ý
- Paginating or Split WordPress Post or Page with NextPage in WordPress Not Working WordPressÀÇ Paginating ¶Ç´Â ½ºÇø´ Æ÷½ºÆ® ¶Ç´Â ÆäÀÌÁö Nextpage ÇÔ²² ¿öµå¿¡ ¾È µÊ
- Modify and Change Remote Desktop Listening Port ¿ø°Ý µ¥½ºÅ©ÅéÀ» ¼ö½Å ´ë±â Æ÷Æ®¸¦ ¼öÁ¤ÇÏ°í º¯°æ
- How to Convert Character Set and Collation of WordPress Database ¹®ÀÚ ÁýÇÕ°ú Á¤·ÄÇÏ´Â ¹æ¹ýÀ» º¯È¯ WordPress µ¥ÀÌŸº£À̽ºÀÇ
- Change or Modify the Drive Letter and Paths in Windows Vista µå¶óÀÌºê ¹®ÀÚ ¹× °æ·Î º¯°æ ¶Ç´Â ¼öÁ¤ Windows VistaÀÇ
- Oracle EXP-00091 Error When Export Database ¿À¶óŬ ÀÖµµ·Ï EXP - 00091 ¿À·ù°¡ ¹ß»ýÇßÀ» ¶§ µ¥ÀÌÅͺ£À̽º ³»º¸³»±â
- Change Oracle Database User Password ¿À¶óŬ µ¥ÀÌÅͺ£À̽º »ç¿ëÀÚ ºñ¹Ð ¹øÈ£ º¯°æ
- Oracle Database Import Error 3113/3114 Oracle µ¥ÀÌÅͺ£À̽º °¡Á®¿À±â ¿À·ù 3,114ºÐÀÇ 3,113
- Vista IE7 ¡°No Connection to the Internet is Currently Available¡± Error ºñ½ºÅ¸´Â IE7Àº "ÀÎÅͳݿ¡ ¿¬°á ÇöÀç ¾øÀ½"¿À·ù »ç¿ëÇÒ ¼öÀÖ½À´Ï´Ù
- Create, Add or Split Oracle Database Partition Fails with ORA-14080 Error , ¶Ç´Â ¿À¶óŬ µ¥ÀÌÅͺ£À̽º ÆÄƼ¼Ç ºÐÇÒ Ãß°¡ ¸¸µé±â ORA - 14080 ¿À·ù¿Í ÇÔ²² ½ÇÆÐ
































