Jump to content

ads shown on sides of things?

Fierce God

Recommended Posts

Ok, noob question here!

Im wanting to finally use the advertisement option that is given in the AdminCP

I already understand and have tested out the part on where it says to put the ad key....{advertisement="KEY"}....,at the bottom of the place i want to use, in the Theme html/css

My question and want is, where in that part of the html/css can i put the ad key to make an ad show up on either side of something? Here's my examples..

example 1........Im using twitch streams on my server tha ppl can watch right there on site. I want to be able to have ads show up on either side of the stream.....so if you select and click the stream, it opens up and there on either side of it is ads, with stream in the middle......these same ads automatically show on each stream,

example 2........im using the app called Videos......when you select the video you want to watch, i want ads to be on either side of the video 

Heres a look at the script example for Streams.....i know that if i put the key at the bottom, that it will show in bottom once viewed ...but where in this script would i put the ad key for showing up on sides of the stream player


{{$videoURL = mb_substr($current['vbo_url'], -4) == '|end' ? mb_substr($current['vbo_url'], 0, -4) : $current['vbo_url'];}}
<div class="videoWrapper">
	{{if settings.vb_conf_online_watermark_on == 1 && settings.vb_conf_online_watermark}}
		<img src='{setting="vb_conf_online_watermark"}' class='videoWatermark'>
	{{if !$video->myPlayer( $videoURL )}}
		<div id='videobox_player'>
			{expression="\IPS\Application::load('videobox')->customPlayer($videoURL)" raw="true"}
		<video id='videobox_player' class='video-js vjs-default-skin vjs-big-play-centered'>
			{{if mb_strpos($videoURL,'picasaweb.google.com') !== false || mb_strpos($videoURL,'drive.google.com') !== false}}
				{{foreach (array) \IPS\Application::load('videobox')->getLinkGoogle($videoURL) as $file}}
					<source src="{$file['link']}" type="{$file['type']}" label="{$file['res']}" res="{$file['res']}">
			{{elseif mb_strpos($videoURL,'rtmp') !== false}}
				<source src="{$videoURL}" type='rtmp/mp4'>
			{{elseif mb_strpos($videoURL,'.webm') !== false}}
				<source src="{$videoURL}" type='rtmp/webm'>	
			{{elseif mb_strpos($videoURL,'.mp4') !== false || mb_strpos($videoURL,'.m4v') !== false}}
				<source src="{$videoURL}" type='video/mp4'>
			{{elseif mb_strpos($videoURL,'.flv') !== false}}
				<source src="{$videoURL}" type='video/flv'>	
			{{elseif mb_strpos($videoURL,'.m3u8') !== false}}
				<source src="{$videoURL}" type='application/x-mpegURL'>					
			{{foreach (array) $video->getSubtitles($current['vbo_sub']) as $sub}}
				<track kind='captions' src="{$sub['sub']}" srclang="{$sub['lang']}" label="{$sub['label']}" {{if $sub['default']==1}}default{{endif}}>
		{{\IPS\Output::i()->endBodyCode .= \IPS\Theme::i()->getTemplate( 'embed', 'videobox' )->player_script($video, $current, $next);}}


<div id='playerPanel'>
	{{$vid = \IPS\Request::i()->vid > 0 ? \IPS\Request::i()->vid : 1;}}
	{{$serverID = \IPS\Request::i()->serverID > 0 ? \IPS\Request::i()->serverID : $current['vbs_id'];}}
	{{foreach $video->videoOnline() as $name => $server}} 
		{{if count($server['online']) > 0 && ( $server['groups'] == 0 || \IPS\Member::loggedIn()->inGroup( explode( ",", $server['groups'] ) ) )}}
			<ul class='ipsButton_split'>
				{{$cnt = 0;}}
				<li class='ipsButton ipsButton_verySmall ipsButton_primary vbServerName' style='width: 100px !important;'>
				{{foreach $server['online'] as $num => $row}}
						<a href="{$video->url()->setQueryString( array( 'area' => 'online', 'serverID' => $row['vbs_id'], 'vid' => $cnt ) )}" class="ipsButton ipsButton_verySmall {{if $serverID == $row['vbs_id'] && $vid == $cnt}}ipsButton_important{{else}}ipsButton_light{{endif}}" {{if $server['vbs_upload'] == 0 && $video->canEdit()}}data-action='managePart' data-videoid="{$video->id}" data-partid="{$row['vbo_id']}"{{endif}}>
							{lang="videobox_videopart"} {$num}{{if mb_substr($row['vbo_url'], -4) == '|end'}} {lang="videobox_end"}{{endif}}
				{{if $server['vbs_upload'] == 0 && $video->canEdit()}}
						<a href="{$video->url()->setQueryString( array( 'do' => 'addNewPart', 'server' => $row['vbs_id'] ) )}" class="ipsButton ipsButton_verySmall " title='{lang="vb_addNewPart"}' data-ipsDialog data-ipsDialog-title='{lang="vb_addNewPart"}' data-ipsDialog-forceReload='true'>


Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...