• migon

    (@migon)


    I made new hack on b2upload.php file because any hacks from this forum not working mutch well. Hack is based on old B2 upload hack and has lot of improvements.
    + No imagemagic (GD only)
    + Truecolor thumbnail image creation
    + Ratio image (thumbnail) resize. Images wider or higher than $MAX_SIZE will be resized
    + Script use low quality functions if high quality functions not supported
    + Small additions in stat part and litle thumbnail is shown on upload form page
    + openwin.js file added (JS to open new window thumb.php)
    + File thumb.php added. File show fullsize images as JS popup window.
    Window automatically resize to image size
    Download WordPress b2upload.php hack

Viewing 15 replies - 1 through 15 (of 26 total)
  • Anonymous

    “+ No imagemagic (GD only)”
    could you explain that to me? i’ve been wanting something like this but i want to make sure that it will work.

    NuclearMoose

    (@nuclearmoose)

    Migon,
    Do you have a URL where we could see a page created with the hack?
    Thanks.
    Craig.

    Thread Starter migon

    (@migon)

    >”+ No imagemagic (GD only)”
    >
    >could you explain that to me? i’ve been wanting something like this but i want to
    > make sure that it will work.
    Script use PHP functions for images, this functions is available only on hosting systems where is installed GD extension for PHP ( see phpinfo(); on your hosting ). This extension is standart part of PHP package. More at ww.php.net or search more information on google.
    BTW:Imagemagic is standalone tool for image manipulating and isn’t available everywhere
    ————–
    TO: NuclearMoose
    At this time unfortunately not, but in short time I start new blog and than you can see hack in action. But why do you don′t make some tests of this hack. Installation / uninstallation is very simple
    —-
    Sorry for my english ??

    Nimil

    (@nimil)

    thank you very much! (i finally registered!) now i know what the heck gd is and i figured out that i do infact have it ??

    Nimil

    (@nimil)

    there’s something wrong with your hack :/
    when i went to upload a picture i ended up with this after it uploaded:
    Warning: move_uploaded_file(/public_html/blog/junk/stripes5.jpg): failed to open stream: No such file or directory in /home/nimil/public_html/blog/wp-admin/b2upload.php on line 232
    Warning: move_uploaded_file(): Unable to move ‘/tmp/phpHA07HC’ to ‘/public_html/blog/junk/stripes5.jpg’ in /home/nimil/public_html/blog/wp-admin/b2upload.php on line 232
    Warning: copy(/public_html/blog/junk/stripes5.jpg): failed to open stream: No such file or directory in /home/nimil/public_html/blog/wp-admin/b2upload.php on line 235
    Couldn’t Upload Your File to /public_html/blog/junk/stripes5.jpg.
    i have no idea what the heck it’s talking about, and my uploads worked just fine until i installed this hack ??

    macewan

    (@macewan)

    really like the idea behind this. i’m working on incorporating a simple copy right message to be automaticly added to an image. using gd also.
    https://www.macewan.org/wordpress/index.php is a quick and dirty example – minus my work – of the above *.zip file. i created an image directory on under this working wordpress directory to store the images. also a edit is made the the thumbs.php file to reflect where the image is stored. (erased the ./data/ portion)

    mulinux

    (@mulinux)

    Migon,
    I’m using your hack. It’s great – but I had to make some changes to get it working. There were some hardcoded paths and some javascript issues. Most of the trouble was with thumb.php
    My website is hosted in a virtual host environment, so there are many restrictions regarding how I can browse the filesystem. I think most of my problems weren’t the fault of your hack, rather the original b2upload.php
    My site is simple, only for my personal use. You can check it out https://yunt.net
    Thanks for the hack.
    Sean

    mulinux

    (@mulinux)

    oh one more thing – the “move” feature which renames duplicate files is completely broken. ??
    I got the same issues as Nimil. If I get around to fixing this, I’ll post it here.

    macewan

    (@macewan)

    I’m going to use this hack (mod’d a little) for projects on sourceforge. Will add more options in the b2upload window. Like multi image upload, a button that takes you back to upload option once current image thumb is displayed. This will be useful for screenshots on projects.
    ??

    Thread Starter migon

    (@migon)

    oh ok and sorry for the bugs (and thanks foracknowledgements ?? ) I attempt to fix the bugs and make some changes and then I post a new version
    TO:Nimil
    I think, you have something wrong with realpath
    or the upload directory – do you have write permission for this directory set on your server?
    or you have very hard restrictions on your hosting server.
    —-
    Sorry for my english ??

    Nimil

    (@nimil)

    it might be the permissions, i’ll check, but as i said, i was able to upload to that directory before with no problem..so i dunno. but i will double check things.

    Thread Starter migon

    (@migon)

    Nimil test this:
    set your upload path to ../junk/
    and in thumb.php set path to ./junk/
    i work now on improvements please stay tuned ??

    Nimil

    (@nimil)

    still recieving the error.

    Thread Starter migon

    (@migon)

    Done, I made new version of my hack, check this linkShow me hack page. On page is few screenshots of this hack and link to download.
    To see hack in action see my blog at blog.openheads.org(in czech only)
    New freatures:
    + detailed information about upload environment for better debug
    + upload_path check (if dir exists / is dir writable?)
    and more
    for complete list of changes see the history file from zip archive

    icer5k

    (@icer5k)

    Here is the info I get with the environment debug:
    Upload environment
    Upload path: /homepages/42/d88930152/htdocs/ono/x/
    Directory is OK!
    Max w or h
    150 px (you might edit this on line 25 in b2upload.php file)
    File Types:
    GIF – GIF98 OK! – supported
    JPG – JPG OK! – supported
    PNG – PNG OK! – supported
    PHP environment:
    openbase_dir – Something is wrong
    EXIF – EXIF OK! – supported
    Quality – LowQuality only is supported
    GDlib – (empty)
    Any idea?

Viewing 15 replies - 1 through 15 (of 26 total)
  • The topic ‘image upload>thumbnail hack odher improvements’ is closed to new replies.