php forum
php mysql forum
php mysql smarty
 
Topic Options
#130475 - 02/06/01 04:14 AM [6.0x] Userimage-Utilization in Post V 1.0
eurosale Offline
Junior Member

Registered: 02/06/01
Posts: 2

   [6.0x] Userimage-Utilization in Post V 1.0 to Del.icio.us Add to del.icio.us
  Digg [6.0x] Userimage-Utilization in Post V 1.0 Digg it
Hi folks,

this simple hack utilizes the standard userimage-Field in UBB6 and shows the image below name and status in the posting.

Demo

eurosale

Top
#130476 - 02/06/01 05:26 AM Re: [6.0x] Userimage-Utilization in Post V 1.0
Marki Offline
Junior Member

Registered: 03/16/00
Posts: 19
Ich sehe, Du hast ein deutsches Board, daher meine Antwort auf Deutsch:

Kann ich die Größe des verlinkten Bildes auch begrenzen? Es macht keinen Sinn ein Userbild in den Beiträgen anzubieten, wenn einzelne Bilder 100kb oder grösser sind... wink

For all others, is there a way to limit the datasize of the picture to let's say < 10 kb?
_________________________
Greetz Alex
Spasschat.de-Team

Top
#130477 - 02/06/01 05:57 AM Re: [6.0x] Userimage-Utilization in Post V 1.0
eurosale Offline
Junior Member

Registered: 02/06/01
Posts: 2
There is no limitation of filesize included in the hack yet.

I'm running that hack also on 5.47 for a time, never had problems with users linking oversized pictures.

You should alter the text in the profile for using the image (e.g. size, proportions 60x60).

eurosale

Top
#130478 - 02/07/01 08:30 PM Re: [6.0x] Userimage-Utilization in Post V 1.0
speed Offline
Code Monkey

Registered: 11/27/00
Posts: 685
Loc: Ft. Myers Fl.
What is the difference between this hack and the 6.0 avatar hack. Other than changing the text in two files instead of one
_________________________

Just a thought

SPEED

Top
#130479 - 02/10/01 01:23 PM Re: [6.0x] Userimage-Utilization in Post V 1.0
Gr33n Offline
Junior Member

Registered: 02/09/01
Posts: 12
Quote:
quote:


Exaclty how do you edit the text on the profile page? Which file do I have to alter?

ThanX!

Gr33n

Top
#130480 - 02/10/01 03:54 PM Re: [6.0x] Userimage-Utilization in Post V 1.0
Lupus Offline
Member

Registered: 02/28/00
Posts: 59
looking at the code, I don't see any added functionality from the other avatar hack. If you want to make a change, my recomendation would be to change the profile field to one of the custom fields (that is what I did when I installed it on my board).

Top
#130481 - 02/11/01 02:52 PM Re: [6.0x] Userimage-Utilization in Post V 1.0
Gr33n Offline
Junior Member

Registered: 02/09/01
Posts: 12
Yes, but how? WHat files do we alter and how?

TheGr33n1

Top
#130482 - 02/11/01 06:53 PM Re: [6.0x] Userimage-Utilization in Post V 1.0
Lupus Offline
Member

Registered: 02/28/00
Posts: 59
http://www.h-realms.com/hacks/6.x/avatar6.txt
public_topic_page.pl

That is the original hack (MM posted it a while ago)

where he said:
my $this_img = $user_profile[20];
chomp($this_img);


I did this:
my $this_img = $user_profile[18];
chomp($this_img);


The 18 is the second to last custom slot. I then went into the control panel, and made it so the second to last slot said "User images." This did not require any hacking...it is a built in option of this version of UBB.

If you want to change the image size,
find where MM says this:

if ($this_img ne "") {
$this_img = qq(
<img width=64 height=64 src="$this_img" border=0> );
} else {
$this_img = "";
}


and change the numbers after width and height.

Top
#130483 - 02/11/01 08:17 PM Re: [6.0x] Userimage-Utilization in Post V 1.0
Markee Dragon Offline
Junior Member

Registered: 09/10/00
Posts: 27
Loc: Portland Oregon
What about taking this a step further and put in the ability to limit the size of the pic to be shown. I'd like to use it in our forums but I few people who would put in pics that are a megabyte or so. All of my dialup users would complain.

Someone think they can add in some code to set the max image size?
_________________________

www.ShatteredCrystal.com
Where Virtual meets Reality
markeedragon@shatteredcrystal.com

Top
#130484 - 02/12/01 02:17 AM Re: [6.0x] Userimage-Utilization in Post V 1.0
Gr33n Offline
Junior Member

Registered: 02/09/01
Posts: 12
I saw on another board where on the profile he had a 'picture' field AND an 'Avatar' field. Now how would I accomplish that? ANd how do I put links in the text next to the profile fields? (I wanna make a link to a page of available avatars).

ThanX. TheGr33n1

Top
#130485 - 02/13/01 01:35 PM Re: [6.0x] Userimage-Utilization in Post V 1.0
V'Pier Offline
Junior Member

Registered: 01/16/00
Posts: 8
I really hope someone can whip up a pulldown avatar list instead of this. The one I remember was set up to read from an avatar directory that is full of images you put in there, then they just click the drop down list, pick the image they want and a little java script makes the image pop on beside the drop down list.

I know nothing of cgi scripting frown but it would be nice if someone were to bring that ol' 5.x script into the 6.x world smile

Oh well, it's too early, but we'll all look foward to seeing that script one day smile
_________________________
V'Pier

Top
#130486 - 02/13/01 05:33 PM Re: [6.0x] Userimage-Utilization in Post V 1.0
Lupus Offline
Member

Registered: 02/28/00
Posts: 59
Gr33n,
If you want to have both a avatar field and a picture field, just follow the instructions I gave in response to your last question in this thread. It will not be a drop down box, it will be a slot for people to enter the addy of the image.

No, I don't know a way to limit the file size (in MB) but if you set the diminsions of the image at a reasonably small size, you should not have problems with download times.

Top
#130487 - 02/14/01 11:49 AM Re: [6.0x] Userimage-Utilization in Post V 1.0
Flare Offline
Junior Member

Registered: 01/13/00
Posts: 24
Loc: Kansas
Giving the IMG tag a size will NOT reduce download time. All it does is download the huge 1MB file and then rescale it.

IMHO, and it's always been of my opinion that the Avatar hack and/or this particular feature is EXTREMELY short sighted. Why do people insist on giving the users power to bring a dialup connection or even an ISDN connection to it's knees with huge image files? That's exactly what happens when you give the user the ability to specify ANY URL they want for their little icon.

All my users icons are ones they have uploaded to my server (eliminating the speed problems from connecting to 50 billion different servers), then converted to the proper dimentions, THEN that file is sent to the user who views the message.

The above is the ONLY secure way to handle user icons, any other way and you are just BEGGING for trouble. I really don't see why people keep persisting with the Avatar hack or why on earth Infopop made the ability to specify a URL as a user image.

Anyway, just my 2c worth.
_________________________
A crust of bread is better than nothing. Nothing is better than love.
Therefore, by the transitive property, a crust of bread is better than love.

Top
#130488 - 02/14/01 04:44 PM Re: [6.0x] Userimage-Utilization in Post V 1.0
DPK.ducky.quack Offline
Developer

Registered: 11/18/00
Posts: 874
get the Image Magick module....
http://www.simplesystems.org/ImageMagick/
_________________________

Top
#130489 - 02/16/01 02:19 AM Re: [6.0x] Userimage-Utilization in Post V 1.0
hate98 Offline
Member

Registered: 01/05/01
Posts: 280
Flare is 100% right.

However, if I was gonna create a hack, I'd probably approach is this way...

Code:
code:


Above is some simple perl that checks the gif image height/width attributes.

Step 1: create an upload page so users can send a .gif file to your server (many applet, javascript wares out there for this). put your policies about filesize and type there, plus this could be linked from the profile screen in UBB and could allow image deleting/addition - user controlled.

Step 2: check image attribute, sh!tcan the image if too big (you decide what is too big)

Step 3: rename the file to include the member profile number in the filename, i.e. 0000002.gif

Step 4: hack UBB to use SSI call to a perl script to check if image exists, and if it's there display the image

this is real quick off the top of my head stuff... but in a nutshell it allows user to upload, you can warn them about filesizes and take action, and image will NOT display unless it exists, and it's all on your server. two hacks - one in profile, one in forums display source, and one external script or HTML file that handles uploading and deleting and policies.

hey, i'm busy with my own stuff, no time for this! but maybe i sparked some folks into saying "hmmmmm....." ;-)

-jim

[ February 16, 2001: Message edited by: hate98 ]

Top
#130490 - 02/28/01 05:56 PM Re: [6.0x] Userimage-Utilization in Post V 1.0
J.C. Offline
Addict

Registered: 08/11/00
Posts: 1551
Another prob is, if you have none enetered you see a missing image (using IE 5.0)

frown
_________________________
- Groupee Moderator
- Custom Web Development
http://www.JCSWebDev.com

Top


Top Posters Last 30 Days
AllenAyres 12
Gizmo 10
S7ARBVCK 2
blaaskaak 2
Cambridge 1
Murphdog 1
MattUK 1
Who's Online
0 Registered (), 30 Guests and 8 Spiders online.
Key: Admin, Global Mod, Mod
Shout Box

Latest Posts
[7.3.1] add search to showmembers page
by blaaskaak
Today at 04:50 AM
BeyondCompare v3.00
by blaaskaak
09/05/08 02:46 PM
Noob - need help, or a reality check!
by Gizmo
09/04/08 03:21 AM
Here I am! Rock me like a Hurricane!
by AllenAyres
09/02/08 03:05 PM
[7.x] Generic Page Outside of forum directory
by Gizmo
08/30/08 05:43 PM
Team UBBDev Rides Again!
by Gizmo
08/28/08 11:45 PM
Multiple Identity Detector
by MattUK
08/28/08 04:10 PM
New Mods
[7.3.1] add search to showmembers page
by blaaskaak
Today at 04:50 AM
Installing FlashChat with 7.3
by Paug
08/23/08 12:14 AM
[7.3.x] ubb.links
by AllenAyres
06/20/08 11:50 PM
[7.2.1] - Naked shoutbox
by sirdude
08/17/07 10:36 PM
[7.x] Generic Page Outside of forum directory
by
01/14/07 10:58 PM
Newest Members
veedubb8, twentyseven, Claus1, welcomeback1, Paug
13327 Registered Users

 

 

 
fusionbb message board php hacks