It is possible to override mobile heights for custom situations. To do so, apply a media query such as the one below and change the values to fit your situation. In order to “override” existing media queries, note the “!important” for the height value.
This recipe allows you to override the functionality of a standard link and use a “deeplink” for linking within a mobile app.
To add this functionality, simply copy and paste the javascript below to the customJS GAM field. Then modify your HTML link by add and customizing the “data” elements seen below. Be sure to use all three. The “event” attributes will ensure that this link will still send events to the Event Tracker.
WARNING: This software will affect your Google Analytics as you are overriding GAMs core linking functionality.
Adding timed elements is easy. Simply wrap your timed element with a <span class="datecheck" data-date-start="" data-date-end=""> tag. Be sure to include the human-readable start and end date in the following format: dd/mm/yy hh:ss:mm. Once done, copy the CustomJS code below to your GAM ad.
NOTE: If you’re already wrapping your timed text in a <span> tag, simply add the datacheck class and the data tags as listed above to your existing element.
CAUTION: There are no guards on this JS function that prevents multiple items from appearing OR default values. If you use this feature, be sure to check your dates and ensure there will always be a value. The example below shows a limited time message, then display a “default” message for a protracted term.