• Resolved LuluTamiko

    (@lulutamiko)


    I have the box “Uploads Require Approval” checked so that uploaded images will be excluded from the gallery until approved … but it doesn’t seem to be working when an image is uploaded without any text entered in the “Image Description” field. The images are appearing immediately in the gallery without approval. However, if the user does type something into the description field at the time of uploading, then the images are excluded until approved.

    NextGEN Public Uploader 1.8.2
    NextGEN Gallery 2.0.76

    https://www.ads-software.com/plugins/nextgen-public-uploader/

Viewing 15 replies - 1 through 15 (of 15 total)
  • I been try to “go around” problem as well, waiting for a solution ??

    Version 2.0.77 (Gallery)
    Version 1.1.3 (Plus)
    Version 1.8.2 (uploader)

    problem solved for me.

    [ngg_uploader] is not working, you have to use [ngg_uploader id=1]
    Got it to work with this.

    TyroneFroberg I tried this but nothing new… the image still goes instantly to the gallery =/

    Same problem here. It was working just fine until the update.

    Hi,
    I tried [ngg_uploader id=1] too and the images aren’t excluded. I use NextGen Gallery pro.

    Hi all, I ended up writing my own uploader and just do an INSERT into ngg table.

    I’m having this same problem and definitely don’t have enough WP/PHP background to make a custom uploader as @edytajordan did.

    Any word from the plugin developers? Pretty critical feature here to have an approval queue when allowing the public to upload.

    Rob

    (@gravelrash)

    Same issue here

    Hallo.
    I have struggled with the same problem and came up with a simple workaround.
    I added a “required” attribute to the description-input.

    In the npu-upload.php, on Line 160:
    $strOutput .= "\n\t<input type=\"text\" name=\"" . esc_attr( $name ) . "\" id=\"" . esc_attr( $name ) . "\"/>";
    ADD a “required” to this input field so it looks like this –>
    $strOutput .= "\n\t<input type=\"text\" name=\"" . esc_attr( $name ) . "\" id=\"" . esc_attr( $name ) . "\"required/>";

    Like this users can only upload a file when they filled in the description field. When the description field is empty and the user clicks on the submit button, he will get the message to fill in the description field. This way all uploaded images are excluded.

    When you update the plugin you will hav to redo this change though. Hope this helps some of you. : )

    I have tried your solution ink_zip, but its still not working for me … ?? I edited line 160 as you suggested but i can still upload files without description with the latest version of Firefox. WordPress, NGG and NGG Public uplaoder are all up to date with this test btw.

    It’s a pretty bad bug, i do really hope somebody knows a solid fix ??

    It might be becuase of the different settings you have set in the public uploader plugin, because for me it works with Firefox too.

    Try adding on LINE 366 as well a “required” to the input element.

    $output .= '<input type="text" name="imagedescription" id="imagedescription"/>';
    Cange to ->
    $output .= '<input type="text" name="imagedescription" id="imagedescription" required/>';

    Let me know if that worked. If not, tell me about your Public Uploader settings.

    Thnx ink_zip, i now get a message on screen when the description is empty, which the correct way to deal with the problem.

    In the npu-upload.php, on Line 160:

    $strOutput .= "\n\t<input type=\"text\" name=\"" . esc_attr( $name ) . "\" id=\"" . esc_attr( $name ) . "\"/>";
    ADD a "required" to this input field so it looks like this -->
    $strOutput .= "\n\t<input type=\"text\" name=\"" . esc_attr( $name ) . "\" id=\"" . esc_attr( $name ) . "\"required/>";

    AND

    Try adding on LINE 366 as well a “required” to the input element.

    $output .= '<input type="text" name="imagedescription" id="imagedescription"/>';
    Cange to ->
    $output .= '<input type="text" name="imagedescription" id="imagedescription" required/>';

    Solves the problem for now ??
    Thnx mate!

    I am glad it worked for you too. It isn’t really an all proof solution though. IE9 and lower do not support the required tag. Neither does Safari.

    You can create Javascript fallbacks for this. Here is a Link (first result when googling for it) that explains it well:
    https://www.csskarma.com/blog/required-input-fallback/

    And after all this still is only clientside validation.

    Of course, rather than plying with code you could simply create an “upload gallery” that is not published. NextGen makes it easy to transfer images from one gallery to another. Just as quick as approving each image upload.

    Hi All,

    Here is a simple step to fix this issue as-per “ink_zip” suggested point description should fill something….

    In the npu-upload.php, on Line 245:

    return;

    here just pass a null value to $arrUpdateFields[], so it will be like this

    $arrUpdateFields[] = “description = ‘ ‘”;

    ofcourse this null value never show/store in DB or anywhere but our problem will solve ??

    By this way dont need to force users to fill description, also may be some of them dont like to use description field for photos, Also another BIG thing is that description field’s “required” argument not much secure to restrict photo approval because anyone can break this restriction by browser inspect tools and delete argument etc…

    I think it will help better!

    Thanks All!

Viewing 15 replies - 1 through 15 (of 15 total)
  • The topic ‘Images not being excluded until approved’ is closed to new replies.