why I get this error on line 109?

Discussion in 'PHP' started by duckeldanny, Apr 26, 2010.

  1. #1
    Hello, I have a problem with a wordpress plugin. Its a store plugin for wordpress with buddypress.
    It calls CubePoints Store.
    Everytime I buy something on my blog with this plugin I get this error:

    Fatal error: Call to undefined function is_user_logged_in() in /mnt/web2/42/82/52112482/htdocs/my-blog/wp-content/plugins/cp_store/cp_store.php on line 109

    in line 109 in cp_store.php is this:
    if (!is_user_logged_in()) { cps_die('Error! Please login to purchase items!');}

    I tried to login with other user accounts but, it doesnt work.
    Anyone have a idea to solve this problem.
    Thanks
     
    duckeldanny, Apr 26, 2010 IP
  2. Kaimi

    Kaimi Peon

    Messages:
    60
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Try to add
    
    require_once ('/mnt/web2/42/82/52112482/htdocs/my-blog/wp-includes/pluggable.php');
    
    PHP:
    at the beginning of cp_store.php
     
    Kaimi, Apr 26, 2010 IP
  3. duckeldanny

    duckeldanny Peon

    Messages:
    20
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    wow, it works. Thank you very very much.
     
    duckeldanny, Apr 26, 2010 IP