Site Links
Home
Features
Documentation
Pricing & Order
Members Area
Support Options
UBBDev.com
UBBWiki.com
Who's Online Now
2 registered members (Ruben, M4TT), 65 guests, and 378 spiders.
Key: Admin, Global Mod, Mod
Member Spotlight
Posts: 25
Joined: November 2012
Show All Member Profiles 
Top Posters(30 Days)
Gizmo 14
FREAK 11
M4TT 9
mmkk 5
Ruben 4
isaac 4
Latest Photos
Chinese Buddhist temple.
My buddha beads.
Rendered Walls
Multi-Screen wallpaper
Stockholm Metro
Previous Thread
Next Thread
Print Thread
upload photo or not for everyone #260278
07/09/17 06:14 AM
07/09/17 06:14 AM
Joined: Jun 2006
Posts: 518
Sweden
Morgan Offline OP
addict
Morgan  Offline OP
addict
Joined: Jun 2006
Posts: 518
Sweden
Hi
there has been discussions about Photobucket starts to charge money and a lot of our member has now problems with old links to photos.
one member sent me this message and a per script.
do you think it could be used. I havenot included the scrip here.

What do you suggest?
Should I allow anybody to opload photos to out forum, right now its premium members that pay a fee. I'm not sure that allowing everyone is a good ideas cause it will be so many photos over time but I'm open for suggestions.

Thanks


Quote
Hello Morgan,

Here’s the script - photobuckoff.pl

It’s written to work with files, so would not immediately useful for Britbike, which I think holds posts in a database.
If you can tell me what database you’re using and the table structure, I should be able to give you an updated version which will work for Britbike as well.

This could come in handy as people move images to another image hosting site. Get them to give you the old URL and new URL for the images, Then run the script to update the links in their posts.

Anyway, it will work best on a Unix-based system such as Linux or OS X, but there are versions of Perl available for Windows.
You will also need the Getopt::Long Perl module installed

There are 4 ways to run it

1/ specify the input & output files, and the old and new URLs
perl photobuckoff.pl -s <source file> -d <destination file> -o <old URL> -n <new URL>

2/ specify the input & output files, and a file with an old and new URL on each line
perl photobuckoff.pl -s <source file> -d <destination file> -f <file containing URLs>

3/ specify the input & output directories, and the old and new URLs
perl photobuckoff.pl -s <source directory> -d <destination directory> -o <old URL> -n <new URL>

4/ specify the input & output directories, and a file with an old and new URL on each line
perl photobuckoff.pl -s <source directory> -d <destination directory> -f <file containing URLs>

where:
<source file> is the file you want to fix
<destination file> is the file which will will have the updates applied (avoid overwriting your original)
<old URL> is the URL you want to replace
<new URL> is the URL you want to replace it with
<file containing URLs> is a file with a pair of URLs on each line. The first is the one you want replaced, the second is what will replace it

The script will replace every occurrence of the old string with the new string.

If you specify directories, it will work on every file in the directory, and all the subdirectories.

If you have a file with pairs of URLs, these will be sorted by length and alphabetically. It runs through each old URL for each line, which can be a bit of a trap if one of the shorter URLs is a subset of one of the longer replacements - you can wind up with some odd looking results.


An example would be:
perl photobuckoff.pl -s tom.html -d harry.html -o http://photobucket.com/users/shane -n http://britbike.com/home/shane


Morgan Johansson
BritBike Forum
http://www.britbike.com/forums/ubbthreads.php?
Express Hosting
Express Hosting "We are the official hosting company of UBB.threads. Ask us about our free migration services to migrate your UBB.threads installation."
Re: upload photo or not for everyone [Re: Morgan] #260279
07/09/17 06:46 AM
07/09/17 06:46 AM
Joined: Apr 2004
Posts: 1,004
California
isaac Offline
UBB.threads Developer
isaac  Offline
UBB.threads Developer
Joined: Apr 2004
Posts: 1,004
California
The image processing for UBB.threads has been considerably updated since version 7.6.0 (which you're currently running).
https://www.ubbcentral.com/forums/ub...hreads-7-6-1-not-yet-released#Post259969

It can take and process a standard sized (example: 12MP-16MP) smartphone photo and reduce the dimensions and file sizes for you on the fly.

[Linked Image]

The result will be an attached post image which uses much less storage on your server, and "costs less" to transfer for each page view.

I would highly recommend that you stay away from photobucket for a few simple reasons:
1) uploads to photo bucket mean that you never have control over the photobucket-linked-content your users post. And it could go away whenever photobucket chooses, creating incomplete posts and broken links.
2) if you ever decide to jump on the HTTPS bandwagon which most of today's internet is headed towards, be warned that photbucket still doesnt support https, and you are linking to a 3rd party for your content (see also #1). a future UBB.threads 7.6.x feature which is being worked on, will be to check if your main domain is on https, and then only allowing inlined images from your own website, and others who are also https -- meaning that photobucket's insecure http urls will not be displayed as images, but only as a url link to the image. This is intended to preserve the https validation of your pages.
3) users leave your site to create and account (and upload, manage...etc) at photobucket. a user can also violate the terms of photobucket and have all their account photos deleted, thus removing valuable content from being used on your site. a user can also choose to have their photobucket account deleted, with the same results. if a users requests that your delete their account from your UBB.threads forum, you can remove their account, but keep all the content that was created, and label the user as "Anonymous."
4) photobucket is not mobile friendly. if you have users with android or iphones, they may just ignore trying to attach any images at all. (see also #3)
5) if you do choose to manually manicure/curate your attachment folder for NSFW/unrelated forum attachments, you absolutely wont be seeing any of the linked items linked from photo bucket.
6) Perl/CGI scripts... A quick google search returns many results. These were within those results: (A), (B).

The attached image processing code for UBB.threads 7.6.1 is basically written and done already. The Control Panel page settings for this new code are being written with as much time as I can put in to it -- June was an awful month for my productivity due to picking up a new 6 week puppy at the beginning of it. She's getting better and sleeping for longer periods of time now, so I've been able to jump back in to some UBBT programming over the last week. (translation: im looking forward to getting this new code finished up, and in to everyone's hands as soon as I can. I've been looking forward to it since May).

Last edited by isaac; 07/09/17 07:12 AM. Reason: added some links, screenshot, clarity and... more info.
Re: upload photo or not for everyone [Re: Morgan] #260280
07/09/17 07:11 AM
07/09/17 07:11 AM
Joined: Jun 2006
Posts: 518
Sweden
Morgan Offline OP
addict
Morgan  Offline OP
addict
Joined: Jun 2006
Posts: 518
Sweden
Thanks for your answer isaac,

I guess thousands of photos will dissapere from the forum due to broken photobucket links in the future.
Best would perhaps be to allow photo uploads to my server then.
I look forward to 7.6.1 to see how much it will help when it arrives.
Good luck with your puppy and with the programming.


Morgan Johansson
BritBike Forum
http://www.britbike.com/forums/ubbthreads.php?

Shout Box
Today's Birthdays
No Birthdays
Recent Topics
Shout Box Sound Effect
by M4TT. 11/29/17 08:28 PM
Ad island
by TGCsanderson. 11/25/17 06:41 PM
Taking to long to connect to DB
by AstroCat. 11/24/17 12:34 PM
I want to update forum but can't find license
by dimaninc. 11/23/17 10:51 AM
Forum Statistics
Forums36
Topics35,014
Posts190,530
Members12,045
Most Online978
Jun 24th, 2007
Random Image
Powered by UBB.threads™ PHP Forum Software 7.6.1
(Snapshot build 20171106)