Reputation: 1773
I'm creating a simple fake forum for a class project. It works exactly like a normal forum where you can post topics, comment, ect.. But when you are at the main forum page (bellow) there is text that says signed in as
and then your username
but the username is not right next to the text on one line like i want it to be. How can I merge them together?
This is the code for that line
<form align="right" id="name_disp">
<div>
<p id="SIA">signed in as </p>
<a style="color:blue"id="userNAME" onclick="showProfile(this.innerHTML)">hahn2014</a>
<input type="button" value="Sign Out" onClick="logOut()" style="width: 65px; height: 25px">
</div>
</form>
Upvotes: 0
Views: 19
Reputation: 1405
Instead of <p> </p>
use <span></span>
like this :
<span id="SIA">signed in as </span>
<a style="color:blue"id="userNAME" onclick="showProfile(this.innerHTML)">hahn2014</a>
JSFIDDLE : http://jsfiddle.net/y9Gje/
Upvotes: 1