Title: Error message in PHP
Last modified: August 22, 2016

---

# Error message in PHP

 *  Resolved [Thanatermesis](https://wordpress.org/support/users/thanatermesis/)
 * (@thanatermesis)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/error-message-in-php/)
 * I just found this error message in my php/nginx logs:
 * 2015/02/11 13:00:04 [error] 6165#0: *13 FastCGI sent in stderr: “PHP message:
   PHP Fatal error: Call to undefined method Yop_Poll_Model::get_poll_options_by_id()
   in /wp-content/plugins/yop-poll/inc/public-admin.php on line 34” while reading
   response header from upstream, client: 188.226.235.52, server: [http://www.elivecd.org](http://www.elivecd.org),
   request: “GET /wp-cron.php HTTP/1.1”, upstream: “fastcgi://127.0.0.1:9000”, host:“
   www.elivecd.org”
 * [https://wordpress.org/plugins/yop-poll/](https://wordpress.org/plugins/yop-poll/)

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

 *  Plugin Author [YOP](https://wordpress.org/support/users/yourownprogrammer/)
 * (@yourownprogrammer)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/error-message-in-php/#post-5775533)
 * Hello
 * Please let us know what version of YOP Poll you are running.
 * Best
    YOP Team
 *  Thread Starter [Thanatermesis](https://wordpress.org/support/users/thanatermesis/)
 * (@thanatermesis)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/error-message-in-php/#post-5775629)
 * Hello, last version, it doesn’t shows me that there’s an update
 * More exactly, version is: 5.6
 * Thank you,
    Thanatermesis
 *  Thread Starter [Thanatermesis](https://wordpress.org/support/users/thanatermesis/)
 * (@thanatermesis)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/error-message-in-php/#post-5775782)
 * In fact the function **“get_poll_options_by_id”** seems like to only exist on
   this place, there’s no code referencing it… maybe its some old API?
 * I think that this problem is triggered when the cron is fetched
 *  Plugin Author [YOP](https://wordpress.org/support/users/yourownprogrammer/)
 * (@yourownprogrammer)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/error-message-in-php/#post-5775802)
 * Hello
 * I have included a fix to this problem below.
    Also, it will be present in the
   next release.
 * Add the code below in models/yop_poll_model.php
 *     ```
       public static function get_poll_options_by_id( $poll_id = 0 ) {
   
                   $poll_options    = get_yop_poll_meta( $poll_id, 'options', true );
   
                   $default_options = get_option( 'yop_poll_options', false );
   
                   if( is_array( $default_options ) ) {
   
                       if( count( $default_options ) > 0 ) {
   
                           foreach( $default_options as $option_name => $option_value ) {
   
                               if( ! isset( $poll_options [$option_name] ) ) {
   
                                   $poll_options    [$option_name] = $option_value;
   
                               }
   
                           }
   
                       }
   
                   }
   
                   return $poll_options;
       }
       ```
   
 * after
 *     ```
       function get_bans_filter_search()
       {
       ...
       }
       ```
   
 * Best
    YOP Team
 *  [RockyMtnHi](https://wordpress.org/support/users/rockymtnhi/)
 * (@rockymtnhi)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/error-message-in-php/#post-5775836)
 * I am getting the same error that started on 5 Feb 2015 and my version is 5.6:
   [
   05-Feb-2015 01:00:07 UTC] PHP Fatal error: Call to undefined method Yop_Poll_Model::
   get_poll_options_by_id() in /home/wildblv0/public_html/wp-content/plugins/yop-
   poll/inc/public-admin.php on line 34
 * Has it been updated since 5.6?

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

The topic ‘Error message in PHP’ is closed to new replies.

 * ![](https://ps.w.org/yop-poll/assets/icon-256x256.png?rev=3524390)
 * [YOP Poll](https://wordpress.org/plugins/yop-poll/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/yop-poll/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/yop-poll/)
 * [Active Topics](https://wordpress.org/support/plugin/yop-poll/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/yop-poll/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/yop-poll/reviews/)

 * 5 replies
 * 3 participants
 * Last reply from: [RockyMtnHi](https://wordpress.org/support/users/rockymtnhi/)
 * Last activity: [11 years, 2 months ago](https://wordpress.org/support/topic/error-message-in-php/#post-5775836)
 * Status: resolved