Gina Fegreus
There was a problem with a Velocity script
Page/sports/bio-template
ErrorVM #printHeadshot: too many arguments to macro. Wanted 0 got 2 at bio-template[line 923, column 1]
Page source:
1: #if ($browser.getIphone() || $browser.getMobile())
2: 	#set ($isMobile = true)
3: #else
4: 	#set ($isMobile = false)
5: #end
6: 
7: ## PICK UP OPTIONS
8: $website.include("options")
9: #set ($options = $request.getAttribute("options"))
10: #set ($locale = "en_us")
11: #set ($locale = $options.get("locale"))
12:  
13: ## STATS DATA
14: #if ($request.getParameter("stats"))
15: 	
16: ## FETCH THE BIO URL FROM THE PARAMETER
17: #set ($bioURL = $request.getParameter("biourl"))
18: 
19: ## VIEW IS AVAILABLE PROVIDED WHEN REACHED HERE
20: #set ($view = $request.getParameter("view"))
21: 
22: #set ($pos = "")
23: #set ($pos = $attributes.get("position"))
24: #set ($posVec = $pos.split("/"))
25: #set ($pos = $posVec[0])
26: #set ($pos = $pos.toLowerCase())
27: #set ($statPos = $positions.get($pos))
28: 
29: #set ($playerId = $attributes.get("playerId"))
30: #set ($stats = $splits.overall)
31: 
32: #if ($locale == "en_us")
33: #set ($defLabel = 'Defense')
34: #elseif ($locale == "en_gb") 
35: #set ($defLabel = 'Defence')
36: #end
37: 
38: #macro (gamelogData $p)
39: 
40: #set ($p = $positions.get($p))
41: #set ($gamelogs = $gamelogs.get($p))
42: 
43: ## SECONDARY TAB CONTENT FOR ONLY FOOTBALL,  BASEBALL AND BASKETBALL
44: #if ($sport.enumCode == 0 || $sport.enumCode == 1 || $sport.enumCode == 2)
45:   #set ($class = "sub-tab-content")
46:   #if ($activePos == $p)
47:     #set ($class = "sub-tab-content active")
48:   #end
49:   #if ($isMobile)
50: 	<div class="mobile-bios-subtab-panel mobile-stats-panel-wrapper #if ($activePos == $p) active #end">
51:   #else
52: 	<div class="$class">
53:   #end
54: #end
55: 	
56: #if (! $isMobile)
57: 	<div class="stats-fullbox clearfix">
58: #else
59: 	<div class="mobile-stats-panel-container">
60: #end
61: <table>
62:   <tr>
63:     <th #if ($isMobile) width="10%" #end>Date</th>
64:     <th #if ($isMobile) class="mobile-stats-fixed-column" #*width="20%"*# #end>Opponent</th>
65:     <th>Score</th>
66:     #foreach ($gamelog in $gamelogs)
67:       <th>$gamelog</th>
68:     #end
69:   </tr>
70: 
71: #set ($counter = 0)
72: #foreach ($event in $events)
73:  #set ($counter = $counter + 1)
74:  #if ($counter % 2 == 0)
75:   #set ($row = "even")
76:  #else
77:   #set ($row = "odd")
78:  #end
79:   <tr class="${row}">
80:     <td>$formatter.formatDate($event.event.date, "MMM d")</td>
81:     <td #if ($isMobile) class="mobile-stats-fixed-column" #end>
82:     #if ($event.event.neutralSite.length() > 0) vs.
83:     #elseif (!$event.event.home) at
84:     #else ## nothing for a home game
85:     #end
86:     $event.event.opponent.name</td>
87:     <td class="align-center">
88:     #if ($event.event.statusCode >= 0)
89:       #if ($event.event.eventId.length() > 0 && $event.stats.size() > 0)
90:       <a href="../boxscores/${formatter.formatDate($event.event.date, "yyyyMMdd")}_${event.event.eventId.substring(0, 4)}.xml">${event.event.APResult}</a>
91:       #else
92:       ${event.event.APResult}
93:       #end
94:     #else &nbsp; #end
95:     </td>
96:     #foreach ($gamelog in $gamelogs.keySet())
97:       #set ($value = "-")
98:       #set ($value = $formatter.formatNumber($event.stats.get($gamelog), $formats.get($gamelog)))
99:       <td class="align-center">
100:       #if ($value.length() > 0)$value#else - #end
101:       </td>
102:     #end
103:   </tr>
104: #end
105: </table>
106: </div>
107: 
108: #if ($sport.enumCode == 0 || $sport.enumCode == 1 || $sport.enumCode == 2)
109:   </div>
110: #end
111: 
112: #end ## macro gamelogData
113: 
114: #macro (split $statPosBriefs $label $stats $class)
115:   <tr class="$!{class}">
116:     <td #if ($isMobile) class="mobile-stats-fixed-column" #end>${label}</td>
117:     #foreach ($brief in $statPosBriefs.keySet())
118:       #set ($value = "-")
119:       #set ($value = $!formatter.formatNumber($stats.get($brief), $formats.get($brief)))
120:       <td class="align-center">#if ($value.length() > 0) $value #else - #end</td>
121:     #end
122:   </tr>
123: #end
124: 
125: #set ($colspan = $statPosBriefs.size() + 1)
126: #macro (printSplitsHr)
127: 	#if ($isMobile)
128: 		<tr>
129: 			<td class="mobile-stats-fixed-column">&nbsp;</td>
130: 			<td colspan="$statPosBriefs.size()">&nbsp;</td>
131: 		</tr>
132: 	#else
133: 		<tr><td colspan="${colspan}"><hr /></td></tr>
134: 	#end
135: #end
136: 
137: #macro (splitsData $p)
138: 
139: #set ($p = $positions.get($p))
140: #set ($statPosBriefs = $briefs.get($p))
141: 
142: ## SECONDARY TAB CONTENT FOR ONLY FOOTBALL,  BASEBALL AND BASKETBALL
143: #if ($sport.enumCode == 0 || $sport.enumCode == 1 || $sport.enumCode == 2)
144:   #set ($class = "sub-tab-content")
145:   #if ($activePos == $p)
146:     #set ($class = "sub-tab-content active")
147:   #end
148:   #if ($isMobile)
149: 	<div class="mobile-bios-subtab-panel mobile-stats-panel-wrapper #if ($activePos == $p) active #end">
150:   #else
151: 	<div class="$class">
152:   #end
153: #end
154: 	
155: #if (! $isMobile) 
156: 	<div class="stats-fullbox clearfix">
157: #else
158: 	<div class="mobile-stats-panel-container">
159: #end
160: <table>
161:   <tr>
162:     <th #if ($isMobile) class="mobile-stats-fixed-column" #end>&nbsp;</th>
163:     #foreach ($brief in $statPosBriefs)
164:       <th>$brief</th>
165:     #end
166:   </tr>
167: 
168: #split($statPosBriefs, "Total", $splits.overall, "odd")
169: #split($statPosBriefs, "Conference", $splits.conference, "even")
170: #split($statPosBriefs, "Exhibition", $splits.exhibition, "odd")
171: 
172: #printSplitsHr()
173: 
174: #split($statPosBriefs, "Home", $splits.home, "odd")
175: #split($statPosBriefs, "Away", $splits.away, "even")
176: #split($statPosBriefs, "Neutral", $splits.neutral, "odd")
177: 
178: #printSplitsHr()
179: 
180: #split($statPosBriefs, "Wins", $splits.inWins, "odd")
181: #split($statPosBriefs, "Losses", $splits.inLosses, "even")
182: #if ($sport.enumCode == 5) ## Ice hockey
183:   #split($statPosBriefs, "Ties", $splits.inTies, "odd")
184: #end
185: 
186: #printSplitsHr()
187: 
188: ## Going to need to replace this with sound logic that does not use the sport to determine dates
189: #if ($sport.enumCode == 5) ## Ice hockey
190:  #split($statPosBriefs, "September", $splits.september, "odd")
191:  #split($statPosBriefs, "October", $splits.october, "even")
192:  #split($statPosBriefs, "November", $splits.november, "odd")
193:  #split($statPosBriefs, "December", $splits.december, "even")
194:  #split($statPosBriefs, "January", $splits.january, "odd")
195:  #split($statPosBriefs, "February", $splits.february, "even")
196:  #split($statPosBriefs, "March", $splits.march, "odd")
197:  #split($statPosBriefs, "April", $splits.april, "even")
198: #elseif ($sport.enumCode == 2) ## Basketball
199:  #split($statPosBriefs, "November", $splits.november, "odd")
200:  #split($statPosBriefs, "December", $splits.december, "even")
201:  #split($statPosBriefs, "January", $splits.january, "odd")
202:  #split($statPosBriefs, "February", $splits.february, "even")
203:  #split($statPosBriefs, "March", $splits.march, "odd")
204: #elseif ($sport.enumCode == 3 or $sport.enumCode == 9) ## Soccer or field hockey
205:  #split($statPosBriefs, "September", $splits.september, "odd")
206:  #split($statPosBriefs, "October", $splits.october, "even")
207:  #split($statPosBriefs, "November", $splits.november, "odd")
208:  #split($statPosBriefs, "December", $splits.december, "even")
209: #elseif ($sport.enumCode == 0) ## Football
210:  #split($statPosBriefs, "August", $splits.august, "odd")
211:  #split($statPosBriefs, "September", $splits.september, "even")
212:  #split($statPosBriefs, "October", $splits.october, "odd")
213:  #split($statPosBriefs, "November", $splits.november, "even")
214:  #split($statPosBriefs, "December", $splits.december, "odd")
215: #elseif ($sport.enumCode == 6 or $sport.enumCode == 10) ## Men's or women's lacrosse
216:  #split($statPosBriefs, "January", $splits.january, "odd")
217:  #split($statPosBriefs, "February", $splits.february, "even")
218:  #split($statPosBriefs, "March", $splits.march, "odd")
219:  #split($statPosBriefs, "April", $splits.april, "even")
220:  #split($statPosBriefs, "May", $splits.may, "odd")
221: #end
222: </table>
223: 
224: </div> ## stats-fullbox
225: 
226: #if ($sport.enumCode == 0 || $sport.enumCode == 1 || $sport.enumCode == 2)
227:   </div>
228: #end
229: 
230: #end ## macro splitsData
231: 
232: #macro (printRecentGames)
233: <table>
234: <tr><th colspan="3">Recent Games</th></tr>
235: #set ($eventEnd = -1)
236: #foreach ($event in $events)
237:   #if ($event.event.result.resolved)
238:     #set ($eventEnd = $velocityCount)
239:   #end
240: #end
241: #set ($eventStart = $eventEnd - 5)
242: #if ($eventStart < 0) #set ($eventStart = 0) #end
243: 
244: #set ($counter = 0)
245: #foreach ($event in $events)
246: #if ($velocityCount >= $eventStart and $velocityCount <= $eventEnd)
247: 
248:  #set ($counter = $counter + 1)
249:  #if ($counter % 2 == 0)
250:   #set ($row = "even")
251:  #else
252:   #set ($row = "odd")
253:  #end
254: 
255:   <tr class="${row}">
256:     <td>$formatter.formatDate($event.event.date, "MMM d")</td>
257:     <td>
258:     #if ($event.event.neutralSite.length() > 0) vs.
259:     #elseif (!$event.event.home) at
260:     #else ## nothing for a home game
261:     #end
262:     $event.event.opponent.name</td>
263:     <td>
264:     #if ($event.event.statusCode >= 0)
265:       #if ($event.event.eventId.length() > 0 && $event.stats.size() > 0)
266:       <a href="../boxscores/${formatter.formatDate($event.event.date, "yyyyMMdd")}_${event.event.eventId.substring(0, 4)}.xml">${event.event.APResult}</a>
267:       #else
268:       ${event.event.APResult}
269:       #end
270:     #end
271:   </tr>
272: #end ## if
273: #end
274: </table>
275: #end
276: 
277: #macro (printSubTab $pos $label $activePos $view)
278: 	<option #if ($activePos == $pos) selected="selected" #end value="${bioURL}?view=${view}&pos=${pos}">$!label</option>
279: #end
280: 
281: 
282: #if ($isMobile)
283: 
284: #set ($activePos = $statPos)
285: #if ($request.getParameter("view") == "gamelog" && $positions.get($request.getParameter("pos")).length() > 0)
286: 	#set ($activePos = $positions.get($request.getParameter("pos")))
287: #end
288: 
289: <div id="tab-gamelog">
290: 
291: ## SECONDARY TABS FOR ONLY FOOTBALL,  BASEBALL AND BASKETBALL
292: #if ($sport.enumCode == 0 || $sport.enumCode == 1 || $sport.enumCode == 2)
293: 	
294: <select class="mobile-bios-subtabs clearfix">
295: 
296: #if ($sport.enumCode == 0) ## Football
297: 
298: #printSubTab('gb', 'Passing', $activePos, 'gamelog')
299: #printSubTab('rb', 'Rushing', $activePos, 'gamelog')
300: #printSubTab('wr', 'Receiving', $activePos, 'gamelog')
301: #printSubTab('k', 'Kicking', $activePos, 'gamelog')
302: #printSubTab('p', 'Punting', $activePos, 'gamelog')
303: #printSubTab('kr', 'Returns', $activePos, 'gamelog')
304: #printSubTab('d', $defLabel, $activePos, 'gamelog')
305: 
306: #elseif ($sport.enumCode == 1) ## Baseball
307: 
308: #printSubTab('h', 'Hitting', $activePos, 'gamelog')
309: #printSubTab('p', 'Pitching', $activePos, 'gamelog')
310: #printSubTab('f', 'Fielding', $activePos, 'gamelog')
311: 
312: #elseif ($sport.enumCode == 2) ## Basketball
313: 
314: #printSubTab('sh', 'Shooting', $activePos, 'gamelog')
315: #printSubTab('bc', 'Ball control', $activePos, 'gamelog')
316: 
317: #end
318: 
319: </select> ## stats-tabs-secondary
320: 
321: #end ## sport check for secondary tabs
322: 
323: #if ($sport.enumCode == 0) ## Football
324: 
325:   #gamelogData("qb") ## PASSING
326:   #gamelogData("rb") ## RUSHING
327:   #gamelogData("wr") ## RECEIVING
328:   #gamelogData("k") ## KICKING
329:   #gamelogData("p") ## PUNTING
330:   #gamelogData("kr") ## RETURNS
331:   #gamelogData("d") ## DEFENSE
332:   
333: #elseif ($sport.enumCode == 1) ## Baseball
334: 
335:   #gamelogData("h") ## HITTING
336:   #gamelogData("p") ## PITCHING
337:   #gamelogData("f") ## FIELDING
338:   
339: #elseif ($sport.enumCode == 2)
340: 
341:   #gamelogData("sh") ## SHOOTING
342:   #gamelogData("bc") ## BALL CONTROL
343:   
344: #else
345: 	
346:   #gamelogData($pos)
347:   
348: #end
349: 	
350: </div> ## tab-content
351: ## END GAMELOG
352: 
353: ## SPLITS
354: #set ($activePos = $statPos)
355: #if ($request.getParameter("view") == "splits" && $positions.get($request.getParameter("pos")).length() > 0)
356: 	#set ($activePos = $positions.get($request.getParameter("pos")))
357: #end
358: 
359: 
360: <div id="tab-splits">
361: 
362: ## SECONDARY TABS FOR ONLY FOOTBALL,  BASEBALL AND BASKETBALL
363: #if ($sport.enumCode == 0 || $sport.enumCode == 1 || $sport.enumCode == 2)
364: 	<select class="mobile-bios-subtabs clearfix">
365: 		#if ($sport.enumCode == 0) ## Football
366: 
367: 			#printSubTab('gb', 'Passing', $activePos, 'splits')
368: 			#printSubTab('rb', 'Rushing', $activePos, 'splits')
369: 			#printSubTab('wr', 'Receiving', $activePos, 'splits')
370: 			#printSubTab('k', 'Kicking', $activePos, 'splits')
371: 			#printSubTab('p', 'Punting', $activePos, 'splits')
372: 			#printSubTab('kr', 'Returns', $activePos, 'splits')
373: 			#printSubTab('d', $defLabel, $activePos, 'splits')
374: 
375: 		#elseif ($sport.enumCode == 1) ## Baseball
376: 
377: 			#printSubTab('h', 'Hitting', $activePos, 'splits')
378: 			#printSubTab('p', 'Pitching', $activePos, 'splits')
379: 			#printSubTab('f', 'Fielding', $activePos, 'splits')
380: 
381: 		#elseif ($sport.enumCode == 2) ## Basketball
382: 
383: 			#printSubTab('sh', 'Shooting per game', $activePos, 'splits')
384: 			#printSubTab('st', 'Shooting', $activePos, 'splits')
385: 			#printSubTab('bc', 'Ball control per game', $activePos, 'splits')
386: 			#printSubTab('bt', 'Ball control', $activePos, 'splits')
387: 
388: 		#end
389: 	</select>
390: #end ## sport check for secondary tabs
391: 	
392: #if ($sport.enumCode == 0) ## Football
393: 
394: ## <div class="sub-tab-panels">
395: 	#splitsData("qb") ## PASSING
396: 	#splitsData("rb") ## RUSHING
397: 	#splitsData("wr") ## RECEIVING
398: 	#splitsData("k") ## KICKING
399: 	#splitsData("p") ## PUNTING
400: 	#splitsData("kr") ## RETURNS
401: 	#splitsData("d") ## DEFENSE
402: ## </div>
403: 	
404: #elseif ($sport.enumCode == 1) ## Baseball
405: 
406: ## <div class="sub-tab-panels">
407: 	#splitsData("h") ## HITTING
408: 	#splitsData("p") ## PITCHING
409: 	#splitsData("f") ## FIELDING
410: ## </div>
411: 	
412: #elseif ($sport.enumCode == 2) ## Basketball
413: 	
414: ## <div class="sub-tab-panels">
415: 	#splitsData("sh") ## SHOOTING PER GAME
416: 	#splitsData("st") ## SHOOTING
417: 	#splitsData("bc") ## BALL CONTROL PER GAME
418: 	#splitsData("bt") ## BALL CONTROL
419: ## </div>
420: 
421: #else
422: 	
423: 	#splitsData($pos)
424: 	
425: #end
426: 
427: </div> ## tab-content
428: ## SPLITS
429: 
430: 
431: 
432: 
433: 
434: #else
435: 
436: 
437: 
438: ## PROFILE
439: #set ($class = "tab-content clearfix")
440: #if ($view == "profile")
441: 	#set ($class = "tab-content clearfix active")
442: #end
443: <div class="${class}">
444: <div class="stats-wrapper clearfix">
445: 
446: ## LAST SIX GAMES
447: <div class="stats-halfbox-left">
448: #printRecentGames()
449: </div>
450: 
451: ## RANKING
452: $website.include("../players?tmpl=stats-bios-rank-template&rank=${playerId}&pos=${statPos}")
453: 
454: </div> ## stats-wrapper	
455: </div> ## tab-content
456: ## PROFILE
457: 
458: ## GAMELOG
459: #set ($class = "tab-content clearfix")
460: #if ($view == "gamelog")
461: 	#set ($class = "tab-content clearfix active")
462: #end
463: 
464: #set ($activePos = $statPos)
465: #if ($request.getParameter("view") == "gamelog" && $positions.get($request.getParameter("pos")).length() > 0)
466: 	#set ($activePos = $positions.get($request.getParameter("pos")))
467: #end
468: 
469: <div class="${class}">
470: <div class="stats-wrapper clearfix">
471: 
472: ## SECONDARY TABS FOR ONLY FOOTBALL,  BASEBALL AND BASKETBALL
473: #if ($sport.enumCode == 0 || $sport.enumCode == 1 || $sport.enumCode == 2)
474: 	
475: <div class="stats-tabs-secondary clearfix">
476: <ul class="clearfix">
477: 
478: #if ($sport.enumCode == 0) ## Football
479: 
480: #if ($activePos == "qb")<li class="active">#else <li> #end<a href="${bioURL}?view=gamelog&pos=qb">Passing</a></li>
481: 
482: #if ($activePos == "rb")<li class="active">#else <li> #end<a href="${bioURL}?view=gamelog&pos=rb">Rushing</a></li>
483: 
484: #if ($activePos == "wr")<li class="active">#else <li> #end<a href="${bioURL}?view=gamelog&pos=wr">Receiving</a></li>
485: 
486: #if ($activePos == "k")<li class="active">#else <li> #end<a href="${bioURL}?view=gamelog&pos=k">Kicking</a></li>
487: 
488: #if ($activePos == "p")<li class="active">#else <li> #end<a href="${bioURL}?view=gamelog&pos=p">Punting</a></li>
489: 
490: #if ($activePos == "kr")<li class="active">#else <li> #end<a href="${bioURL}?view=gamelog&pos=kr">Returns</a></li>
491: 
492: #if ($activePos == "d")<li class="active">#else <li> #end<a href="${bioURL}?view=gamelog&pos=d">#if ($locale == "en_us")Defense #elseif ($locale == "en_gb") Defence #end</a></li>
493: 
494: #elseif ($sport.enumCode == 1) ## Baseball
495: 
496: #if ($activePos == "h")<li class="active">#else <li> #end<a href="${bioURL}?view=gamelog&pos=h">Hitting</a></li>
497: 
498: #if ($activePos == "p")<li class="active">#else <li> #end<a href="${bioURL}?view=gamelog&pos=p">Pitching</a></li>
499: 
500: #if ($activePos == "f")<li class="active">#else <li> #end<a href="${bioURL}?view=gamelog&pos=f">Fielding</a></li>
501: 
502: #elseif ($sport.enumCode == 2) ## Basketball
503: 
504: #if ($activePos == "sh")<li class="active">#else <li> #end<a href="${bioURL}?view=gamelog&pos=sh">Shooting</a></li>
505: 
506: #if ($activePos == "bc")<li class="active">#else <li> #end<a href="${bioURL}?view=gamelog&pos=bc">Ball control</a></li>
507: 
508: #end
509: 
510: </ul>
511: </div> ## stats-tabs-secondary
512: 
513: #end ## sport check for secondary tabs
514: 
515: #if ($sport.enumCode == 0) ## Football
516: 
517: <div class="sub-tab-panels">
518:   #gamelogData("qb") ## PASSING
519:   #gamelogData("rb") ## RUSHING
520:   #gamelogData("wr") ## RECEIVING
521:   #gamelogData("k") ## KICKING
522:   #gamelogData("p") ## PUNTING
523:   #gamelogData("kr") ## RETURNS
524:   #gamelogData("d") ## DEFENSE
525: </div>
526:   
527: #elseif ($sport.enumCode == 1) ## Baseball
528: 
529: <div class="sub-tab-panels">
530:   #gamelogData("h") ## HITTING
531:   #gamelogData("p") ## PITCHING
532:   #gamelogData("f") ## FIELDING
533: </div>
534:   
535: #elseif ($sport.enumCode == 2)
536: 
537: <div class="sub-tab-panels">
538:   #gamelogData("sh") ## SHOOTING
539:   #gamelogData("bc") ## BALL CONTROL
540: </div>
541:   
542: #else
543: 	
544:   #gamelogData($pos)
545:   
546: #end
547: 	
548: </div> ## stats-wrapper
549: </div> ## tab-content
550: ## GAMELOG
551: 
552: ## SPLITS
553: #set ($class = "tab-content clearfix")
554: #if ($view == "splits")
555: 	#set ($class = "tab-content clearfix active")
556: #end
557: 
558: #set ($activePos = $statPos)
559: #if ($request.getParameter("view") == "splits" && $positions.get($request.getParameter("pos")).length() > 0)
560: 	#set ($activePos = $positions.get($request.getParameter("pos")))
561: #end
562: 
563: <div class="${class}">
564: <div class="stats-wrapper clearfix">
565: 
566: ## SECONDARY TABS FOR ONLY FOOTBALL,  BASEBALL AND BASKETBALL
567: #if ($sport.enumCode == 0 || $sport.enumCode == 1 || $sport.enumCode == 2)
568: 	
569: <div class="stats-tabs-secondary clearfix">
570: <ul class="clearfix">
571: 
572: #if ($sport.enumCode == 0) ## Football
573: 
574: #if ($activePos == "qb")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=qb">Passing</a></li>
575: 
576: #if ($activePos == "rb")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=rb">Rushing</a></li>
577: 
578: #if ($activePos == "wr")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=wr">Receiving</a></li>
579: 
580: #if ($activePos == "k")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=k">Kicking</a></li>
581: 
582: #if ($activePos == "p")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=p">Punting</a></li>
583: 
584: #if ($activePos == "kr")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=kr">Returns</a></li>
585: 
586: #if ($activePos == "d")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=d">#if ($locale == "en_us")Defense #elseif ($locale == "en_gb") Defence #end</a></li>
587: 
588: #elseif ($sport.enumCode == 1) ## Baseball
589: 
590: #if ($activePos == "h")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=h">Hitting</a></li>
591: 
592: #if ($activePos == "p")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=p">Pitching</a></li>
593: 
594: #if ($activePos == "f")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=f">Fielding</a></li>
595: 
596: #elseif ($sport.enumCode == 2) ## Basketball
597: 
598: #if ($activePos == "sh")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=sh">Shooting per game</a></li>
599: 
600: #if ($activePos == "st")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=st">Shooting</a></li>
601: 
602: #if ($activePos == "bc")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=bc">Ball control per game</a></li>
603: 
604: #if ($activePos == "bt")<li class="active">#else <li> #end<a href="${bioURL}?view=splits&pos=bt">Ball control</a></li>
605: 
606: #end
607: </ul>
608: </div> ## stats-tabs-secondary
609: #end ## sport check for secondary tabs
610: 	
611: #if ($sport.enumCode == 0) ## Football
612: 
613: <div class="sub-tab-panels">
614: 	#splitsData("qb") ## PASSING
615: 	#splitsData("rb") ## RUSHING
616: 	#splitsData("wr") ## RECEIVING
617: 	#splitsData("k") ## KICKING
618: 	#splitsData("p") ## PUNTING
619: 	#splitsData("kr") ## RETURNS
620: 	#splitsData("d") ## DEFENSE
621: </div>
622: 	
623: #elseif ($sport.enumCode == 1) ## Baseball
624: 
625: <div class="sub-tab-panels">
626: 	#splitsData("h") ## HITTING
627: 	#splitsData("p") ## PITCHING
628: 	#splitsData("f") ## FIELDING
629: </div>
630: 	
631: #elseif ($sport.enumCode == 2) ## Basketball
632: 	
633: <div class="sub-tab-panels">
634: 	#splitsData("sh") ## SHOOTING PER GAME
635: 	#splitsData("st") ## SHOOTING
636: 	#splitsData("bc") ## BALL CONTROL PER GAME
637: 	#splitsData("bt") ## BALL CONTROL
638: </div>
639: 
640: #else
641: 	
642: 	#splitsData($pos)
643: 	
644: #end
645: 
646: </div> ## stats-wrapper
647: </div> ## tab-content
648: ## SPLITS
649: 
650: #end ## MOBILE / DESKTOP STATS
651: 
652: #else
653: ## BIO
654: 
655: ## CHANGES FOR STATS
656: 
657: ## HACK TO GET STATS URL FROM RENDERER... NEEDS SERVER CHANGE
658: #set ($bioObject = $page.getDataAsObject())
659: #set ($statsURL = $bioObject.statsURL)
660: ## END OF HACK
661: 
662: #if ($statsURL.length() > 0)
663:   $website.includeAgain("${statsURL}?tmpl=bio-stats-template")
664:   ## various settings to get the variables set
665:   #set ($events = $request.getAttribute("bio_events"))
666:   #set ($labels = $request.getAttribute("bio_labels"))
667:   #set ($briefs = $request.getAttribute("bio_briefs"))
668:   #set ($gamelogs = $request.getAttribute("bio_gamelogs"))
669:   #set ($splits = $request.getAttribute("bio_splits"))
670:   #set ($statPosition = $request.getAttribute("bio_position"))
671:   #set ($positions = $request.getAttribute("bio_positions"))
672:   #set ($playerId = $request.getAttribute("bio_player_id"))
673:   #set ($highlights = $request.getAttribute("bio_highlights"))
674:   #set ($formats = $request.getAttribute("bio_formats"))
675: #end
676: 
677: ## END CHANGES FOR STATS
678: 
679: #set ($pos = "")
680: #set ($pos = $attributes.get("position"))
681: #set ($pos = $statPosition)
682: #set ($pos = $pos.toLowerCase())
683: #set ($posVec = $pos.split("/"))
684: #set ($pos = $posVec[0])
685: #set ($pos = $positions.get($pos))
686: #set ($highlights = $highlights.get($pos))
687: 
688: #set ($showHighlights = true)
689: #if ($options.get("bio_show_highlights") && $options.get("bio_show_highlights") == false)
690: 	#set ($showHighlights = false)
691: #end
692: 
693: #set ($labels = $labels.get($pos))
694: #set ($briefs = $briefs.get($pos))
695: #set ($gamelogs = $gamelogs.get($pos))
696: #set ($stats = $splits.overall)
697: #set ($hasEvents = $events.size() > 0)
698: #set ($hasSynopsis = $synopsis.length() > 1 && $synopsis.indexOf("<center>") == -1)
699: #set ($htmlStatsURL = "${page.url}-stats")
700: #set ($hasHTMLStats = $website.exists($htmlStatsURL))
701: #set ($bioBriefURL = "${page.url}-brief")
702: #set ($hasBioBrief = $website.exists("$bioBriefURL"))
703: #set ($showRoster = ($page.contentType == "loki/bio" && $page.headlinesFeatured.size() > 0) || ($page.contentType == "loki/bio-network" && $page.sectionPage.children.size() > 1))
704: #if ($options.get("bio_hide_roster") == true)
705: 	#set ($showRoster = false)
706: #end
707: 
708: ## Always default to the bio page if available
709: #set ($view = "bio")
710: 
711: #if ($hasSynopsis || $hasBioBrief)
712: 	#set ($view = "bio")
713: #elseif ($hasEvents)
714: 	#set ($view = "profile")
715: #elseif ($hasHTMLStats)
716: 	#set ($view = "htmlstats")
717: #else
718: 	#set ($view = "")
719: #end
720: 
721: #if ($options.get("bio_default_view").length() > 0)
722: 	#set ($checkView = $options.get("bio_default_view"))
723: #end
724: 
725: #if ($request.getParameter("view"))
726: 	#set ($checkView = $request.getParameter("view"))
727: #end
728: 
729: #if ($checkView == "profile" && $hasEvents)
730: 	#set ($view = "profile")
731: #elseif ($checkView == "bio" && ($hasSynopsis || $hasBioBrief))
732: 	#set ($view = "bio")
733: #elseif ($checkView == "gamelog" && $hasEvents)
734: 	#set ($view = "gamelog")
735: #elseif ($checkView == "splits" && $hasEvents)
736: 	#set ($view = "splits")
737: #elseif ($checkView == "htmlstats" && $hasHTMLStats)
738: 	#set ($view = "htmlstats")
739: #end
740: 
741: #if ($attributes.get("full_name"))
742: 	#set ($fullName = $attributes.get("full_name"))
743: #else
744: 	#set ($firstName = $!attributes.get("first_name"))
745: 	#set ($lastName = $!attributes.get("last_name"))
746: 	#set ($fullName = "${firstName} ${lastName}")
747: #end
748: 
749: #macro (printHeadshot $width $height)
750: 	#if ($headshot.url)
751: 		<img src="$headshot.url?max_width=$!width&max_height=$!height" alt="$fullName" title="$fullName" class="bio-headshot" />
752: 	#else
753: 		#if ($website.exists("/images/setup/headshot_default.jpg"))
754: 			<img src="/images/setup/headshot_default.jpg?max_width=$!width&max_height=$!height" alt="$fullName" title="$fullName" class="bio-headshot" />
755: 		#else
756: 			<img src="/info/images/default_headshot.jpg?max_width=$!width&max_height=$!height" alt="$fullName" title="$fullName" class="bio-headshot" />
757: 		#end
758: 	#end
759: #end
760: 
761: #if ($isMobile)
762: 
763: #set ($hasBioTab = false)
764: #if ($hasSynopsis || $hasBioBrief)
765: 	#set ($hasBioTab = true)
766: #end
767: 
768: #set ($hasProfileTab = false)
769: #if (($highlights && $showHighlights) || $events.size() > 0 || $website.exists("$statsURL/../players"))
770: 	#set ($hasProfileTab = true)
771: #end
772: 
773: <script type="text/javascript">
774: 	window.mobileConf = {
775: 		page : 'bios',
776: 		pageParams : {
777: 			view : '$!view'
778: 		}
779: 	}
780: </script>
781: 
782: <div class="bios">
783: 	<div class="profile">
784: 		<div class="images">
785: 			<div class="photo">
786: 				#printHeadshot(81, 116)
787: 			</div>				
788: 			#if ($attributes.get("number"))	<div class="number"> $!attributes.get("number") </div> #end
789: 		</div>
790: 		<div class="texts">
791: 			<div class="name">$!attributes.get("first_name") $!attributes.get("last_name")</div>
792: 			<div class="data">
793: 				#foreach ($field in $fields)
794: 					#if (! $field.key.startsWith("custom"))
795: 						#if ($attributes.get($field.key).length() > 0 && ($field.key != "first_name" && $field.key != "last_name" && $field.key != "number" && $field.key != "full_name"))
796: 
797: 							#if ($field.key == "phone1" || $field.key == "phone2")
798: 								Phone: $!attributes.get($field.key) <br />
799: 							#elseif ($field.key == "email_address")
800: 								#set ($emailAdd = $attributes.get($field.key))
801: 								Email: <a href="mailto:${emailAdd}">$emailAdd</a> <br />
802: 							#else
803: 								$field.value: $!attributes.get($field.key) <br />
804: 							#end
805: 
806: 							#set ($counter = $counter + 1)
807: 						#end
808: 					#end
809: 				#end
810: 					
811: 				#foreach ($i in [1..10])
812: 					#set ($customKey = "bio_custom${i}")
813: 					#if ($options.get($customKey).length() > 0 && $attributes.get("custom${i}"))
814: 						$options.get($customKey): </td><td class="val">$!attributes.get("custom${i}") <br />
815: 						#set ($counter = $counter + 1)
816: 					#end
817: 				#end
818: 				
819: 			</div>
820: 		</div>
821: 	</div>	
822: 
823: 	#if ($hasBioTab || $hasProfileTab)
824: 	<div class="details mobile-tabs mobile-stats" id="mobile-bios-tabs-container">
825: 		<ul class="mobile-bios-tabs">
826: 			#if ($hasBioTab)
827: 				<li><a data-view="bio" href="#tab-bios">Bio</a></li>
828: 			#end
829: 			#if ($hasProfileTab)
830: 				<li><a data-view="profile" href="#tab-profile">Profile</a></li>
831: 			#end
832: 			#if ($hasEvents)
833: 				<li><a data-view="gamelog" href="#tab-gamelog">Game Log</a></li>
834: 				<li><a data-view="splits" href="#tab-splits">Splits</a></li>
835: 			#end
836: 		</ul>
837: 		
838: 		#if ($hasBioTab)
839: 		<div id="tab-bios">
840: 			#if ($hasSynopsis)
841: 				$synopsis
842: 			#elseif ($hasBioBrief)
843: 				<p>$website.include("$bioBriefURL")</p>
844: 			#end
845: 		</div>
846: 		#end
847: 		
848: 		#if ($hasProfileTab)
849: 		#set ($cellWidth = $tool.math.toInteger($tool.math.div(100, $highlights.size())))
850: 			
851: 		<div id="tab-profile">
852: 			## HIGHLIGHTS
853: 			#if ($highlights && $showHighlights)
854: 				<div class="bios-stat-wrapper">
855: 					<h4>Highlights</h4>
856: 					<table width="100%"><tr>
857: 					#foreach ($highlight in $highlights.keySet())
858: 						<th #if (! $isMobile) width="18%" #else width="${cellWidth}%" #end>$!highlights.get($highlight)</th>
859: 					#end
860: 					</tr><tr>
861: 					#foreach ($highlight in $highlights.keySet())
862: 						<td>
863: 						#set ($value = "-")
864: 						#set ($value = $formatter.formatNumber($stats.get($highlight), $formats.get($highlight)))
865: 						#if ($value.length() > 0)
866: 							<span class="value">$value</span>
867: 						#else
868: 							<span class="value">-</span>
869: 						#end	
870: 						</td>
871: 					#end
872: 					</tr></table>
873: 				</div>
874: 			#end
875: 			
876: 			## RECENT GAMES
877: 			#if ($events.size() > 0)
878: 			<div class="bios-stat-wrapper">
879: 				##<h4>Recent Games</h4>
880: 				#printRecentGames()
881: 			</div>
882: 			#end
883: 			
884: 			<div class="bios-stat-wrapper">
885: 				$website.include("$statsURL/../players?tmpl=stats-bios-rank-template&rank=${playerId}&pos=${pos}")
886: 			</div>
887: 			
888: 		</div>
889: 		#end
890: 		
891: 		## STATS TABS
892: 		#if ($hasEvents)
893: 			$website.includeAgain("${statsURL}?tmpl=bio-template&stats=1&biourl=${tool.esc.url($page.url)}&view=${view}&pos=${request.getParameter('pos')}")
894: 			
895: 			<div id="tab-splits"></div>
896: 			
897: 		#end
898: 		
899: 	</div>
900: 	#end
901: </div>   
902:    
903:    
904: #else
905: ## NOT MOBILE
906: 
907: <head>
908: 	<title>$fullName #if ($attributes.get("team")) | $attributes.get("team")#end</title>
909: 	<link rel="stylesheet" type="text/css" href="/info/bio-styles.css" />
910: </head>
911: 
912: ## FULL ROSTER
913: <div class="bio-wrap clearfix">
914: 
915: <div class="head clearfix">
916: 
917: <div class="bio-title">#if ($attributes.get("number"))<span class="number">$!attributes.get("number") - #end</span><span class="name">$fullName</span></div>
918: 
919: <div class="about">
920: 
921: <div class="clearfix">
922: 
923: #printHeadshot(150, 200)
924: 
925: #set ($counter = 0)
926: <table cellpadding="5" cellspacing="5" border="0">
927: 
928: #foreach ($i in [1..10])
929: 	#set ($stickyKey = "bio_custom${i}_sticky")
930: 	#if ($options.get($stickyKey).length() > 0 && $attributes.get("custom${i}").length() > 0)
931: 		<tr><td class="lbl">$options.get($stickyKey): </td><td class="val">$!attributes.get("custom${i}")</td></tr>
932: 		#set ($counter = $counter + 1)
933: 	#end
934: #end
935: 
936: #foreach ($field in $fields)
937: 	#if (! $field.key.startsWith("custom"))
938: 		#if ($attributes.get($field.key).length() > 0 && ($field.key != "first_name" && $field.key != "last_name" && $field.key != "number" && $field.key != "full_name"))
939: 
940: 			#if ($field.key == "phone1" || $field.key == "phone2")
941: 				<tr><td class="lbl">Phone: </td><td class="val">$!attributes.get($field.key)</td></tr>
942: 			#elseif ($field.key == "email_address")
943: 				#set ($emailAdd = $attributes.get($field.key))
944: 				<tr><td class="lbl">Email: </td><td class="val"><a href="mailto:${emailAdd}">$emailAdd</a></td></tr>
945: 			#else
946: 				<tr><td class="lbl">$field.value: </td><td class="val">$!attributes.get($field.key)</td></tr>
947: 			#end
948: 
949: 			#set ($counter = $counter + 1)
950: 		#end
951: 	#end
952: #end
953: 
954: #foreach ($i in [1..10])
955: 	#set ($customKey = "bio_custom${i}")
956: 	#if ($options.get($customKey).length() > 0 && $attributes.get("custom${i}"))
957: 		<tr><td class="lbl">$options.get($customKey): </td><td class="val">$!attributes.get("custom${i}")</td></tr>
958: 		#set ($counter = $counter + 1)
959: 	#end
960: #end
961: 
962: </table>
963: 
964: </div> ## clearfix
965: </div> ## ends about
966: 
967: #if ($highlights && $showHighlights)
968: <div class="headstats">
969: 	#foreach ($highlight in $highlights.keySet())
970: 		<div class="hst">
971: 		<span class="title" title="$!highlights.get($highlight)">$!highlights.get($highlight)</span>
972: 		#set ($value = "-")
973: 		#set ($value = $formatter.formatNumber($stats.get($highlight), $formats.get($highlight)))
974: 		#if ($value.length() > 0)
975: 			<span class="value">$value</span>
976: 		#else
977: 			<span class="value">-</span>
978: 		#end
979: 		</div>
980: 	#end
981: </div>
982: #end ## if-highlights
983: 
984: </div> ## ends head
985: 
986: #if ($hasSynopsis || $hasBioBrief || $hasEvents || $hasHTMLStats || $showRoster)
987: <div class="stats-tabs clearfix">
988: 	#if (($hasSynopsis || $hasBioBrief || $hasEvents || $hasHTMLStats) && $view.length() > 0)
989: 	<ul class="clearfix">
990: 		#if ($hasSynopsis || $hasBioBrief)
991: 			#if ($view == "bio")<li class="active">#else<li>#end<a href="${page.url}?view=bio">Bio</a></li>
992: 		#end
993: 		
994: 		#if ($hasEvents)
995: 			#if ($view == "profile")<li class="active">#else<li>#end<a href="${page.url}?view=profile">Player Profile</a></li>
996: 			#if ($view == "gamelog")<li class="active">#else<li>#end<a href="${page.url}?view=gamelog">Game Log</a></li>
997: 			#if ($view == "splits")<li class="active">#else<li>#end<a href="${page.url}?view=splits">Split Stats</a></li>
998: 		#end
999: 
1000: 		#if ($hasHTMLStats)
1001: 			#if ($view == "htmlstats")<li class="active">#else<li>#end<a href="${page.url}?view=htmlstats">HTML Stats</a></li>
1002: 		#end
1003: 	</ul>
1004: 	#end
1005: 	#if ($showRoster)
1006: 		#if ($page.contentType == "loki/bio")
1007: 			#set ($headlinesFeaturedSize = 0)
1008: 			#foreach ($featuredPage in $page.headlinesFeatured)
1009: 				#if ($featuredPage.contentType == "loki/headlines")
1010: 					#set ($headlinesFeaturedSize = $headlinesFeaturedSize + 1)
1011: 				#end
1012: 			#end
1013: 			#if ($headlinesFeaturedSize > 0)
1014: 				<select class="roster-select-list">
1015: 					<option selected="selected" class="bold">Related Bios</option>
1016:     			#foreach ($featuredPage in $page.headlinesFeatured)
1017:     				#if ($featuredPage.contentType == "loki/headlines")
1018:     					$website.includeAgain("${featuredPage.url}?tmpl=roster-list-template&current_url=${page.url}")
1019:     				#end
1020: 				#end
1021: 				</select>
1022: 			#end
1023: 		#elseif ($page.contentType == "loki/bio-network")
1024: 			#set ($relatedPlayers = $page.sectionPage.children)
1025: 			#set ($teamNames = {})
1026: 			#foreach ($relatedPlayer in $relatedPlayers)
1027: 				#if ($relatedPlayer.contentType == "loki/bio-network")
1028: 					#set ($relatedPlayerObj = $relatedPlayer.getDataAsObject().getAttributes())
1029: 					## <span class="none relatedplayeratt">$relatedPlayerObj</span>
1030: 					#set ($teamName = $relatedPlayerObj.get("team"))
1031: 					#if ($teamName.length() > 0)
1032:     					#if (!$teamNames.containsValue($teamName))
1033:     						$!teamNames.put($tool.math.add($teamNames.size(), 1), $teamName)
1034:     					#end
1035: 					#end
1036: 				#end
1037: 			#end
1038: 			##<span class="none teamnames">$teamNames</span>
1039: 			<select class="roster-select-list">
1040: 			#foreach ($i in [1..$teamNames.size()])
1041: 				#if ($teamNames.size() > 1)
1042: 					<optgroup label="$teamNames.get($i)">
1043: 				#end
1044: 				
1045: 				#foreach ($relatedPlayer in $relatedPlayers)
1046: 					#if ($relatedPlayer.contentType == "loki/bio-network")
1047: 						#set ($relatedPlayerObj = $relatedPlayer.getDataAsObject().getAttributes())
1048: 						#set ($teamName = $relatedPlayerObj.get("team"))
1049: 						#if ($teamName.length() > 0 && $teamName == $teamNames.get($i))
1050: 							#set ($playerFirstName = $relatedPlayerObj.get("first_name"))
1051: 							#set ($playerLastName = $relatedPlayerObj.get("last_name"))
1052: 							#if ($page.url == $relatedPlayer.url)
1053: 								<option value="$relatedPlayer.url" selected="selected" class="bold">${playerFirstName} ${playerLastName}</option>
1054: 							#else
1055: 								<option value="$relatedPlayer.url">${playerFirstName} ${playerLastName}</option>
1056: 							#end
1057: 						#end
1058: 					#end
1059: 				#end
1060: 				
1061: 				#if ($teamNames.size() > 1)
1062: 					</optgroup>
1063: 				#end
1064: 			#end
1065: 			</select>
1066: 		#end
1067: 	#end
1068: </div>
1069: #end
1070: 
1071: #if ($hasSynopsis || $hasBioBrief || $hasEvents || $hasHTMLStats)
1072: 	<div class="tab-content-panels">
1073: #end
1074: 
1075: ## BIO TAB
1076: #if ($hasSynopsis || $hasBioBrief)
1077: 
1078: #set ($class = "tab-content clearfix")
1079: #if ($view == "bio")
1080: 	#set ($class = "tab-content clearfix active")
1081: #end
1082: <div class="${class}">
1083: 
1084: <div class="synopsis clearfix">
1085: #if ($hasSynopsis)
1086: 	$synopsis
1087: #elseif ($hasBioBrief)
1088: 	$website.include("$bioBriefURL")
1089: #end
1090: </div>
1091: 
1092: </div> ## tab-content
1093: #end ## BIO TAB ENDS
1094: 
1095: ## STATS TABS
1096: #if ($hasEvents)
1097:   $website.includeAgain("${statsURL}?tmpl=bio-template&stats=1&biourl=${tool.esc.url($page.url)}&view=${view}&pos=${request.getParameter('pos')}")
1098: #end
1099: 
1100: ## HTML TAB
1101: #if ($hasHTMLStats)
1102: 
1103: #set ($class = "tab-content clearfix")
1104: #if ($view == "htmlstats")
1105: 	#set ($class = "tab-content clearfix active")
1106: #end
1107: <div class="${class}">
1108: 	<a href="${htmlStatsURL}" class="bio-htmlstats-identifier">Click to view HTML Stats</a>
1109: </div>
1110: 
1111: #end
1112: 
1113: #if ($hasSynopsis || $hasBioBrief || $hasEvents || $hasHTMLStats)
1114: 	</div>
1115: #end
1116: 
1117: </div> ## ends bio-wrap
1118: 
1119: #if ($request.getAttribute("bioScriptCalled"))
1120:   #set ($scriptCalled = true)
1121: #else
1122:   #set ($scriptCalled = false)
1123: #end
1124: 
1125: #if (!$scriptCalled)
1126: 	
1127: $!request.setAttribute("bioScriptCalled", true)
1128: <script type="text/javascript" src="$website.cdn("/info/jquery.address-1.5.min.js")"></script>
1129: <script type="text/javascript">
1130: 
1131: jQuery.address.strict(false).state('${page.url}').init(function() {
1132: 	$('.bio-wrap .stats-tabs a').address();
1133: 	$('.bio-wrap .stats-tabs-secondary a').address();
1134: });
1135: 
1136: $(function() {
1137: 
1138: $('.bio-wrap .stats-tabs li').click(function(e) {
1139: 	e.preventDefault();
1140: 	if (!$(this).hasClass('active')) {
1141: 		$(this).addClass('active').siblings().removeClass('active');
1142: 		$(this).parent().parent('.stats-tabs').next('.tab-content-panels').children('.tab-content').removeClass('active').eq($(this).index()).addClass('active');
1143: 	}
1144: });
1145: 
1146: $('.bio-wrap .stats-tabs-secondary li').click(function(e) {
1147: 	e.preventDefault();
1148: 	if (!$(this).hasClass('active')) {
1149: 		$(this).addClass('active').siblings().removeClass('active');
1150: 		$(this).parent().parent('.stats-tabs-secondary').next('.sub-tab-panels').children('.sub-tab-content').removeClass('active').eq($(this).index()).addClass('active');
1151: 	}
1152: });
1153: 
1154: #if ($showRoster)
1155: 	$('.bio-wrap .roster-select-list').change(function() {
1156: 		window.location.href = $(this).val();
1157: 	});
1158: #end
1159: 
1160: #if ($hasHTMLStats)
1161: 	$('.bio-htmlstats-identifier').each(function() {
1162: 		var targetElement = $(this);
1163: 		jQuery.get($(this).attr('href'), function(data) {
1164: 			var htmlStats = $(data).find('center').first();
1165: 			htmlStats.add(htmlStats.siblings('center'));
1166: 			if (htmlStats.children().length > 0) {
1167: 				targetElement.replaceWith(htmlStats);
1168: 			}
1169: 		});
1170: 	});
1171: #end
1172: 
1173: });
1174: </script>
1175: #end
1176: 
1177: #end ## MOBILE CHECK
1178: #end ## STATS PARAMETER
1179: 
1180: $wiki

View: Mobile | Desktop