Team profile widget

Description

The Team profile widget provides basic and advanced statistics about a team, as well as odds information.

Bind the widget to HTML DOM

🚧

Make sure that you have the loader already set up on your website.
If not, follow our guide:

You can bind the widget to the HTML DOM by two ways:

  • Bind the widget without initial options. The required attribute here is "data-widgetId"
    <div data-widgetId="team"></div>
  • Bind the widget with initial options. The all available options can be seen below
    <div data-widgetId="team" data-options='{...}'></div>
  • The optional "data-options" attribute:
    {
        int teamId: 1,      // Unique identifier of the resource.
        int seasonId: 1 // when it is inputed in the data-options= {}, the team statistics for the given season are displayed, otherwise the statistics for the latest season are shown.
        string lang: 'en',    // the language in format like: en, bg, ru and etc.
        display["info", "stats", "odds"] -> A list of components to be displayed. If blank, all three options will be displayed (if available).
        Available options:
        - "info" - displays information about the team;
        - "stats" - displays statistical information;
        - "odds" - displays odds for selected eventiD if available;

        market:{"name":"1x2"} -> select a market for the odds.
        int[] oddProviderIds -> // A list of ids, these ids are odd provider ids. This option is responsible
                                        // for displaying only odd providers with the ids that are added in the given array.
                                        // If oddProviders and oddProviderIds options are both provided, the oddProviderIds option will be used only, as it is with a higher priority.

        string apiURL -> // The URL of the API for football information
        boolean canSelectMarkets -> // Show/Hide markets dropdown
        string apiKey  -> // The key for the authorization header which will be base64 encoded
        int eventId,      -> // Unique identifier of the resource.
        string oddClient  -> // Identifies the client for which to return filtered bookmakers with affiliate URLs.
                                     // Without the parameter can not sort odd_providers or provide affiliate links.
                                     // Instead it will sometimes give a 'coupon' key with the odds fo building URLs. header
                                     // NB! This option is mandatory, otherwise the odds wont be displayed
        displayTeamShortNamesOnDesktop: (true/false)  -> // This option replaces the team name with its short name on all resolutions, if "displayTeamCustomNamesOnDesktop" is not added
        displayTeamShortNamesOnMobile: (true/false)  -> // This option replaces the team name with its short name on mobile resolutions, if "displayTeamCustomNamesOnMobile" is not added
        displayTeamCustomNamesOnDesktop: (true/false)  -> // This option replaces the team name with its custom name on all resolutions
        displayTeamCustomNamesOnMobile: (true/false)  -> // This option replaces the team name with its custom name on mobile resolutions

    }

Team profile widget in the CMS

Currently, the Sportal365 CMS offers a variety of football widgets to enable creators to add sports-specific statistics and context to their articles, videos, or galleries.

Adding Team profile widget in Blocky

To display basic team information (founded date, league, coach, stadium, country, and social media):

  • Enter your desired team in the Team field, select a Season and then Save block.

To display _advanced team information (_team wins, matches played, losses, points, and so on):

  • Select the Display statistics option and then Save block.

To complement the information you provide about a team with odds:

  • Select the Display odds option.
  • When the Odds data panel appears, select a Match and Bookmaker.

πŸ“˜

Note that displaying odds with the Team profile widget follows the same logic and steps of the Odds widget.

Video Example