- Home /
How to format Unity's Webplayer
I have need to have a form on the same page as the Unity web player. I'm trying to position the form to the left of the game so that they will be side by side. I'm not familiar with CSS or div tags. I have tried setting my form in a div tag that had a float set to left and I also gave the content div a left float, but it seems no matter what I have tried the form is always displayed above the game.
Any suggestions?
Answer by DannyB · Aug 21, 2012 at 12:04 PM
This is not really a Unity question but an HTML/CSS question.
But in any case what you want to do is simple, in the HTML:
Remove or increase the width attribute of the div.content class - you should now see it will snap to the left (if you removed width).
Add float:right to the unityplayer CSS (div#unityPlayer)
Add a new DIV inside the content div, above the player div and give it id="myform"
In the CSS add div#myform selector and give it float:left attribute as well as width
There are more ways to achieve this, depending on what exactly you need, but this is one of the basic methods.
Edit: Attached example file.