Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Not a member yet? Click here to register.
Forgot Password?

How to scale images in forum posts?

Asked Modified Viewed 3,278 times
A
Afliktion
A
  • Junior Member, joined since
  • Contributed 15 posts on the community forums.
  • Started 9 threads in the forums
  • Started this discussions
asked
Junior Member

I am not sure I am posting this in the right area, if not I am sorry.
I am trying to make my forum so that when a member posts an image ( linked ) at say, 1200 x 850, once posted, the image will scale to 550px wide and keep height in proportion. But, when someone clicks the image it will open a new window with the full size image on it. Not in the upload to gallery area, I mean the actual posts for the forum.
I hope I explained that well enough.
I have looked at many questions on the topic, but haven't found what I need to accomplish what I am trying to do.
I am very new to PHP code, and I just can't seem to get how to do this one.
If anyone has a way I can resolve this I would be greatful.

Sincerely, Afliktion
0 replies

4 posts

A
Ankur
A
Ankur 10
Hi! Its me, Ankur Thakur! smile
  • Veteran Member, joined since
  • Contributed 1,277 posts on the community forums.
  • Started 60 threads in the forums
answered
Veteran Member

Try to edit the IMAGE BB Code from includes\bbcodes\img_bbcode_include.php.

You may find this Line in file :
[syntaxhighlighter brush=php,first-line=1,highlight=0,collapse=false,html-script=false]return "<span style='display: block; width: 300px; max-height: 300px; overflow: auto;' class='forum-img-wrapper'><img src='".$matches[1].str_replace(array("?","&amp;","&","="wink, "", $matches[3]).$matches[4]."' alt='".$matches[3].$matches[4]."' style='border:0px' class='forum-img' /></span>";[/syntaxhighlighter]

Try changing the width !
0 replies
A
Afliktion
A
  • Junior Member, joined since
  • Contributed 15 posts on the community forums.
  • Started 9 threads in the forums
  • Started this discussions
answered
Junior Member

:D
Thank you Ankur, worked great!
0 replies
— 3 months later —
S
songiuno
S
  • Member, joined since
  • Contributed 55 posts on the community forums.
  • Started 13 threads in the forums
answered
Member

Question: does this file mod affect only the posted images in the forum or do other features of PhP-Fusion use this setting and would also be affected?
0 replies
B
batbaru1
B
  • Member, joined since
  • Contributed 54 posts on the community forums.
  • Started 14 threads in the forums
answered
Member

Does this mod depend on the version I'm running? I'm on v7.02.04 and also want to have it so that forum attached images display at about 550px wide, and when the image is clicked it will show in original full size.

I tried editing includes\bbcodes\img_bbcode_include.php as mentioned but upon doing a few test posts, it doesn't seem to do anything.

Help?
0 replies

Labels

None yet

Statistics

  • Views 0 views
  • Posts 4 posts
  • Votes 0 votes
  • Topic users 4 members

4 participants

S
S
  • Member, joined since
  • Contributed 55 posts on the community forums.
  • Started 13 threads in the forums
B
B
  • Member, joined since
  • Contributed 54 posts on the community forums.
  • Started 14 threads in the forums
A
A
Ankur 10
Hi! Its me, Ankur Thakur! smile
  • Veteran Member, joined since
  • Contributed 1,277 posts on the community forums.
  • Started 60 threads in the forums
A
A
  • Junior Member, joined since
  • Contributed 15 posts on the community forums.
  • Started 9 threads in the forums
  • Started this discussions

Notifications

Track thread

You are not receiving notifications from this thread.

Related Questions

Not yet