Thread:Itsleo20/@comment-25091708-20140905060951/@comment-25091708-20140906033829

To make it clear: Replace the code in that place with this one: function addMastheadTags( ) { var rights = { } ; // BEGIN List of Accounts Given Extra User Rights Icons - Must list all tags rights[ "Itsleo20" ]                    = [ "Technician" <span class="sy0" style="color:rgb(51,153,51);">, <span class="st0" style="color:rgb(51,102,204);">"Town Guardian" <span class="sy0" style="color:rgb(51,153,51);">, <span class="st0" style="color:rgb(51,102,204);">"Wizard" <span class="br0" style="color:rgb(0,153,0);">] <span class="sy0" style="color:rgb(51,153,51);">, rights<span class="br0" style="color:rgb(0,153,0);">[ <span class="st0" style="color:rgb(51,102,204);">"ItsZee" <span class="br0" style="color:rgb(0,153,0);">]                      <span class="sy0" style="color:rgb(51,153,51);">= <span class="br0" style="color:rgb(0,153,0);">[ <span class="st0" style="color:rgb(51,102,204);">"Technician" <span class="sy0" style="color:rgb(51,153,51);">, <span class="st0" style="color:rgb(51,102,204);">"Town Guardian" <span class="sy0" style="color:rgb(51,153,51);">, <span class="st0" style="color:rgb(51,102,204);">"Wizard" <span class="br0" style="color:rgb(0,153,0);">] <span class="sy0" style="color:rgb(51,153,51);">, rights<span class="br0" style="color:rgb(0,153,0);">[ <span class="st0" style="color:rgb(51,102,204);">"Shroomy05" <span class="br0" style="color:rgb(0,153,0);">]                   <span class="sy0" style="color:rgb(51,153,51);">= <span class="br0" style="color:rgb(0,153,0);">[ <span class="st0" style="color:rgb(51,102,204);">"Technician" <span class="sy0" style="color:rgb(51,153,51);">, <span class="st0" style="color:rgb(51,102,204);">"Town Guardian" <span class="sy0" style="color:rgb(51,153,51);">, <span class="st0" style="color:rgb(51,102,204);">"Wizard" <span class="br0" style="color:rgb(0,153,0);">] <span class="sy0" style="color:rgb(51,153,51);">, rights<span class="br0" style="color:rgb(0,153,0);">[ <span class="st0" style="color:rgb(51,102,204);">"Mister Stay Puft" <span class="br0" style="color:rgb(0,153,0);">]            <span class="sy0" style="color:rgb(51,153,51);">= <span class="br0" style="color:rgb(0,153,0);">[ <span class="st0" style="color:rgb(51,102,204);">"Technician" <span class="sy0" style="color:rgb(51,153,51);">, <span class="st0" style="color:rgb(51,102,204);">"Town Guardian" <span class="br0" style="color:rgb(0,153,0);">] <span class="sy0" style="color:rgb(51,153,51);">, rights<span class="br0" style="color:rgb(0,153,0);">[ <span class="st0" style="color:rgb(51,102,204);">"Snapdragon717" <span class="br0" style="color:rgb(0,153,0);">]               <span class="sy0" style="color:rgb(51,153,51);">= <span class="br0" style="color:rgb(0,153,0);">[ <span class="st0" style="color:rgb(51,102,204);">"Technician" <span class="sy0" style="color:rgb(51,153,51);">, <span class="st0" style="color:rgb(51,102,204);">"Town Guardian" <span class="br0" style="color:rgb(0,153,0);">] <span class="sy0" style="color:rgb(51,153,51);">, rights<span class="br0" style="color:rgb(0,153,0);">[ <span class="st0" style="color:rgb(51,102,204);">"Chickenwrangler369" <span class="br0" style="color:rgb(0,153,0);">]          <span class="sy0" style="color:rgb(51,153,51);">= <span class="br0" style="color:rgb(0,153,0);">[ <span class="st0" style="color:rgb(51,102,204);">"Technician" <span class="sy0" style="color:rgb(51,153,51);">, <span class="st0" style="color:rgb(51,102,204);">"Town Guardian" <span class="br0" style="color:rgb(0,153,0);">] <span class="sy0" style="color:rgb(51,153,51);">, rights<span class="br0" style="color:rgb(0,153,0);">[ <span class="st0" style="color:rgb(51,102,204);">"Electric Plants" <span class="br0" style="color:rgb(0,153,0);">]             <span class="sy0" style="color:rgb(51,153,51);">= <span class="br0" style="color:rgb(0,153,0);">[ <span class="st0" style="color:rgb(51,102,204);">"Lawn Police" <span class="br0" style="color:rgb(0,153,0);">] <span class="sy0" style="color:rgb(51,153,51);">; <span class="co1" style="font-style:italic;color:rgb(0,102,0);">// END List of Accounts Given Extra User Rights Icons <span class="co1" style="font-style:italic;color:rgb(0,102,0);">// BEGIN Script to Remove Old Rights Icons & Insert New <span class="kw1" style="font-weight:bold;color:rgb(0,0,102);">if <span class="br0" style="color:rgb(0,153,0);">( wgCanonicalSpecialPageName <span class="sy0" style="color:rgb(51,153,51);">== <span class="st0" style="color:rgb(51,102,204);">"Contributions" <span class="br0" style="color:rgb(0,153,0);">) <span class="br0" style="color:rgb(0,153,0);">{ <span class="kw1" style="font-weight:bold;color:rgb(0,0,102);">var user <span class="sy0" style="color:rgb(51,153,51);">= wgPageName.<span class="me1" style="color:rgb(102,0,102);">substring <span class="br0" style="color:rgb(0,153,0);">( wgPageName.<span class="me1" style="color:rgb(102,0,102);">lastIndexOf <span class="br0" style="color:rgb(0,153,0);">( <span class="st0" style="color:rgb(51,102,204);">"/" <span class="br0" style="color:rgb(0,153,0);">) <span class="sy0" style="color:rgb(51,153,51);">+ <span class="nu0" style="color:rgb(204,0,0);">1 <span class="br0" style="color:rgb(0,153,0);">) .<span class="me1" style="color:rgb(102,0,102);">replace <span class="br0" style="color:rgb(0,153,0);">( <span class="co2" style="font-style:italic;color:rgb(0,153,102);">/_/g <span class="sy0" style="color:rgb(51,153,51);">, <span class="st0" style="color:rgb(51,102,204);">" " <span class="br0" style="color:rgb(0,153,0);">) <span class="sy0" style="color:rgb(51,153,51);">; <span class="br0" style="color:rgb(0,153,0);">} <span class="kw1" style="font-weight:bold;color:rgb(0,0,102);">else <span class="br0" style="color:rgb(0,153,0);">{ <span class="kw1" style="font-weight:bold;color:rgb(0,0,102);">var user <span class="sy0" style="color:rgb(51,153,51);">= wgTitle<span class="sy0" style="color:rgb(51,153,51);">; <span class="br0" style="color:rgb(0,153,0);">} <span class="kw1" style="font-weight:bold;color:rgb(0,0,102);">if <span class="br0" style="color:rgb(0,153,0);">( <span class="kw1" style="font-weight:bold;color:rgb(0,0,102);">typeof rights<span class="br0" style="color:rgb(0,153,0);">[ user<span class="br0" style="color:rgb(0,153,0);">] <span class="sy0" style="color:rgb(51,153,51);">!= <span class="st0" style="color:rgb(51,102,204);">"undefined" <span class="br0" style="color:rgb(0,153,0);">) <span class="br0" style="color:rgb(0,153,0);">{ <span class="co1" style="font-style:italic;color:rgb(0,102,0);">// remove old rights $<span class="br0" style="color:rgb(0,153,0);">( <span class="st0" style="color:rgb(51,102,204);">'.UserProfileMasthead .masthead-info span.tag' <span class="br0" style="color:rgb(0,153,0);">) .<span class="me1" style="color:rgb(102,0,102);">remove <span class="br0" style="color:rgb(0,153,0);">( <span class="br0" style="color:rgb(0,153,0);">) <span class="sy0" style="color:rgb(51,153,51);">; <span class="kw1" style="font-weight:bold;color:rgb(0,0,102);">for <span class="br0" style="color:rgb(0,153,0);">( <span class="kw1" style="font-weight:bold;color:rgb(0,0,102);">var i<span class="sy0" style="color:rgb(51,153,51);">= <span class="nu0" style="color:rgb(204,0,0);">0 <span class="sy0" style="color:rgb(51,153,51);">, len<span class="sy0" style="color:rgb(51,153,51);">= rights<span class="br0" style="color:rgb(0,153,0);">[ user<span class="br0" style="color:rgb(0,153,0);">] .<span class="me1" style="color:rgb(102,0,102);">length <span class="sy0" style="color:rgb(51,153,51);">; i <span class="sy0" style="color:rgb(51,153,51);">< len<span class="sy0" style="color:rgb(51,153,51);">; i<span class="sy0" style="color:rgb(51,153,51);">++ <span class="br0" style="color:rgb(0,153,0);">) <span class="br0" style="color:rgb(0,153,0);">{ <span class="co1" style="font-style:italic;color:rgb(0,102,0);">// add new rights $<span class="br0" style="color:rgb(0,153,0);">( <span class="st0" style="color:rgb(51,102,204);">'<span class="tag" span style="margin-left: 10px !important">' <span class="sy0" style="color:rgb(51,153,51);">+ rights<span class="br0" style="color:rgb(0,153,0);">[ user<span class="br0" style="color:rgb(0,153,0);">] <span class="br0" style="color:rgb(0,153,0);">[ i<span class="br0" style="color:rgb(0,153,0);">] <span class="sy0" style="color:rgb(51,153,51);">+           <span class="st0" style="color:rgb(51,102,204);">' ' <span class="br0" style="color:rgb(0,153,0);">) .<span class="me1" style="color:rgb(102,0,102);">appendTo <span class="br0" style="color:rgb(0,153,0);">( <span class="st0" style="color:rgb(51,102,204);">'.masthead-info hgroup' <span class="br0" style="color:rgb(0,153,0);">) <span class="sy0" style="color:rgb(51,153,51);">; <span class="br0" style="color:rgb(0,153,0);">} <span class="br0" style="color:rgb(0,153,0);">} <span class="co1" style="font-style:italic;color:rgb(0,102,0);">// END Script to Remove Old Rights Icons & Insert New <span class="br0" style="color:rgb(0,153,0);">} <span class="sy0" style="color:rgb(51,153,51);">; $<span class="br0" style="color:rgb(0,153,0);">( <span class="kw1" style="font-weight:bold;color:rgb(0,0,102);">function <span class="br0" style="color:rgb(0,153,0);">( <span class="br0" style="color:rgb(0,153,0);">) <span class="br0" style="color:rgb(0,153,0);">{   <span class="kw1" style="font-weight:bold;color:rgb(0,0,102);">if <span class="br0" style="color:rgb(0,153,0);">( $<span class="br0" style="color:rgb(0,153,0);">( <span class="st0" style="color:rgb(51,102,204);">'#UserProfileMasthead' <span class="br0" style="color:rgb(0,153,0);">) <span class="br0" style="color:rgb(0,153,0);">) <span class="br0" style="color:rgb(0,153,0);">{      addMastheadTags<span class="br0" style="color:rgb(0,153,0);">( <span class="br0" style="color:rgb(0,153,0);">) <span class="sy0" style="color:rgb(51,153,51);">;    <span class="br0" style="color:rgb(0,153,0);">}  <span class="br0" style="color:rgb(0,153,0);">} <span class="br0" style="color:rgb(0,153,0);">) <span class="sy0" style="color:rgb(51,153,51);">;