Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> RavenNuke(tm) v2.5x
Author Message
neralex
Site Admin



Joined: Aug 22, 2007
Posts: 1774

PostPosted: Mon Jan 04, 2021 11:50 am Reply with quote

kd8hho wrote:
Also discovered "maybe" a bug.. testing forum posting, youtube BB code. did not work correctly. would not show emb video. looked at the code in themes

changed the url from [ Only registered users can see links on this board! Get registered or login! ] to [ Only registered users can see links on this board! Get registered or login! ] after change emb YT vids works. im guessing YT changed how embed video works

This issue affects more files than the bbcode.tpl files of the themes... Thanks to kd8hho for reporting this.

/modules/forums/includes/bbcode.php
/modules/forums/templates/subSilver/bbcode.tpl
/themes/xxx/forums/bbcode.tpl

Here you can find the full list of affected files and the changes in the core-package: [ Only registered users can see links on this board! Get registered or login! ]

_________________
Github: RavenNuke  
View user's profile Send private message
neralex







PostPosted: Mon Jan 04, 2021 1:51 pm Reply with quote

While fixing the issue I played with the embedded container-sizes to add some responsive css-features.

Aspect ratio 16:9



Aspect ratio 4:3



Open /includes/bbcode_box/css/bbcode_addons.css and each /themes/xxx/style/bbcode_addons.css and find:

css Code:
.forumvideotagline{padding-top:6px}

add after:

css Code:
/* video embed-responsive based on BS4 */

div[class*='video-embed-responsive-'] {
position: relative;
display: block;
width: 100% !important;
max-width: 50%;
padding: 0;
overflow: hidden;
}
div[class*='video-embed-responsive-']::before {
display: block;
content: "";
}
div[class*='video-embed-responsive-'] iframe {
position: absolute;
top: 0;
bottom: 0;
left: 0;
width: 100% !important;
height: 100% !important;
border: 0;
}
div[class*='video-embed-responsive-'] + .forumvideotagline {padding-top: 0;}
.video-embed-responsive-16by9::before {padding-top: 56.25%;}
.video-embed-responsive-4by3::before {padding-top: 75%;}


Open /includes/bbcode_box/js/bbcode_extras.js and at the end:

Code:
$('div[class*=\'video-embed-responsive-\'] > .forumvideotagline').each(function () {

   $(this).parent().after($(this));
});


Open /modules/Forums/includes/bbcode.php and find:

php Code:
(video|video-small|video-medium|video-large|video-left|video-right|video-center|video-small-left|video-small-right|video-small-center|video-medium-left|video-medium-right|video-medium-center|video-large-left|video-large-right|video-large-center)

replace it with:

php Code:
(video|video-small|video-medium|video-large|video-left|video-right|video-center|video-small-left|video-small-right|video-small-center|video-medium-left|video-medium-right|video-medium-center|video-large-left|video-large-right|video-large-center|video-embed-responsive-16by9|video-embed-responsive-4by3)


Open /modules/Forums/templates/subSilver/posting_body.tpl and each /themes/xxx/forums/posting_body.tpl and find:

html Code:
<div class="box-select"><select id="utubesposition" name="utubesposition" onchange="youtubeline()">

<option value="">Default</option>
<option value="-left">Left</option>
<option value="-center" selected="selected">Center</option>
<option value="-right">Right</option>
</select></div>

replace it with:

html Code:
<div class="box-select"><select id="utubesposition" name="utubesposition" onchange="youtubeline()">

<option value="">Default</option>
<option value="-left">Left</option>
<option value="-center" selected="selected">Center</option>
<option value="-right">Right</option>
<option value="-embed-responsive-16by9">Responsive 16:9</option>
<option value="-embed-responsive-4by3">Responsive 4:3</option>
</select></div>



dropdown-options.jpg
 Description:
 Filesize:  47.91 KB
 Viewed:  3165 Time(s)

dropdown-options.jpg




Last edited by neralex on Mon Jan 04, 2021 4:57 pm; edited 1 time in total 
kd8hho
Worker
Worker



Joined: Mar 30, 2009
Posts: 132

PostPosted: Mon Jan 04, 2021 4:42 pm Reply with quote

Makes me feel a bit better knowing I actually found a bug and it wasn't just me! Laughing

_________________
Linux Register User #481509 | Ubuntu Register User #25492  
View user's profile Send private message Visit poster's website
neralex







PostPosted: Mon Jan 04, 2021 5:07 pm Reply with quote

Spasticdonkey did the last big changes in 2012, I patched it in 2018 and I guess there are more little issues. Its like a Knitting Spool. Wink
 
kd8hho







PostPosted: Mon Jan 04, 2021 6:49 pm Reply with quote

neralex wrote:
Spasticdonkey did the last big changes in 2012, I patched it in 2018 and I guess there are more little issues. Its like a Knitting Spool. Wink


gets hard to keep up with all the changes as people drop off the dev.

Once I get my new site finished and up and running I will have to really study the php again, its been at least 10 years or so since I really did any serious php stuff outside of edit a simple conf file.
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> RavenNuke(tm) v2.5x

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©