• I have a new WP install. 62 different pages, a little blog distributed around based on category. I’ve installed the e-commerce plug-in, added a few products. Still testing…

    I keep everything in it up-to-date, checking for updates at least twice daily. I’m hosted on Dreamhost.

    I haven’t yet gone live with the site (it’s filled with Latin text right now) because there is a weird error I keep getting.

    Error #1:

    1. In the Dashboard, I click [Appearance] >> [Edit CSS]
    2. In the CSS window, I make a change, such as p {color:pink;}
    3. I click [Save Stylesheet]
    4. I receive an error message that reads:
    Fatal error: Call to undefined function get_current_screen() in /home/edwardmartiniii/testy.hellbendermedia.com/wp-content/plugins/wp-e-commerce/wpsc-admin/includes/product-functions.php on line 23
    5. So, I click the BACK button on my browser, and once again click [Appearance] >> [Edit CSS]
    6. My change is not present.
    7. So, I open the described file “product-functions.php”. Line #23 reads:
    $current_screen = get_current_screen();
    8. Meaning I can’t edit the CSS programmatically. I don’t know what this function is SUPPOSED to be doing, and I don’t know why editing the CSS calls a function in the e-commerce module anyway.
    9. Troubleshooting suggestions welcome! I could MANUALLY edit the CSS file and then upload it, but I’m afraid any changes I make will simply be lost in the next update.

    Thanks!

    Edward

Viewing 12 replies - 1 through 12 (of 12 total)
  • The function get_current_screen() is included since WP 3.1, are you using old WP version?

    http://codex.wordpress.org/Function_Reference/get_current_screen

    Thread Starter EdwardMartinIII

    (@edwardmartiniii)

    Sorry — I forgot to add that bit.

    I’m using WordPress 3.5.1.

    I check for updates to WP and to all plug-ins roughly twice a day.

    Can’t find any clues then, probably only the

    wp-e-commerce

    developer can help you.

    Thread Starter EdwardMartinIII

    (@edwardmartiniii)

    Dang! That got me thinking.

    I deactivated the e-commerce plug-in and tried to edit the CSS. Worked great.

    Reactivated the e-commerce plug-in.

    Tried again. Fail condition.

    So this much I know — the problem is probably in the e-commerce module (or at least manifests there).

    I CAN change my CSS, but I have to temporarily bring the e-commerce plug-in down.

    It’s hacky, but I’m back in business at least.

    As long as it works, it’s a perfect solution 🙂

    Same issue here. Would you advise using a different e-commerce plugin? If so, which one?

    Thread Starter EdwardMartinIII

    (@edwardmartiniii)

    “Same issue here. Would you advise using a different e-commerce plugin? If so, which one?”

    I got tired of the hack.

    I dumped e-commerce and instead installed MarketPress and bought a subscription to the company’s support system. I regret NOTHING!

    I now use several of their plug-ins. Three thumbs up!

    Thank you very, very much!

    Thread Starter EdwardMartinIII

    (@edwardmartiniii)

    Please let me know if that ends up helping! 8)

    1. Open “wp-content/plugins/wp-e-commerce/wpsc-admin/admin.php”
    2. After Line #26: Add “require_once(ABSPATH . ‘wp-admin/includes/screen.php’);”
    3. Save your changes… and see if bug still exists.

    Hello,

    1. Open “wp-content/plugins/wp-e-commerce/wpsc-admin/admin.php”
    2. After Line #26: Add “require_once(ABSPATH . ‘wp-admin/includes/screen.php’);”
    3. Save your changes… and see if bug still exists.

    Good luck.:)

    Hello @rikboy
    I wanted to thank you for the help. You fixed the issue I had with the wordpress website I am working on right now.
    Again thanks a lot!

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘Fatal error: Call to undefined function get_current_screen()’ is closed to new replies.