Make requests and get help.
Moderator: Manveer
-
alek
- Registered User
- Posts: 2904
- Joined: Sat Mar 03, 2018 4:11 pm
- Location: 2 goblinz under age 9
- Age: 41
#1
Post
by alek » Fri May 20, 2022 7:28 am
Hi,
Is there a way to resize an image that been placed inside the img tags?
Code: Select all
[img resizeCommandsGoHere]somePicture[/img]
Before you respond, please assume I'm an idiot when it comes to coding... because I am.
-
mgil
- Shitpostmaster General
- Posts: 8401
- Joined: Wed Sep 13, 2017 5:46 pm
- Location: FlabLab©®
- Age: 48
#2
Post
by mgil » Fri May 20, 2022 4:47 pm
alek wrote: ↑Fri May 20, 2022 7:28 am
Hi,
Is there a way to resize an image that been placed inside the img tags?
Code: Select all
[img resizeCommandsGoHere]somePicture[/img]
Before you respond, please assume I'm an idiot when it comes to coding... because I am.
Not that I know of. I thought it just displayed the image scaled to display.
-
alek
- Registered User
- Posts: 2904
- Joined: Sat Mar 03, 2018 4:11 pm
- Location: 2 goblinz under age 9
- Age: 41
#3
Post
by alek » Mon May 23, 2022 3:57 pm
mgil wrote: ↑Fri May 20, 2022 4:47 pm
alek wrote: ↑Fri May 20, 2022 7:28 am
Hi,
Is there a way to resize an image that been placed inside the img tags?
Code: Select all
[img resizeCommandsGoHere]somePicture[/img]
Before you respond, please assume I'm an idiot when it comes to coding... because I am.
Not that I know of. I thought it just displayed the image scaled to display.
Makes sense; thanks.
-
BenM
- Registered User
- Posts: 3787
- Joined: Sun Sep 17, 2017 7:18 pm
- Age: 47
#4
Post
by BenM » Sun May 29, 2022 5:59 am
How's this - I just created a new BBCode, [imgrs]
Use it the same as the [img] BBCode, but with a percentage to resize the image (based on the width of the forum). So to resize it to 50% you'd go like [imgrs=50]https://path/to/image[/imgrs]
I'll test it in the next post....
-
BenM
- Registered User
- Posts: 3787
- Joined: Sun Sep 17, 2017 7:18 pm
- Age: 47
#5
Post
by BenM » Sun May 29, 2022 6:06 am
Resize to 10%
Resize to 50%
Resize to 80%
Seems like it!
PS I just stole the code/idea from someone else on another forum, can't take all the credit.
-
mgil
- Shitpostmaster General
- Posts: 8401
- Joined: Wed Sep 13, 2017 5:46 pm
- Location: FlabLab©®
- Age: 48
#6
Post
by mgil » Sun May 29, 2022 6:15 am
Nice work! @BenM
-
alek
- Registered User
- Posts: 2904
- Joined: Sat Mar 03, 2018 4:11 pm
- Location: 2 goblinz under age 9
- Age: 41
#7
Post
by alek » Tue May 31, 2022 8:51 am
Yes! That’s great!