Type Function Return value none Revision Release 2024.3703 Keywords ads, advertising, Appodeal, hide See also appodeal.show() appodeal.*
Hides a currently displayed Appodeal banner ad. Does not apply to interstitial or video ads.
appodeal.hide( adUnitType )
String. The type of ad to hide. This should always be set to "banner"
.
local appodeal = require( "plugin.appodeal" ) local function adListener( event ) if ( event.phase == "init" ) then -- Successful initialization -- Show a banner ad appodeal.show( "banner", { yAlign="top" } ) elseif ( event.phase == "failed" ) then -- The ad failed to load print( event.type ) print( event.isError ) print( event.response ) end end -- Initialize the Appodeal plugin appodeal.init( adListener, { appKey="YOUR_APP_KEY" } ) -- Sometime later, hide the ad appodeal.hide( "banner" )