WordPress.org

Ready to get started?Download WordPress

Forums

Exhibit 1.0c Photo Gallery Plugin (88 posts)

  1. node
    Member
    Posted 9 years ago #

    After installing WordPress 1.2 and Exhibit 1.0c, everything seems to work fine, except that I get an error message in the Exhibit box on the edit page that says:
    Fatal error: Call to undefined function: add_action() in [my site root]/wp-content/plugins/exhibit10.php(227) : eval()'d code on line 1
    I've seen other people post this error, but no one's ever responded with a solution. Any ideas?

  2. welsper
    Member
    Posted 9 years ago #

    Gah! Just noticed a typo in the height/width code I posted earlier (http://wordpress.org/support/10/7599#post-24):
    >> Right before
    Should be "Right after"

  3. mufflonen
    Member
    Posted 9 years ago #

    I've been thinking about this chgrp thing. it'd be really useful if it could be set to the group "whatever my username is or something" and this could be set in the config file or something like that so it'd be easy for people to change the group.
    the thing is that I've done a search on chgrp and I see how to add this to the t-folder code sort of because I understand that part of the code. but I don't really know how to add it to the code where the user creates folders because I don't know enough php. :) like, if I am not getting this totally wrong, you have to define which folder to change the group of, and I don't know how to define that folder.
    there's also the problem that if I add a chgrp to the thumb-folder-code, I get "operation not permitted" (chgrp). is this because the t-folder is inside my imagefolder which have my username set as the group while exhibit seem to "belong" to group 99 (and user 99) and therefore cannot change group of files/folders inside my imagefolder.
    could that be fixed in some way? otherwise is umask the only solution that I can see :/

  4. symantix
    Member
    Posted 9 years ago #

    Is there any workaround to the wrapping issue in IE?

  5. ringmaster
    Member
    Posted 9 years ago #

    @node:
    This issue actually has been annotated before (maybe another thread?) and should be pretty easy to fix. In exhibit10.php, go to like 220:
    $ev = <<< EOC
    Change this to:
    $ev = "
    Change line 226 from:
    EOC;
    To:
    ";
    @SlitherImp:
    You need to change the float: setting in your exhibit.css file. Open exhibit.css and look for this line:
    /*float:right;*/
    Remove the comment marks so it does this:
    float:right;
    Feel free to change "right" to "left" if you like. The configuration settings for top and bottom will affect what text the image preview floats near. Just remember that the styles in the exhibit.css (or your main wordpress CSS file) also affect the images, making it easy to style your pictures to whatever CSS you use for the rest of your site.
    @mufflonen:
    I wish I knew what was going on on your box. I think there must be some odd permissions at work. It's conceivable that you have been denied access to the chgrp() command by your host.
    That chmod to 0664 doesn't work is really strange. I don't understand why you would need the execute bit set for an image file to be able to erase it.
    I'll just have to incorporate an unlink feature into the next release.
    FYI, the thumbnail folder is created on line 1474 in the make_thumbnails function.

  6. mufflonen
    Member
    Posted 9 years ago #

    yea, I know where the thumbnils are created in the php-file, it's more where chgrp should be added to the other subfolder-function that confuses me :)
    664 is not a problem, the problem was that the folders were created with 755 permissions...I could change that to 664 or whatever preferred with umask.
    I definitely think an unlink feature would be good. I miss deletion of files from inside exhibit now when I can upload them :D

  7. node
    Member
    Posted 9 years ago #

    @ringmaster:
    Thanks for your response. You're right, I had overlooked your earlier posting on the topic. However, I don't think that the "here document" (<<<) syntax is the problem in this case. I made the changes you suggested, and now I get a slightly different error message displayed in the same place as before:
    Fatal error: Call to undefined function: add_action() in [my site root]/wp-content/plugins/exhibit10.php(227) : eval()'d code on line 2

    I also tried using the "here document" syntax in another test PHP script on the same server (Dreamhost, which runs PHP4.3.4), and it worked fine. Any other ideas?

  8. Anonymous
    Unregistered
    Posted 9 years ago #

    hi,
    how can I disable the "onclick" function? Is there a way to display the picture in the same size I uploaded it. Without resizing..
    Thanks a lot
    dexter

  9. Anonymous
    Unregistered
    Posted 9 years ago #

    I like the upload interface provided with your plug-in, however i want to hide the main upload page. Is this possible. I don't want to provide two ways to upload images. I tried playing around with the upload levels but it did not work. Actually I think I discovered a bug in the process. When you specify minimum upload level in WP to 2 then you must have level 3 to upload using the Exhibit plug-in and level 2 for the normal WP upload page. Anyway, I would prefer a seperate upload level for Exhibit, is thios possible?

  10. ig0tch4
    Member
    Posted 9 years ago #

    the class "feedback" needs to clear the float:left from the gallery.
    .feedback { clear:left; } should solve your problem.

  11. SlitheryImp
    Member
    Posted 9 years ago #

    Thankyou very much RingMaster and igotch4, it's exactly as I want it now :D

  12. Anonymous
    Unregistered
    Posted 9 years ago #

    to get pictures to display in the same size that you uploaded it, this modification will effect the display of the preview (thumbnail) image...
    1. open up exhibit.css file and change:
    .ex_thumb_preview img {
    width:100%px;
    }
    2. open up exhibit10.cfg and change:
    thumb_width=640
    thumb_height=640
    you can edit thumb_width and thumb_height to be however large you want your maximum image resolution to be.
    if you want the actual original image (rather than the preview) to be displayed, here's what you can do... after you've added an image to your blog entry, double-click on the image thumbnail in the left-hand column of the exhibit section and it'll insert the html anchor and image tag into the entry body. sorta like this:
    <img src="http://www.domain.com/wp/images//t/IMG_8663.jpg" alt="" border="0" />
    in the img src code, remove the "/t" directory so the image will point to your original image and not the thumbnail.

  13. Anonymous
    Unregistered
    Posted 9 years ago #

    I have WP1.2 and Exhibit 1.0c.
    I changed the permissions in exhibit.cfg to be 0777.
    When trying to upload I get
    /uploads
    Fatal error: Call to undefined function: imagecreatefromjpeg() in /docs/cgi.media.mit.edu/emonic/eblog/wp-content/plugins/exhibit10.php on line 1489
    Also:
    - clicking "rebuild" does nothing.
    - clicking on any image icon (or its name) does nothing.
    - "t" folder has been created but nothing is inside.
    - files upload all right but then it is followed by the fatal error above.
    which (based on the comments above) is a sign that GD is not installed? My sysadmin however, assures me that GD is installed and is working.
    He says: "libgd is in /usr/local/lib."
    Is there a way to point the Exhibit to use this version? Or, to check whether GD really is installed properly?
    Thanks much...

  14. welsper
    Member
    Posted 9 years ago #

    phpinfo(); will tell you. Just create a file that has only:
    <?php phpinfo(); ?>

  15. Anonymous
    Unregistered
    Posted 9 years ago #

    I uploaded everything and changed all files as need be, but when I edit, it tells me I still need to chnage the name of the varibale from CHANGEME to something else. I did make the change but it's still telling me to change the name. I only made the edit in exhibit10.php. Did I forget it somewhere else?

  16. mufflonen
    Member
    Posted 9 years ago #

    uhm. I created a post with some exhibit-stuff, it looks great. but if I go back to edit the post once published, it won't let me remove pictures or change the caption...what's wrong?

  17. valiot
    Member
    Posted 9 years ago #

    I noticed that when I create sub-directories and upload images via the Exhibit interface, the uploaded files cannot be deleted. Even if I access the folders via an FTP program, I cannot delete the images. Is it because Exhibit puts special permissions on these folders?

  18. mufflonen
    Member
    Posted 9 years ago #

    valiot, this is because the owner of the files is not set to you and permissions are by default 755 or something like that which means you only get a "5" I've posted one solution above (see umask). to remove the folders you have now, you have to contact your host who has root access and can delete them.

  19. Anonymous
    Unregistered
    Posted 9 years ago #

    thanks Anonymous,
    another question. at the first posting site is displayed the small thumb gallery. at the comment site is displayed a thumb gallery which is a bit bigger. how can i disable this gallery or how can i show the small one from the posting site?
    what the way for the user to come from the comment site back to the posting site? there is no back button or something else.
    thanks a lot
    cheers
    frank

  20. andrew_h
    Member
    Posted 9 years ago #

    On the subject of deletion problems, this is caused by the folder and file having been uploaded or created by a php file the owner therefore being most likely 'nobody'. I am no expert with this but I think I can suggest solutions other than going to your host (who will not be impressed at being asked to delete files for you).
    First if you can find the first directory above the one you want to delete files in that belongs to you (as opposed to nobody), you chmod it 777 and keep going down until you reach the folder the file is in. You should then be able to delete the file. Then go back and reset all the folders back to what they were before.
    The second way is write a new php file (from another php file) that contains the code to do the delete.
    Andrew

  21. mufflonen
    Member
    Posted 9 years ago #

    andrew, I tried a couple of dats what you suggested about deleting but at least that didn't work for me. I had to ask my host about deleting those folders plus modify exhibit to give me enough permissions in the future

  22. ringmaster
    Member
    Posted 9 years ago #

    Regarding Exhibit release 1.1:
    This is not available just yet, but I thought I would give you an idea of what's been done already.
    Code had started to get a little unmanageable, so I split things into a few different files. For the new system to work, you upload one file into the plugin folder, and one folder of supplementary files into the plugin folder (the exhibitimg directory now contains some extra php files).
    I changed the implementation of the plugin hook so that you don't need to modify WordPress any more. Those who have already made this change should not see any apparent difference.
    1.1 includes file/directory deletion, limited to users with upload-level permissions.
    When you add single files to a post in 1.1, it just adds them and they appear in the thumbnail list. You need not re-save the post. I'm considering this feature for adding whole directories as well.
    You should be able to access all WP user info from within any Exhibit code in 1.1, which should allow you to create user directories for image uploads. I may yet write this feature in myself.
    You can change what items appear in the Exhibit editor dropdown in the config file, so you won't have extra options in the list for features that you have enabled by default.
    You can change the config file used for a single post with one Exhibit comment directive:
    < !--exhibit:config=some_file.cfg-->
    This will let you easily set a rack worth of config options all at once for just one post. Very handy. I may include a couple extra config files just so you can try it out.
    I fixed the bug regarding removing all preview images.
    I fixed the Exhibit stylesheet so that the thumbnail images no longer go under the sidebar in IE. (HA! Take that, blasted CSS/IE...)
    I have written an installation readme for all the confused folks.
    Now... If someone can iron out what needs to be done permission-wise (or will the delete feature obviate this?) with the creation stuff, I will gladly include it. But it's looking like some people are having a much harder time than others and there has been no definitive solution yet.

  23. WebSlog
    Member
    Posted 9 years ago #

    Different goofiness. The thumb displays just fine, but clicking on the thumb in the entry pops open a new window (as directed by the script) to display the photo. The caption at http://www.webslog.com displays just fine in the newly opened window, just no picture.
    Both images and t directories set to 775.
    Here's what I see when I open the activity window.
    http://www.webslog.com/images//site.jpg forbidden

  24. mufflonen
    Member
    Posted 9 years ago #

    sounds like the new version will be even more awesome
    1) my thoughts about the permission stuff:
    deletion from inside wordpress/exhibit could be enough, that depends on how much time you want to spend on the code of course. BUT I think it would be good if a user could not only set chmod for t-folders (like now, in the config file) but ALSO for other created subfolders with exibit. do you see what I mean, ringmaster? just wanna be sure we're understanding each other here :) because that chmod-stuff in the config file is working fine with the t-folders.
    2) my question about not being able to modify captions/previews when editing a post, is that fixed in the new version? you said something about a preview bug that's been fixed, is this what you meant?
    thank you so much for the plugin, you're doing a fantastic job here.

  25. elmsblog
    Member
    Posted 9 years ago #

    I don't think I have GD (is the right?) on my server. Can I still use this?

  26. valiot
    Member
    Posted 9 years ago #

    I can't wait for the new version!
    I still have the following main requests based on your latest update on the new features:
    1) It would be great to have subdirectories automatically created based on the author name.
    2) level 10 admin should have the ability (from within Exhibit) to delete other's directories and images. Of course author's can delete their own images and directories.
    3) Each Author should only "see" their own directory and cannot use other author's images or navigate into other's directories. They should live within their directory space. All these directories can be subs of the main image folder.
    4) Have the ability to default the preview checkboxes to always on. Configurable?
    5) I would like to seperate the level requirements for the default WP upload and the exhibit upload. Is it possible to have a level assigned in the config file for the minimum level required to upload images in exhibit?

  27. ringmaster
    Member
    Posted 9 years ago #

    For some reason, every time I try to post an response on this thread, the wordpress site goes dead. I'll try again:
    @WebSlog:
    It looks like you solved your problem. You should consider adding some CSS to remove the little link images from some of your links, though, like the Exhibit images and your calendar.
    @mufflonen:
    If it is the case that your whole permissions problem is predicated on the bug (missing funtionality) in Exhibit that does not set permissions on created directories, then you need to look for the mkdir function in the Exhibit source and add the lines after it that set the chmod permissions. They're missing. This is fixed in 1.1.
    @elmsblog:
    If you don't have GD, Exhibit can't make thumbnails for you. But it you make thumbnails for your images in a subdirectory named 't' with the same names as your original images, Exhibit will recognize them and use them. So, yes, you can use this, just with a little more work - work you would do anyway if you want thumbnails on your site.
    Are you using some other tool to make thumbnails? I have heard whispers of ImageMagick, but it's not as easy to implement in PHP as it seems.
    @valiot:
    Options 2 & 3 are complete in 1.1. Option 1 is in the works.
    Option 4 should be easy enough to do.
    Option 5 is a little more difficult, but makes sense for what you're tyring to accomplish (you don't want user uploading to the root image directory, but uploading to their assigned user directory is fine).

  28. WebSlog
    Member
    Posted 9 years ago #

    Thanks for the response ringmaster. Stupid me, the permissions on the image in question weren't set right. Dooh. Love the plugin, it's working great. Messing with the CSS to alter the link images. Spoecifically, the links in the calendar are throwing the layout off.

  29. waywardbob
    Member
    Posted 9 years ago #

    can anyone shed any light on my thumbnail problem? i have a directory with around 40 images. when i asked it to make thumbs it only made a dozen or so. tried again and it made a couple more. now it won't make any more - the file list on the right just goes blank, no errors in the server logs. i tried putting the remaining images in a new folder but it wouldn't make thumbs there either.
    i'm confused.
    bob

  30. mufflonen
    Member
    Posted 9 years ago #

    sounds good that's fixed in the new ver. , ringmaster. I am still wondering about editing the caption after the post has been saved...

Topic Closed

This topic has been closed to new replies.

About this Topic