snoopy5 Well-known member Oct 16, 2012 #1 Hi I want to use other colours than anywhere else in the forum for the "login/register" formular. How can I do this?
Hi I want to use other colours than anywhere else in the forum for the "login/register" formular. How can I do this?
Chris D XenForo developer Staff member Oct 16, 2012 #2 Each of the fields on the login/register form have a unique ID. You could style them in EXTRA.css by referencing the ID of the element (rather than the class). e.g. #id_ctrl_email { background-color: red; } Would give the Email field only a red background. Upvote 0 Downvote
Each of the fields on the login/register form have a unique ID. You could style them in EXTRA.css by referencing the ID of the element (rather than the class). e.g. #id_ctrl_email { background-color: red; } Would give the Email field only a red background.
snoopy5 Well-known member Oct 16, 2012 #3 Thanks. That sound good. Where can I find a list of all those IDs? Upvote 0 Downvote
Chris D XenForo developer Staff member Oct 16, 2012 #4 Use a decent browser such as Chrome or Firefox. Right click the field and select "Inspect Element" from the menu. You will then be shown the HTML code which pertains to that field. So something like: <input type="text" class="textCtrl" name="email" id="id_ctrl_email" /> id_ctrl_email is the ID so you would reference that in css with #id_ctrl_email Upvote 0 Downvote
Use a decent browser such as Chrome or Firefox. Right click the field and select "Inspect Element" from the menu. You will then be shown the HTML code which pertains to that field. So something like: <input type="text" class="textCtrl" name="email" id="id_ctrl_email" /> id_ctrl_email is the ID so you would reference that in css with #id_ctrl_email
snoopy5 Well-known member Oct 16, 2012 #5 Thanks, I get the id with this, but it seems to be the wrong code for the background. Nothing changes. Upvote 0 Downvote
Thanks, I get the id with this, but it seems to be the wrong code for the background. Nothing changes.
Chris D XenForo developer Staff member Oct 16, 2012 #6 My example was wrong. The id for the email field is actually just "ctrl_email". So EXTRA.css containing: #ctrl_email { background-color: red; } Would make the email field red. Upvote 0 Downvote
My example was wrong. The id for the email field is actually just "ctrl_email". So EXTRA.css containing: #ctrl_email { background-color: red; } Would make the email field red.