How to Center a Raw HTML box?

Posted in: Newspaper
Post count: 4

Hi I´m using Newspaper8 and drag the “Raw HTML box” to where I want to place an iframe code with my ads. The code is generated by Revive Adserver and everything works properly except the alignment of the Raw HTML box.

The full code that I am paste-ing into the Raw HTML box is below. The alignment of the ads is always set to left and I can’t change it.

What code can I add before or inside the iframe code to make what’s inside the Raw HTML appear in the center?

Hope you can help,
Thanks,
Editor at http://www.topp5.is
===========

<!– Revive Adserver iFrame Tag – Generated with Revive Adserver v4.1.1 –>
<iframe id=’ae42645b’ name=’ae42645b’ src=’http://adserver.topp5.is/www/delivery/afr.php?zoneid=8&target=_blank&cb=INSERT_RANDOM_NUMBER_HERE&#8217; frameborder=’0′ scrolling=’no’ width=’1020′ height=’360′></iframe>

Post count: 9544

You can’t control anything inside an iframe being loaded from external source as the “elements” inside the iframe are all controlled by THAT content being loading into the iframe container.

You can try doing normal CSS?
https://www.w3schools.com/tags/att_iframe_align.asp

<iframe src="/default.asp" width="200" height="200" align="right">
</iframe>

Post count: 9544

Theme doesn’t control your basic HTML elements like that. If there is existing CSS conflicting, simply add your own custom css to manage a custom use, as in your ad unit.

Post count: 9544

Also, I think with modern HTML5, applying a ‘class’ to the iframe is better way to do all of that either by explicit class, or by id=mycustoframe … etc.

Viewing 4 posts - 1 through 4 (of 4 total)
The forum ‘Newspaper’ is closed to new topics and replies.