Page 1 of 2

Photobucket fix

Posted: Sun Apr 01, 2018 12:27 am
by StephenSLR
I just noticed a thread here affected with Photobucket disease.

I'm not sure if it's been mentioned here before, I couldn't find it when I searched.

There is a workaround to get your pics back.

If you edit your old posts and add ~original to the end of the image file name it should display properly.

The last part of your image tag will look something like this:

my_image_file_name.jpg[/img]

change it to:

my_image_file_name.jpg~original[/img]

I tried it on one of my posts here and it works.

If you have a lot of pics in your post, click 'Modify' on your post,

CTRL+A to highlight all,

CTRL+C to copy it

then paste the content of your post into Notepad using CTRL+V

go to Edit > Replace > Replace All

and replace all the jpg's with jpg~original then you can copy/paste all that into your post and save.

;)

s

Re: Photobucket fix

Posted: Sun Apr 01, 2018 2:35 am
by hybrid
I can probably script something to change the whole database.

Re: Photobucket fix

Posted: Sun Apr 01, 2018 2:45 am
by Dwayne
That would be awesome.

Re: Photobucket fix

Posted: Sun Apr 01, 2018 2:45 am
by nassi
Thank you Stephen, it is working for most of the images. Very good find.
Thanks again.

Re: Photobucket fix

Posted: Sun Apr 01, 2018 2:13 am
by ozbilt
hybrid wrote:I can probably script something to change the whole database.
You are a good man hybrid, I don't care what they say about you .......

With over 8,000 pics on my bucket and over 10,000 posts, I was not looking forward to fixing them ....... :bingo:

Re: Photobucket fix

Posted: Sun Apr 01, 2018 2:29 am
by StephenSLR
hybrid wrote:I can probably script something to change the whole database.
Cool; although it'd probably change all my 'jpg~original's to 'jpg~original~original' lol.

Some of the photobucket links also have the suffix jpeg for some reason and it works if you change jpeg to jpeg~original

s

Re: Photobucket fix

Posted: Sun Apr 01, 2018 2:41 am
by scott66stang
Thats awesome as i have just spent about 8 hours finding my original pics on storage devices transfering to postimage and copy pasting to a couple of my build threads. i have done about 2% ?

Re: Photobucket fix

Posted: Sun Apr 01, 2018 3:18 am
by scott66stang
StephenSLR wrote:
hybrid wrote:I can probably script something to change the whole database.
Cool; although it'd probably change all my 'jpg~original's to 'jpg~original~original' lol.

Some of the photobucket links also have the suffix jpeg for some reason and it works if you change jpeg to jpeg~original

s
So yeah i just changed a load of posts in a matter of minutes, but i might just hold off to see if Hybrid can work his magic otherwise i will have to remove 1 ~original from the ones i have changed. ?

Re: Photobucket fix

Posted: Sun Apr 01, 2018 9:33 pm
by hybrid
StephenSLR wrote:
hybrid wrote:I can probably script something to change the whole database.
Cool; although it'd probably change all my 'jpg~original's to 'jpg~original~original' lol.

Some of the photobucket links also have the suffix jpeg for some reason and it works if you change jpeg to jpeg~original

s
Not if someone that knows what they are doing writes the script ?

Re: Photobucket fix

Posted: Sun Apr 01, 2018 9:43 pm
by Dwayne
That rules me out then.

Re: Photobucket fix

Posted: Mon Apr 02, 2018 4:45 am
by hybrid
Ok, I have made the change database wide.
Can you guys that still had photobucket links see if they are working now?

For the rest of the interwebs, this is how it was done.
- Backup database
- Export the posts_text table
- run the following over it:

Code: Select all

sed -ie -E ":a;s|(^.*\[IMG\]http:\/\/.*.photobucket.com\/albums\/.*)(.jpg)\[\/IMG\]|\1\2~original\[\/IMG\]|gi;ta" exportedtable.sql
- Check it
- truncate the table in the db
- import the file back into the db

Re: Photobucket fix

Posted: Mon Apr 02, 2018 4:48 am
by hybrid
By the way - once this "fix" filters around the interwebs, photobuckets traffic will start to increase again and they may shut this down.
I wouldn't expect it to last forever.

Re: Photobucket fix

Posted: Mon Apr 02, 2018 4:52 am
by scott66stang
Yep all fixed except a few reply posts from others with pictures attached, but they may have been deleted by other uses. Well Done :bingo:

Re: Photobucket fix

Posted: Mon Apr 02, 2018 4:53 am
by Dwayne
Awesome job, thanks.

I'm going to save some key pages offline, and save photos etc for future reference.

Re: Photobucket fix

Posted: Mon Apr 02, 2018 4:54 am
by scott66stang
Even the ones i have recently added the ~original too