Home | Webstore
Latest News: OOTP Update 20.5.47 - OOTP 20 Available - FHM 5 Available

Collection Missions for Perfect Team Released!

  

Go Back   OOTP Developments Forums > Out of the Park Baseball 20 > OOTP Mods > OOTP Mods - Logos, Graphics, and HTML

Reply
 
Thread Tools
Old 12-21-2017, 02:01 PM   #1
andjbock
Hall Of Famer
 
andjbock's Avatar
 
Join Date: Jul 2003
Location: Somerville, MA, USA Bats: Right Throws: Left
Posts: 3,542
Thanks: 101
Thanked 170x in 98 posts
Replacing player photos with the default player photo in tpl (league website Q)

I know this isn't a super popular topic, but does anyone which .tpl has the images for the leaderboard reports?

You can see the broken image links on my league's Red Sox page.

http://poundslash.com/ootp/lgreports.../team_100.html

I was able to figure out the player profile picture, so it always goes to the default photo, but can't find where I can replace the leaderboad photos.

I've checked the following and no luck:

box_leaders.tpl
box_leaders_start.tpl
__________________
andjbock is offline   Reply With Quote
Old 05-13-2019, 03:02 PM   #2
andjbock
Hall Of Famer
 
andjbock's Avatar
 
Join Date: Jul 2003
Location: Somerville, MA, USA Bats: Right Throws: Left
Posts: 3,542
Thanks: 101
Thanked 170x in 98 posts
Hi self,

If you add the following code to head_bits.tpl (templates folder in your saved league, not the default templates folder) this should then be produced across all html pages.

Replace "http://ootp.biz/lgreports/images/default_player_photo.png" with the location and name of the image you want to globally replace broken image links with.

Use < script ></script> tags around all of the code below.


Code:
$(window).bind('load', function() {
$('img').each(function() {
    if((typeof this.naturalWidth != "undefined" &&
        this.naturalWidth == 0 ) 
        || this.readyState == 'uninitialized' ) {
        $(this).attr('src', 'http://ootp.biz/lgreports/images/default_player_photo.png');
    }
}); })

Last edited by andjbock; 05-24-2019 at 09:52 AM.
andjbock is offline   Reply With Quote
Reply

Bookmarks

Tags
html, reports, templates, tpl, website

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 09:27 AM.

 

Major League Baseball trademarks and copyrights are used with permission of MLB Advanced Media, L.P. Minor League Baseball trademarks and copyrights are used with the permission of Minor League Baseball. All rights reserved.

The Major League Baseball Players Association (www.MLBPLAYERS.com ) is the collective bargaining representative for all professional baseball players of the thirty Major League Baseball teams and serves as the exclusive group licensing agent for commercial and licensing activities involving active Major League baseball players. On behalf of its members, it operates the Players Choice licensing program and the Players Choice Awards, which benefit the needy through the Major League Baseball Players Trust, a charitable foundation established and run entirely by Major League baseball players. Follow: @MLB_Players; @MLBPAClubhouse; @MLBPlayersTrust

Out of the Park Baseball is a registered trademark of Out of the Park Developments GmbH & Co. KG

Google Play is a trademark of Google Inc.

Apple, iPhone, iPod touch and iPad are trademarks of Apple Inc., registered in the U.S. and other countries.

COPYRIGHT © 2017 OUT OF THE PARK DEVELOPMENTS. ALL RIGHTS RESERVED.

 

Powered by vBulletin® Version 3.8.10
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Copyright © 2018 Out of the Park Developments