• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 1.2 Placeholder Text inside loginBar .textCtrl

TsinJu

Well-known member
#1
Hello. I would like to change the Placeholder´s text position for "Your name or email address:" and "Do you already have an account?" from outside the Login Slider´s textCtrl Field to inside. On active field their should be no text anymore.
Is it possible and can anyone help me with that?

text_inside.jpg
 

Adam Howard

Well-known member
#2
Hello. I would like to change the Placeholder´s text position for "Your name or email address:" and "Do you already have an account?" from outside the Login Slider´s textCtrl Field to inside. On active field their should be no text anymore.
Is it possible and can anyone help me with that?

View attachment 62066
This can easily be changed by looking for these phrases templates

AdminCP > Appearance > Phrases
  • do_you_already_have_account
  • your_name_or_email_addres
 

TsinJu

Well-known member
#5
But i dont want to replace the text, i want to move the Text (e.g. Your name or email address), as shown in the picture, from left to inside the name´s form field.

Sorry for any Misunderstanding, but i thought the picture helps clarifying my wish?!
 

Adam Howard

Well-known member
#6
But i dont want to replace the text, i want to move the Text (e.g. Your name or email address), as shown in the picture, from left to inside the name´s form field.

Sorry for any Misunderstanding, but i thought the picture helps clarifying my wish?!
I'm sorry, I gathered you wanted to change it. I was not clear that you wanted to move it inside the box. I just assumed you meant you wanted to change the text.

I'm sure the photo made it clear for most people who use it, but I normally do not use the drop down menu often. And when I do, my password manager usually fills in everything already so I never get to see what it looks like empty.

Will get back to you on this...
 

Adam Howard

Well-known member
#8
OK

part 1 -- Add the text inside the box

login_bar_forum

look for
PHP:
      <dd><input type="text" name="login" id="LoginControl" class="textCtrl" tabindex="101" /></dd>
change too
PHP:
      <dd><input type="text" name="login" id="LoginControl" class="textCtrl" placeholder="{xen:phrase your_name_or_email_address}" tabindex="101" /></dd>
look for
PHP:
            <input type="password" name="password" class="textCtrl" id="ctrl_password" tabindex="102" />
change too
PHP:
            <input type="password" name="password" class="textCtrl" placeholder="{xen:phrase do_you_already_have_account}" id="ctrl_password" tabindex="102" />
I'm trying to figure out now how to remove the text on the side (as I believe you wanted), but you have one hell of an alignment issue when you remove it.

Working on it....
 

Adam Howard

Well-known member
#9
OK

part 2 - remove the side text

Same template...


Look for
PHP:
      <dt><label for="LoginControl">{xen:phrase your_name_or_email_address}:</label></dt>
replace with
PHP:
      <dt><label for="LoginControl"></label></dt>
Look for
PHP:
                <label for="ctrl_password">{xen:phrase do_you_already_have_account}</label>
replace with
PHP:
                <label for="ctrl_password"></label>
DONE :)

Screenshot from 2013-11-28 17:10:48.png
 

TsinJu

Well-known member
#12
login_bar.css

Would allow you to further customize the log-in bar to your liking. ;)
Thought so. Thanks for the tip ;)

Allow me a last Question?!
The Idea is just to have the "No, create an account now." Radio Button as a Checkbox.

I edited this Code
Code:
 <li><label for="ctrl_not_registered"><input type="radio" name="register" value="1" id="ctrl_not_registered" tabindex="105" checked="checked" class="Disabler" />{xen:phrase no_create_account_now}</label></li>
into this (just changed "radio" into "checkbox")
Code:
 <li><label for="ctrl_not_registered"><input type="checkbox" name="register" value="1" id="ctrl_not_registered" tabindex="105" checked="checked" class="Disabler" />{xen:phrase no_create_account_now}</label></li>
and deleted
Code:
li><label for="ctrl_registered"><input type="radio" name="register" value="0" id="ctrl_registered" tabindex="105" checked="checked" class="Disabler" />{xen:phrase yes_my_password_is}:</label></li>
i have a checkbox now (wohoo ;) ), but it works the other way round. When "uncheck´ing" the checkbox, the field where to enter the Password is inactive, when checking its active.
Guess it´s because the Code at all is wrong, but, hell, i have no idea what to do.
Tried Google but can´t find any way that helps me getting this done.

At the End both Radio Button "No, create an account now." and "Yes, my password is:"
shall become one as checkbox...
 

Adam Howard

Well-known member
#13
I forget where it is, but there is an "and / or" statement somewhere. So you need both boxes for it to work. You can't just remove one. I don't recall how to change that (sorry).