WordPress Call To Undefined Function get_currentuserinfo() PHP Error Tumawag sa WordPress Upang Undefined Function get_currentuserinfo () PHP Error

After uploading, installing and activation some plugins for WordPress blog publishing system, the plug-ins may cause the following PHP error message, logged by Apache web server error_log file or been displayed on web pages which looks like the following line: Matapos mag-upload, i-install at activation ilang mga plugins para sa WordPress blog-publish na sistema, ang mga plug-ins maaaring maging sanhi ng mga sumusunod na PHP mensahe ng error, naka-log sa pamamagitan ng Apache web server error_log file o ay ipinapakita sa mga pahina ng web na kung saan tila ang mga sumusunod na linya:

Fatal error: Call to undefined function: get_currentuserinfo() in /wordpress/wp-content/plugins/plugin.php Fatal error: Tawag sa malabo function: get_currentuserinfo () in / wordpress / content-WP / plugins / plugin.php


To make matter worse, these plugins are working fine previously, and suddenly broken down or throwing out the error. Upang gumawa ng bagay na mas masahol pa, ang mga ito plugin ay gumawa pagmultahin dati, at biglang nasira down o masusuka ang mga error. The cause of the issue is due to the reason that get_currentuserinfo() function is defined within pluggable.php of WordPress core. Ang sanhi ng isyu ay dahil sa ang dahilan na get_currentuserinfo () function ay tinukoy sa loob ng pluggable.php ng WordPress core. The problem is that pluggable.php is only been loaded after all the plugins has been loaded. Ang problema ay na pluggable.php lamang ay puno na matapos ang lahat ng mga plugins ay na-load. It means that get_currentuserinfo() is not yet available when plugins are triggering and needing the function. Ibig sabihin nito na get_currentuserinfo () ay hindi pa magagamit kapag plugin ay naghuhudyat at nangangailangan ng function.

To resolve the fix the “call to undefined get_currentuser() function error, just call pluggable.php prior to calling function the requires it. Upang malutas ang ayusin ang "ang tawag sa hindi tiyak get_currentuser () function error, tumawag lamang pluggable.php bago pagtawag ang function ay nangangailangan nito. A little PHP programming skill is required, but for novice, it's not hard to re-code the plugin source code to get the error solved. Ang isang maliit na PHP programming kasanayan ay kailangan, ngunit para sa mga baguhan, ito ay hindi mahirap na muli ang code plugin source code para makuha ang error na lutasin.

Search for the get_currentuser in the PHP file which the error indicates having problem. Search para sa get_currentuser sa PHP file na kung saan ang error ay nagpapahiwatig ng pagkakaroon ng problema. Then copy and paste the following lines before (on top of) the line of get_current_user(). Pagkatapos, kopyahin at idikit ang mga sumusunod na linya sa harap (sa itaas) sa linya ng get_current_user ().

require(ABSPATH . WPINC . '/pluggable.php'); nangangailangan (ABSPATH. WPINC. '/ pluggable.php');

Tip: It's also possible substitute require with requice_once so that pluggable.php is unloaded once the get_currentuser() function is executed. Tip: Posible din nangangailangan ng kapalit sa requice_once kaya pluggable.php na diskargado sa sandaling ang get_currentuser () function ay naisakatuparan.

For example, Halimbawa, ang

require (ABSPATH . WPINC . '/pluggable.php');
get_currentuserinfo();

IMPORTANT : The page is machine translated and provided "as is" without warranty. MAHALAGA: Ang pahina ng makina ay isinalin at ibinigay "bilang ganito" walang warranty. Machine translation may be difficult to understand. Machine pagsasalin ay maaaring mahirap maintindihan. Please refer to Mangyaring sumangguni sa original English article orihinal na Ingles na artikulo whenever possible. hangga't maaari.


One Response to “WordPress Call To Undefined Function get_currentuserinfo() PHP Error” One Response sa "Tawag WordPress Upang Undefined Function get_currentuserinfo () PHP Error"

  1. Call to Undefined Function get_currentuserinfo() Error in WordPress » Tip and Trick Tawag sa Undefined Function get_currentuserinfo () Error sa WordPress »Payo at trick
    October 28th, 2009 22:23 Oktubre 28, 2009 22:23
    1 1

    [...] Above trick does not work in new WordPress version, try the fix undefined function get_currentuserinfo() fatal error guide [...] [...] Lansihin itaas ay hindi gumagana sa bagong bersyon ng WordPress, subukan ang ayusin malabo get_currentuserinfo function () mortal error gabay sa [...]

Leave a Reply Iwanan ng isang Sumagot

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> Maaari mong gamitin ang mga tag: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime = ""> <em> <i> <q cite=""> <strike> <strong>

Subscribe to comments feature has been disabled. Mag-subscribe sa mga komento na katangian ay hindi pinagana. To receive notification of latest comments posted, subscribe to Upang makatanggap ng paunawa ng pinakabagong mga puna, mag-subscribe sa My Digital Life Comments RSS feed Aking Digital Life Comments RSS feed or o register to receive magrehistro upang makatanggap ng new comments in daily email digest. mga bagong komento sa pang araw-araw email digest.
Custom Search

New Articles Bagong Akda

Incoming Search Terms for the Article Papasok na Kataga sa Paghahanap para sa mga Artikulo