-
There was a problem with a Velocity script Page /rich-template Error Error invoking method 'get(java.lang.Integer)' in java.util.ArrayList at l929hzxa0gw96puh/rich-template[line 386, column 66] Page source: 1: #set ($showMobile = false) 2: #if ($request.getParameter('showMobile').length() > 0) 3: #set ($showMobile = true) 4: #end 5: 6: ## Front Row legacy code for verions prior to 2.3 7: #if ($showMobile) 8: ##MOBILE TEMPLATE 9: $website.include("options") 10: #set ($options = $request.getAttribute("options")) 11: 12: ## DEFAULT VALUES 13: #set ($showDate = true) 14: #set ($facebookLike = false) 15: #set ($showThumb = true) 16: #set ($showCaption = true) 17: #set ($thumbWidth = 150) 18: 19: #set ($showDate = $options.get("article_show_date")) 20: #set ($facebookLike = $options.get("article_facebook_like")) 21: #set ($showThumb = $options.get("article_show_thumb")) 22: #set ($showCaption = $options.get("article_show_caption")) 23: #set ($thumbWidth = $options.get("article_mobile_thumb_width")) 24: 25: ## ADD THIS 26: #if ($page.date && $facebookLike == true) 27: 28: #end 29: 30: ## STYLES 31: <style> 32: .mobile-article iframe { max-width:100% } 33: </style> 34: 35: <div class="mobile-article"> 36: ## PAGE TITLE 37: <h1>$!page.title</h1> 38: 39: #if ($showDate == true and $page.date) 40: <span class="page-date">$formatter.formatLongDate($!page.date)</span> 41: #end 42: 43: <div class="clear"></div> 44: 45: #if ($page.thumbnailURL && $showThumb == true) 46: <div class="thumb"> 47: <img src="$page.thumbnailURL" alt="$!page.thumbnailPage.altText" /> 48: #set ($buyPhotoURL = "") 49: #set ($buyPhotoURL = $website.storeURL($page.thumbnailPage)) 50: #if ($page.thumbnailPage.buyURL && $buyPhotoURL.length() > 0) 51: <a href="$buyPhotoURL" class="buynow-button" title="Buy Now"></a> 52: #end 53: #if ($showCaption == true && $page.thumbnailPage.title.length() > 0) 54: <h5 class="thumb-title">$!page.thumbnailPage.title</h5> 55: #end 56: </div> ## ends thumb 57: #end 58: 59: ## PAGE BODY 60: $body.replace('src="//www.youtube.com', 'src="https://www.youtube.com')) 61: 62: <div class="clear"></div> 63: 64: #if ($facebookLike == true) 65: ## FACEBOOK LIKE 66: ##<div class="mobile-facebook-like"> 67: ##<fb:like href="http://${request.serverName}${page.url}" show_faces="false" width="300" height="30" /> 68: ##</div> 69: #end 70: 71: #if ($wiki.valid()) 72: <div class="wiki">$wiki</div> 73: #end 74: </div> 75: $wiki 76: 77: #else 78: 79: ####################################### 80: ## SUPPORT RESPONSIVE LAYOUT ## 81: ####################################### 82: 83: #set ($ajax = false) 84: #if ($request.getParameter("ajax") == true) 85: #set ($ajax = true) 86: $website.decorate("") 87: #end 88: 89: #set ($isMobile = false) 90: #if ($browser.getIphone() || $browser.getMobile()) 91: #set ($isMobile = true) 92: #end 93: 94: #set ($isFrontrow = false) 95: #if ($request.getParameter("frontrow") == true) 96: #set ($isFrontrow = true) 97: #end 98: 99: ## DEFAULT VALUES 100: #set ($layoutStyle = "standard") 101: #set ($showDate = true) 102: #set ($facebookLike = true) 103: #set ($tweetButton = true) 104: #set ($showBannerScore = true) 105: #set ($showThumb = true) 106: #set ($showVideo = true) 107: #set ($videoOverlay = true) 108: #set ($showBoxscore = true) 109: #set ($showGallery = true) 110: #set ($showCaption = true) 111: #set ($showOnlyBody = false) 112: #set ($showRelatedLinks = true) 113: #set ($headlineStyle = "h1") 114: #set ($thumbWidth = 450) 115: #set ($infiniteScroll = false) 116: #set ($shareButtons = true) 117: 118: ## PICK UP OPTIONS 119: $website.include("options") 120: #set ($options = $request.getAttribute("options")) 121: 122: ## SET VARIABLES FROM OPTIONS 123: #if ($options.get("article_layout_style") == "modern") #set ($layoutStyle = "modern") #end 124: #if ($options.get("article_layout_style") == "classic") #set ($layoutStyle = "classic") #end 125: #if ($options.get("article_layout_style") == "modern card") #set ($layoutStyle = "modern") #end 126: #if ($options.get("article_show_date") == false) #set ($showDate = false) #end 127: #if ($options.get("article_facebook_like") == false) #set ($facebookLike = false) #end 128: #if ($options.get("article_tweet_button") == false) #set ($tweetButton = false) #end 129: #if ($options.get("article_banner_score") == false) #set ($showBannerScore = false) #end 130: #if ($options.get("article_show_thumb") == false) 131: #set ($showThumb = false) 132: #set ($showVideo = false) 133: #end 134: #if ($options.get("article_show_video") == false) #set ($showVideo = false) #end 135: #if ($options.get("article_video_overlay") == false || $isMobile) #set ($videoOverlay = false) #end 136: #if ($options.get("article_show_boxscore") == false) #set ($showBoxscore = false) #end 137: #if ($options.get("article_show_gallery") == false) #set ($showGallery = false) #end 138: #if ($options.get("article_show_caption") == false) #set ($showCaption = false) #end 139: #if ($options.get("article_show_body") == true) #set ($showOnlyBody = true) #end 140: #if ($tool.math.toInteger($options.get("article_thumb_width"))) #set ($thumbWidth = $tool.math.toInteger($options.get("article_thumb_width"))) #end 141: #set ($headlineStyle = $options.get("article_headline_style")) 142: 143: ## GRAB RELATED ARTICLES 144: #set ($relatedArticles = []) 145: #set ($relatedHeadline = "") 146: #foreach ($headline in $page.headlinesFeatured) 147: #if ($headline.name == "news" && $relatedHeadline.length() == 0) 148: #set ($relatedHeadline = $headline.url) 149: #foreach ($article in $headline.allHeadlines) 150: #if ($article.contentType == "loki/tinymce" && ($article.date && $article.title.length() > 0)) 151: #set ($bool = $relatedArticles.add($article)) 152: #end 153: #end 154: #end 155: #end 156: 157: ## ONLY TURN ON INFINITY SCROLL WHEN THE PAGE IS A STANDALONE PAGE, AND RELATED ARTICLES FOUND IN ABOVE BLOCK 158: #if ($options.get("article_infinite_scroll") == true && !$website.isIncluded() && $relatedArticles.size() > 0) 159: #set ($infiniteScroll = true) 160: #set ($layoutStyle = "modern") 161: #end 162: 163: ## IF MOBILE TURN OFF INFINITY SCROLL 164: #if ($isMobile) 165: #set ($infiniteScroll = false) 166: #set ($layoutStyle = "classic") 167: #end 168: 169: ## IF FRONTROW TURN OFF DECORATOR, SHARE BUTTONS AND INFINITY SCROLL 170: #if ($isFrontrow) 171: $website.decorate("") 172: #set ($infiniteScroll = false) 173: #set ($shareButtons = false) 174: #end 175: 176: ## OVERRIDE OPTIONS FOR PRINTER FRIENDLY VIEW 177: #if ($request.getParameter("dec") == "printer-decorator") 178: #set ($infiniteScroll = false) 179: #set ($layoutStyle = "standard") 180: #set ($thumbWidth = 450) 181: #set ($showRelatedLinks = false) 182: #set ($facebookLike = false) 183: #set ($tweetButton = false) 184: #end 185: 186: ## WHEN THE FOLLOWING ATTRIBUTE IS SET, TURN OFF THE RELATED LINKS 187: #if ($request.getAttribute("disable_related_links") == "y") 188: #set ($showRelatedLinks = false) 189: #end 190: 191: #if ($showOnlyBody == true) 192: 193: $body 194: 195: #else 196: 197: #set ($relatedPages = $page.relatedInSchedule) 198: #set ($hasSidebar = false) 199: #set ($boxscores = []) 200: #set ($relatedVideo = "") 201: #set ($relatedVideoType = "") 202: #set ($relatedGallery = "") 203: 204: #if ($relatedPages.size() > 0) 205: #foreach ($related in $relatedPages) 206: #if ($showBoxscore) 207: #if ($related.contentType.startsWith("statcrew") && $related.mapType == "BS" && $website.exists($related.url)) 208: #set ($r = $boxscores.add($related.url)) 209: #set ($hasSidebar = true) 210: #end 211: #end 212: 213: #if ($showVideo) 214: #if (($related.contentType == "video/x-flv" || $related.contentType == "loki/video" || $related.contentType == "loki/youtube") && $related.id != $page.id && $website.exists($related.url) && $relatedVideo.length() == 0) 215: #if ($related.contentType == "video/x-flv") 216: #set ($relatedVideo = "${related.url}?dec=") 217: #set ($relatedVideoType = "video/x-flv") 218: #elseif ($related.contentType == "loki/video") 219: #set ($relatedVideo = "${related.url}?dec=") 220: #set ($relatedVideoType = "video/mp4") 221: #else 222: #set ($relatedVideo = "${related.dataAsString}") 223: #set ($relatedVideoType = "video/youtube") 224: #end 225: 226: ## VIDEOJS PLAYER CSS 227: $website.addCss($website.cdn("/info/videojs/css/video-js.min.css")) 228: #end 229: #end 230: 231: #if ($showGallery) 232: #if ($related.mapType == "GA" && !$website.isExternalLink($related.url) && $website.exists($related.url)) 233: #set ($relatedGallery = $related) 234: #end 235: #end 236: #end 237: #end 238: 239: ## MACROS 240: #macro (printSidebar) 241: #if ($hasSidebar) 242: <div class="sidebar"> 243: ## GLOBAL ADS SERVER 244: #if ($website.ads.isAdvertisingEnabled('ARTICLES')) 245: $website.includeAgain("global-adserver-slots?adSlot=articles_sidebar") 246: #end 247: 248: #foreach ($boxscore in $boxscores) 249: #set ($includeURL = "${boxscore}?tmpl=brief-stats-template") 250: #if ($showBannerScore) 251: #set ($includeURL = "${includeURL}&showLinescore=false") 252: #end 253: #if ($foreach.count > 1) 254: <br /> 255: #end 256: <div class="widget"> 257: $website.includeAgain("${includeURL}") 258: <a href="${boxscore}" class="more">full stats</a> 259: </div> 260: #end 261: </div> 262: #end 263: #end ## printSidebar 264: 265: ## PAGE TITLE 266: #macro (printTitle) 267: #if ($page.title.length() > 0) 268: #if ($headlineStyle == "none") 269: <div class="article-title">$!page.title</div> 270: #else 271: <${headlineStyle} class="article-title">$!page.title</${headlineStyle}> 272: #end 273: #end 274: #end ## printTitle 275: 276: ## PAGE DATE 277: #macro (printDate) 278: #if ($page.date && $showDate) 279: <div class="article-date"> 280: <div class="date">Posted: $formatter.formatDate($page.date, "MMM dd, yyyy")</div> 281: 282: #if ($shareButtons && ($facebookLike || $tweetButton)) 283: <div class="like-buttons" data-module="share-buttons"> 284: #if ($facebookLike) 285: <div class="fb-like-btn"><a class="addthis_button_facebook_like" fb:like:layout="button_count"></a></div> 286: #end 287: #if ($tweetButton) 288: <div class="tweet-btn"><a class="addthis_button_tweet"></a></div> 289: #end 290: </div> 291: #end 292: </div> 293: #end 294: #end ## printDate 295: 296: ## ARTICLE THUMBNAIL 297: #macro (printThumbnail) 298: #if (!$videoOverlay && $relatedVideo.length() > 0) 299: <div class="article-image" style="width:${thumbWidth}px"> 300: <div data-module="init-video" data-file="$relatedVideo" data-type="$relatedVideoType" data-image="$!page.thumbnailURL"></div> 301: </div> 302: #else 303: #if ($showThumb && $page.thumbnailURL) 304: #set ($buyPhotoURL = "") 305: #set ($buyPhotoURL = $website.storeURL($page.thumbnailPage)) 306: 307: #set ($thumbSrc = $page.thumbnailURL) 308: #if ($layoutStyle == "standard" || ($layoutStyle == "classic" && !$hasSidebar)) 309: #set ($thumbSrc = "${thumbSrc}?max_width=${thumbWidth}") 310: #end 311: 312: <div class="article-image"> 313: <div class="image"> 314: 315: #if ($page.thumbnailPage.altText.length() > 0) 316: <img src="$thumbSrc" alt="$page.thumbnailPage.altText" /> 317: #else 318: <img src="$thumbSrc" alt="$!page.title" /> 319: #end 320: 321: #if ($page.thumbnailPage.buyURL && $buyPhotoURL.length() > 0) 322: <a href="$buyPhotoURL" class="buynow-btn">Buy Now</a> 323: #end 324: 325: #if ($showCaption == true && $page.thumbnailPage.title.length() > 0) 326: <div class="thumb-caption">$page.thumbnailPage.title</div> 327: #end 328: 329: #if ($relatedVideo.length() > 0) 330: <a href="${relatedVideo}" class="play-btn" data-module="init-video" data-module-binding="always" data-trigger="true" data-overlay="true" data-file="$relatedVideo" data-type="$relatedVideoType">Play Video</a> 331: #end 332: </div> 333: </div> 334: #end 335: #end 336: #end ## printThumbnail 337: 338: ## ARIA LABEL FOR RELATED LINK 339: #macro (printLinkAriaLabel $event $label) 340: #if (!$event) 341: #set ($ariaLabel = $label) 342: #else 343: #set ($ariaLabel = "${event.sport} event: ${formatter.formatDate($event.date, 'MMMM d hh:mm a:')}") 344: #if ($event.neutralSite.length() > 0 || $event.home) 345: #set ($vsOrAt = "vs.") 346: #else 347: #set ($vsOrAt = "at") 348: #end 349: #if ($event.teams.size() > 1) 350: #set ($ariaLabel = "${ariaLabel} ${event.teams.get(0).name} ${vsOrAt} ${event.teams.get(1).name}:") 351: #elseif ($event.teams.size() == 1) 352: #set ($ariaLabel = "${ariaLabel} ${event.teams.get(0).name}:") 353: #end 354: #if ($event.neutralSite.length() > 0) 355: #set ($ariaLabel = "${ariaLabel} @ ${event.neutralSite}:") 356: #end 357: #set ($ariaLabel = "${ariaLabel} ${label}") 358: #end 359: aria-label="$ariaLabel" 360: #end 361: 362: ## RELATED LINKS 363: #macro (printRelatedLinks) 364: #if ($showRelatedLinks && $relatedPages.size() > 0) 365: #set ($printedLinks = {}) 366: #set ($eventLinks = []) 367: #set ($relatedEvents = $page.schedule.getEventsWithLink($page.url)) 368: #if (!$relatedEvents.isEmpty()) 369: #set ($relatedEvent = $relatedEvents[0]) 370: #if (!$relatedEvent.links.isEmpty()) 371: #set ($eventLinks = $relatedEvent.links) 372: #end 373: #end 374: $request.setAttribute("disable_related_links", "y") 375: <div class="related-links" data-module="jscroll" data-momentum="false"> 376: <div> 377: <ul class="clearfix"> 378: #foreach ($related in $relatedPages) 379: #if ($related.id != $page.id) 380: <li> 381: #set ($linkText = $related.mapLabel) 382: #set ($linkUrl = $related.url) 383: #set ($linkMapType = $related.mapType) 384: #set ($linkFound = false) 385: #if (!$relatedEvents.isEmpty()) 386: #set ($link = $eventLinks[0]) 387: #foreach ($l in $eventLinks) 388: #if ($related.url == $l.url) 389: #set ($link = $l) 390: #set ($linkFound = true) 391: #end 392: #end 393: #end 394: #if ($linkFound == true) 395: #set ($linkText = $link.name) 396: #set ($linkUrl = $link.url) 397: #set ($linkMapType = $link.mapType) 398: #end 399: #set ($linkTypeCounter = 1) 400: #set ($linkTypeLabel = $linkText) 401: #if ($printedLinks.containsKey("${$linkText}")) 402: #set ($linkTypeCounter = $printedLinks.get("${linkText}") + 1) 403: #set ($linkTypeLabel = "$linkText${linkTypeCounter}") 404: #end 405: #set ($ignore = $printedLinks.put($linkText, $linkTypeCounter)) 406: 407: <a #printLinkAriaLabel($relatedEvent, $linkTypeLabel) href="$linkUrl" #if ($website.isExternalLink($linkUrl))target="_blank"#end> 408: <span class="gicon-${linkMapType.toLowerCase()}"></span> 409: ${linkText} 410: </a> 411: </li> 412: #end 413: #end 414: </ul> 415: </div> 416: </div> 417: #end 418: #end ## printRelatedLinks 419: 420: #macro (printRelatedArticles) 421: #set ($relatedArticles = $tool.sorter.sort($relatedArticles, "date:desc")) 422: <div class="rel-articles"> 423: <div class="container"> 424: #foreach ($article in $relatedArticles) 425: <div #if ($article.url == $page.url) class="preview active loaded" #else class="preview" #end> 426: <div class="thumb"> 427: #if ($article.thumbnailURL) 428: <img data-src="$article.thumbnailURL?max_width=280&max_height=160&crop=true" alt="$!article.title" class="lazyload" /> 429: #else 430: <img data-src="/images/setup/thumbnail_default.jpg?max_width=280&max_height=160&crop=true" alt="$!article.title" class="lazyload" /> 431: #end 432: </div> 433: <div class="info"> 434: <span class="date">$formatter.formatLongDate($article.date)</span> 435: <a href="$article.url" class="title">$article.title</a> 436: </div> 437: </div> 438: #end 439: </div> 440: </div> 441: #end ## printRelatedArticles 442: 443: #macro (printArticleLayout) 444: 445: #set ($sidebarClass = "no-sidebar") 446: #if ($hasSidebar) 447: #set ($sidebarClass = "has-sidebar") 448: #end 449: 450: <div class="rich-v2 ${layoutStyle} ${sidebarClass} clearfix" data-module="article-rich" data-title="$!page.title" data-url="$page.url"> 451: 452: ## RELATED LINKS 453: #printRelatedLinks 454: 455: ## PAGE TITLE 456: #printTitle 457: 458: ## BANNER SCORE 459: #if ($showBannerScore && $boxscores.size() > 0) 460: #foreach ($boxscore in $boxscores) 461: <div class="banner-score">$website.include("${boxscore}?tmpl=brief-stats-template&showLinescore=true&extended=false")</div> 462: #end 463: #end 464: 465: ## BANNER IMAGE 466: #if ($layoutStyle == "modern") 467: #printThumbnail 468: #end 469: 470: <div class="article-body clearfix"> 471: 472: #if ($layoutStyle == "modern") 473: #if (!$isMobile) 474: #printSidebar 475: #end 476: 477: #elseif ($layoutStyle == "classic") 478: #if (!$isMobile) 479: #printSidebar 480: #end 481: 482: #printThumbnail 483: 484: #elseif ($layoutStyle == "standard") 485: #printThumbnail 486: 487: #if (!$isMobile) 488: #printSidebar 489: #end 490: #end 491: 492: <div class="article-text"> 493: 494: ## PAGE DATE 495: #printDate 496: 497: ## ARTICLE BODY 498: $body 499: 500: ## ARTICLE FOOTER 501: #if (!$request.getAttribute("disable_article_footer")) 502: <div class="article-footer clearfix">$website.include("article-footer")</div> 503: #end 504: 505: ## SHARE BUTTONS 506: #if ($shareButtons && $infiniteScroll && !$website.isIncluded()) 507: $!request.setAttribute("showBookmark", false) 508: $website.include("share-buttons") 509: #end 510: 511: </div> 512: 513: ## SIDEBAR (for mobile print here) 514: #if ($isMobile) 515: #printSidebar 516: #end 517: 518: </div> ## article-body 519: 520: #if ($isMobile) 521: #printRelatedLinks 522: #end 523: 524: ## RELATED PHOTO GALLERY 525: #if ($relatedGallery.url) 526: #set ($photos = $relatedGallery.allHeadlines) 527: #if ($photos.size() > 0) 528: <div class="related-gallery"> 529: <h2 class="related-title">Related Photos</h2> 530: <div class="photos"> 531: <div class="photo-slider" data-module="jscroll" data-snap=".item" data-show-prev-next="true" data-show-buttons="true"> 532: <div> 533: #foreach ($photo in $photos) 534: #set ($imgAlt = "") 535: #if ($photo.altText.length() > 0) 536: #set ($imgAlt = $photo.altText) 537: #elseif ($photo.title.length() > 0) 538: #set ($imgAlt = $photo.title) 539: #else 540: #set ($imgAlt = "Photo for $page.title image $velocityCount") 541: #end 542: <div class="item"> 543: <a href="${relatedGallery.url}"><img data-src="${photo.url}?max_height=140" alt="$!{imgAlt}" class="lazyload" /></a> 544: </div> 545: #end 546: </div> 547: </div> 548: </div> 549: </div> 550: #end 551: #end 552: 553: $wiki 554: 555: </div> ## rich-v2 556: 557: ## GLOBAL ADS SERVER 558: #if ($website.ads.isAdvertisingEnabled('ARTICLES')) 559: $website.includeAgain("global-adserver-slots?adSlot=articles") 560: #end 561: 562: #end ## printArticleLayout 563: 564: ######### END MACROS #################### 565: 566: #if ($infiniteScroll && !$ajax) 567: $!request.setAttribute("pageClass", "release-page") 568: <div class="infinite-articles" data-module="infinite-articles"> 569: <div class="articles"> 570: #printArticleLayout 571: </div> 572: 573: #printRelatedArticles 574: </div> 575: #else 576: #printArticleLayout 577: #end 578: 579: #end ## ends only-body check 580: #end ## showMobile check 581: 582: $!request.setAttribute("icl-videojs-script", true) 583: $!request.setAttribute("icl-videojs-flash-script", true)