Previous Thread
Next Thread
Print Thread
Rate Thread
#53831 06/23/2002 4:35 PM
Joined: Mar 2001
Posts: 80
Member
Member
Offline
Joined: Mar 2001
Posts: 80
Hi,

one of my users has requested that the border be set to zero when using a [IMG] in a .

Could someone please point me in the right direction of inserting the border="0" statement into the output.

Many thanks in advance

Paul

Sponsored Links
#53832 06/23/2002 5:25 PM
Joined: Sep 2001
Posts: 379
Member
Member
Offline
Joined: Sep 2001
Posts: 379
Open ubb_lib.cgi and find:
Code
[/code]Replace with:
[code]

#53833 06/23/2002 8:31 PM
Joined: Mar 2001
Posts: 80
Member
Member
Offline
Joined: Mar 2001
Posts: 80
Thanks Idle,

Works a treat.

Paul

#53834 06/23/2002 10:18 PM
Joined: Sep 2001
Posts: 379
Member
Member
Offline
Joined: Sep 2001
Posts: 379
No problem. smile

#53835 11/11/2004 8:56 AM
Joined: Nov 2004
Posts: 2
Junior Member
Junior Member
Offline
Joined: Nov 2004
Posts: 2
Well i have another [img] question.. I would like to have a customizable border around my picture, for example [img border=dashed 1px red]. Could someone point me to the places where i have to change the code to make this possible.

thanx in advance..

Sponsored Links
#53836 11/11/2004 2:26 PM
Joined: Jan 2000
Posts: 5,073
Admin Emeritus
Admin Emeritus
Joined: Jan 2000
Posts: 5,073
That is exceedingly dangerous without creating lots of validation code - allowing users to play directly with CSS can lead to unexpected results...


UBB.classic: Love it or hate it, it was mine.
#53837 11/11/2004 2:41 PM
Joined: Jan 2003
Posts: 3,456
Likes: 2
Master Hacker
Master Hacker
Offline
Joined: Jan 2003
Posts: 3,456
Likes: 2
Code
$code =~ s/[img border=s+(d{1})pxs+(solid|dotted|dashed|outset|inset)s+?#(d{2}|d{3}|d{6})](.+?)[/img]/<img src="$4" alt="-" style="border: $1px $2 #$3;" />/isg;
Something like that should work, written to work with imageize or something

#53838 11/13/2004 12:22 PM
Joined: Nov 2004
Posts: 2
Junior Member
Junior Member
Offline
Joined: Nov 2004
Posts: 2
thnx a lot, I will try to implement that code into my imageresize function.

To minimize the unexpected behaviour i will only allow certain border style combinations.


Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
JAISP
JAISP
PA
Posts: 449
Joined: February 2008
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)