Demos and example code

Widget API

TP (Trip planner)

data-hfs-widget-tp-postform
"newtab" | "default"
By "default" the WebApp opens in the same window/tab where the widget is located. By setting the parameter to "newtab" a new tab/window will be used to open the WebApp.
data-hfs-widget-tp-[dep/arr]
hfsLocation (HAFAS-ID), String (Location Name)
By using this parameter you can set the departure and/or arrival location in advance.
data-hfs-widget-tp-date
Date (HCI Format)
By using this parameter you can set the prefilled date for the widget.
data-hfs-widget-tp-time
Time (HCI Format)
By using this parameter you can set the prefilled time for the widget.
data-hfs-widget-switches-layout
"default" | "homepage"
By using this parameter you can set the layout of the widget.

SQ (Departures / Arrivals)

data-hfs-widget-sq-autorefresh
Boolean
Defines whether stationboars should refreshed every minute.
data-hfs-widget-sq-maxjny
int
By using this parameter you can set the number journeys to be shown. It is possible that more journeys will be displayed, journeys departing at the same time will always be displayed even if they exceed the value limit of journeys to be shown.
data-hfs-widget-sq-sort
"time" / "line"
Mode "time" chronologically sorts the stationboard (default), "line" groups journeys by line and destination.
data-hfs-widget-sq-location
hfs-location
Enter a valid HAFAS location id to fill the location for the departure board.
data-hfs-widget-sq-pcls
int
This parameter can limit the products to be shown in the stationboard