Fantasy Survivor

Be sure your league is setup properly before installing any scripts.Setup Video
The Fantasy Survivor script is a custom survivor module you can place on your site. The directory contains an uncompressed version of the file if you want to edit or host yourself. There are numerous options to set , so read through everything in the script once you install on your site.
Fantasy Survivor is a contest that will work for just about every league and requires no extra work for owners.
The basic premise is that the low scoring fantasy team gets eliminated every week until there is one survivor.
The one quirk is that if a team is the high scoring team in a given week then that team will have immunity from elimination the following week. If the team that has immunity happens to be the low scoring team then then next lowest scoring team gets eliminated. When there are only two teams remaining then immunity is not applicable for obvious reasons.
In my leagues we set aside prize money for the contest but you can do it for bragging rights.
I have been doing it for years in my leagues and the owners love it. Many times I have had owners tell me that "oh well I lost this week but at least I didn't get eliminated from survivor".
There are options that adjust weekly scores for the survivor contest or for special eliminations but most leagues won't use them. If you want to use them and you don't understand their implementation then please post and I can explain further.
All scripts require cache.js and font awesome file to be placed in a header message as the 1st line. Please review the section "Custom Scripts" Here
Custom template users do not need to load cache.js or font awesome.

SurvivorPlace in any HPM

<!-- FANTASY SURVIVOR HTML -->
<div class="mobile-wrap survivor_head">
     <div style="text-align:center">
        <span style="font-weight:bold;font-size:larger">Fantasy Survivor Legend: </span>
	<span class="fantasy_survivor_legend_highscore" style="padding:4px;border-radius:0px; margin-right:10px">Immunity</span>
	<span class="fantasy_survivor_legend_warning" style="padding:4px; border-radius:0px; margin-right:10px">Eliminated</span>
	<span class="fantasy_survivor_legend_lowscore" style="padding:4px; border-radius:0px">Saved by Immunity</span>
     </div>
</div>

<div id="survivor_wrapper"></div>


<!-- FANTASY SURVIVOR CSS -->
<style>
/* FANTASY SURVIVOR */
.fantasy_survivor_legend_highscore{font-weight:400;color:#fff;background-color:green;}
.fantasy_survivor_legend_warning{font-weight:400;color:#fff;background-color:red;}
.fantasy_survivor_legend_lowscore{font-weight:400;color:#fff;background-color:orange;}
#fantasy_survivor td.highscore span {
    background:green;
    color:#fff;
    font-weight:bold;
    padding:2px;
    text-decoration:none;
    border-radius:5px;
}
#fantasy_survivor td.warning span {
    background:red;
    color:#fff;
    font-weight:bold;
    padding:2px;
    text-decoration:none;
    border-radius:5px;
}
#fantasy_survivor td.lowscore span {
    background:orange;
    color:#fff;
    font-weight:bold;
    padding:2px;
    text-decoration:none;
    border-radius:5px;
    font-style:normal
}
#fantasy_survivor td{
    padding-top:4px;
    padding-bottom:4px;
    text-decoration:none
}
</style>

<!-- FANTASY SURVIVOR SETTINGS -->
<script>
var survivor_disableImmunity = false;
var survivorAutoRun = true;             // The script makes several API calls so to avoid the potential for "too many requests" error it is suggested to set this to false so the table only populates when link is clicked.
var survivorNameIconLogoAbbrev = 0;  	// 0=name, 1=icon, 2=logo, 3=abbrev, 4=icon_name, 5=logo_name

//SURVIVOR TIEBREAKER
	//CURRENTLY ONLY THREE OPTIONS AVAILABLE: TIEBREAK PLAYER (TBP); YEAR TO DATE PTS (YTD); PREVIOUS WEEK PTS; (PREV)
	//YOU CAN RANK THEM BELOW; NOTE TIEBREAK PLAYER IS ONLY APPLICABLE IF YOUR LEAGUE USES THAT OPTION. IF NOT IT WILL BE IGNORED
	var survivor_tiebreakers = new Array();
	survivor_tiebreakers[0] = "TBP";
	survivor_tiebreakers[1] = "YTD";
	survivor_tiebreakers[2] = "PREV";
	
//SURVIVOR INELIGIBLE TIEBREAK POSITIONS
	var survivor_ineligibleTiebreakPositions = new Array();
	//survivor_ineligibleTiebreakPositions["QB"] = true;
	//survivor_ineligibleTiebreakPositions["PK"] = true;

//SPECIAL ELIMINATION - ENTER ("FID",WEEK#,"REASON",true/false) true/false =>replaces regular elimination)
	var survivor_specialElimination = new Array();
	//example: survivor_specialElimination[0] = new Array("0004",3,"Team 4 failed to submit legal lineup therefore is eliminated",false);

//NO ELIMINATION WEEKS; IF NO ELIMINATION WEEK ENCOUNTERED THEN POINTS WILL ACCUMULATE 
	var survivor_noEliminationWeek = new Array();
	//survivor_noEliminationWeek["wk15"] = 1; //1 = start skip elimination
	//survivor_noEliminationWeek["wk16"] = 1;
	//survivor_noEliminationWeek["wk17"] = 0; //0 = do elimination with cumulative score

//MULTIPLE ELIMINATION WEEKS
	//example below will eliminate three teams in weeks 1 & 2, two teams in week 3 then only one for all other weeks
	//var survivor_multipleEliminationWeeks = ({ "wk1":3 , "wk2":3 , "wk3":2 });
	
//STOP IMMUNITY WEEK
	//normally immunity will begin week 2 and stop when there are only two teams left
	//use the var below to stop immunity in a given week
	//var survivor_disableImmunityWeek = 12;
	
//STOP IMMUNITY TEAMS
	//normally immunity will begin week 2 and stop when there are only two teams left
	//use the var below to stop immunity when there are only a specific number of teams remaining or less
	//var survivor_disableImmunityTeams = 4;
	
//START WEEK
	//set first week of elimination below.  The default is week 1.
	var survivor_startWeek = 1;
	
//SEPARATE DIVISIONS/CONFERENCES AND WHETHER TO INCLUDE OVERALL CHAMPION
	var survivor_separateDivisions = false;
	var survivor_separateConferences = false;
	var survivor_overallChampion = false;

//ALTERNATE NAME FOR GAME
	var survivor_alternateName = "";
</script>

<!-- FANTASY SURVIVOR JS FILE -->
<script src="https://www.mflscripts.com/mfl-apps/survivor/script.js"></script>