Title: Problem with wp-polls.php, error 500
Last modified: August 20, 2016

---

# Problem with wp-polls.php, error 500

 *  [Esteban](https://wordpress.org/support/users/tcattitude/)
 * (@tcattitude)
 * [13 years, 10 months ago](https://wordpress.org/support/topic/problem-with-wp-pollsphp-error-500/)
 * Hi,
 * I just hit this error with the 2.63 version of wp-polls:
    PHP Fatal error: Call
   to undefined function add_action() in /*/wp-content/plugins/wp-polls/wp-polls.
   php on line 31 Trying to vote, never works for that. Chrome says there was an
   error 500 on wp-polls.php
 * After digging for a while, i realize that 2.63 it’s called directly by this code:
 *     ```
       <script type='text/javascript'>
       /* <![CDATA[ */
       var pollsL10n = {
       	ajax_url: "http://www.cdf.cl/wp-content/plugins/wp-polls/wp-polls.php",
       	text_wait: "Tu ultima solicitud esta siendo procesada, por favor espera...",
       	text_valid: "Por favor selecciona una respuesta valida.",
       	text_multiple: "Numero maximo de respuestas permitidas: ",
       	show_loading: "1",
       	show_fading: "1"
       };
       /* ]]> */
       </script>
       ```
   
 * Then, doing a comparison of both version, 2.63 and 2.62 or 2.61, i realize you
   don’t include this on top of wp-polls.php file:
 *     ```
       ### Load WP-Config File If This File Is Called Directly
       if (!function_exists('add_action')) {
       	$wp_root = '../../..';
       	if (file_exists($wp_root.'/wp-load.php')) {
       		require_once($wp_root.'/wp-load.php');
       	} else {
       		require_once($wp_root.'/wp-config.php');
       	}
       }
       ```
   
 * So i add those lines myself, reupload wp-polls.php, and… it works again.
 * Hopefully this can be fixed soon 😉
    Great plugin 🙂
 * [http://wordpress.org/extend/plugins/wp-polls/](http://wordpress.org/extend/plugins/wp-polls/)

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Plugin Author [Lester Chan](https://wordpress.org/support/users/gamerz/)
 * (@gamerz)
 * [13 years, 10 months ago](https://wordpress.org/support/topic/problem-with-wp-pollsphp-error-500/#post-2901966)
 * [http://lesterchan.net/wordpress/2012/05/22/wp-polls-wp-postratings-wp-postviews-wp-email-updated/](http://lesterchan.net/wordpress/2012/05/22/wp-polls-wp-postratings-wp-postviews-wp-email-updated/)
 * [http://lesterchan.net/wordpress/2012/06/05/ajax-not-working-for-wp-email-wp-polls-wp-postratings-or-wp-postviews/](http://lesterchan.net/wordpress/2012/06/05/ajax-not-working-for-wp-email-wp-polls-wp-postratings-or-wp-postviews/)
 * 2 blog post that you might be interested in reading =)
 *  Thread Starter [Esteban](https://wordpress.org/support/users/tcattitude/)
 * (@tcattitude)
 * [13 years, 10 months ago](https://wordpress.org/support/topic/problem-with-wp-pollsphp-error-500/#post-2902020)
 * I was using 2.63… and still it was calling wp-polls.php instead admin-ajax.php.
 * And yes, i read those links before. Thanks.
 * None of those three problems was afecting us. Our plugin still was calling wp-
   polls.php. No “-1″ or “Failed To Verify Referrer”, no Password Protected /wp-
   admin/ and no HTTPS/HTTP also.
 * Odd.
 *  Plugin Author [Lester Chan](https://wordpress.org/support/users/gamerz/)
 * (@gamerz)
 * [13 years, 10 months ago](https://wordpress.org/support/topic/problem-with-wp-pollsphp-error-500/#post-2902038)
 * That is not possible, it must be some cache on your end. To be sure, redownload
   the plugin and overwrite it again. Try the default twentyeleven theme

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Problem with wp-polls.php, error 500’ is closed to new replies.

 * ![](https://ps.w.org/wp-polls/assets/icon.svg?rev=977996)
 * [WP-Polls](https://wordpress.org/plugins/wp-polls/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-polls/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-polls/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-polls/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-polls/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-polls/reviews/)

## Tags

 * [wp-polls.php](https://wordpress.org/support/topic-tag/wp-polls-php/)

 * 3 replies
 * 2 participants
 * Last reply from: [Lester Chan](https://wordpress.org/support/users/gamerz/)
 * Last activity: [13 years, 10 months ago](https://wordpress.org/support/topic/problem-with-wp-pollsphp-error-500/#post-2902038)
 * Status: not resolved