Frontend Uploader requires at least 3.3. get_current_screen() was introduced in 3.1. So it seems like you’re running pretty old version of WordPress. Keeping your installation updates is general best practice.
Very strange. This only happened today on updating WP to 3.6. So I tried disabling all other plugins and trying it again and it worked! I had been using:
[fu-upload-form form_layout="post_image" post_type="board"] [textarea name="post_title" class="textarea" id="ug_title" description="Title"] [textarea name="post_content" class="textarea" class="required" id="ug_caption" description="Description"] [input type="file" name="photo" id="ug_photo" description="Your Photo" multiple=""] [input type="submit" class="btn" value="Submit"][/fu-upload-form]
Now that seems totally incorrect. Going back to your example it seems I need:
[fu-upload-form title="Submit a new post" category="board"] [input type="text" name="post_title" id="title" class="required" description="Title" multiple=""] [textarea name="post_content" class="textarea" id="ug_caption" description="Description (optional)"] [input type="file" name="photo" id="ug_photo" description="Your Photos" multiple=""] [input type="submit" class="btn" value="Submit"] [/fu-upload-form]
I didn’t know whether to use post_type or category and where so hopefully I got it right by guessing. You can see at http://akpetcremations.com/grief-and-comfort-board/ that the form has multiple fields of the same type that I was unable to disable in the settings menu.
Just leave it as:
[fu-upload-form form_layout=”post_image” post_type=”board”]
Let me know it worked. I changed the way how the default form is rendered. In the hindsight, I needed to do it a bit different.
Works perfectly and looks great. I just tested a title only with photo upload and title+description+photo. I do like your default form MUCH more now and I am happy enough without customizing. 😛
karenfya, could you provide the list of plugins that you were using when you had that error? trying to reproduce the issue.
I have no idea how I managed to get the error I did after you explained it.
Here’s what happened exactly:
Updated Akismet, AVH First Defense Against Spam, Block Bad Queries (BBQ), Frontend Uploader, ManageWP – Worker, NextGEN Gallery, WordPress Related Posts plugins. Frontend Uploader crashed so deleted, updated WP, reinstalled Frontend Uploader experienced error again and reported it. Later brought NextGEN Gallery back to previous version due to errors (broken for everyone with current version of WP).
Here are the plugins even though I was able to re-enable all of them:
All In One SEO Pack
AVH First Defense Against Spam Plugin
Block Bad Queries (BBQ)
ManageWP – Worker
Photoswipe for NextGEN Gallery
WordPress Related Posts
Ack! Error recreated!! Stupid 2.0~ NextGEN Gallery!
Downloading update from http://downloads.wordpress.org/plugin/nextgen-gallery.zip…
Unpacking the update…
Installing the latest version…
Removing the old version of the plugin…
Plugin updated successfully.
Fatal error: Call to undefined function get_current_screen() in /home/content/38/7902638/html/pcsite/wp-content/plugins/frontend-uploader/frontend-uploader.php on line 191
Alright, thanks! I’ll look into it and make sure this error won’t happen in future versions.
I fixed it. I’ll release new version on Monday, cause I don’t want to deal with angry users on a weekend 🙂 Thanks again, your reports were very helpful!
🙂 Thank you very much! Bravo on your prompt support! Thanks for being a diamond in the rough of plugin developers! (( If you lived here, I’d buy you a coffee. 😛 ))
- The topic ‘[Resolved] Broken’ is closed to new replies.