![]() |
|
|
|||||||
![]() |
|
|
Thread Tools | Rate Thread |
|
|
PM User | #1 |
|
Regular Coder ![]() Join Date: Sep 2008
Posts: 346
Thanks: 1
Thanked 2 Times in 1 Post
![]() |
Not giving button style
I currently have this css:
Code:
input{
font-size:12px;
padding:4px 2px;
border:solid 1px #675f39;
}
</style>
Code:
<form action="accounts-password.php" AUTOCOMPLETE = "off" method="POST"> <input type="hidden" name="member" value="1" /> <span style="float: left;"> Your old Password: </span> <span style="float: right;"> <input size="40" class="only" type="password" name="oldpass"> </span> <br><br> <hr> <span style="float: left;"> Your New Password: </span> <span style="float: right;"> <input size="40" type="password" name="newpass"> </span> <br><br> <span style="float: left;"> Re-Type Your New Password: </span> <span style="float: right;"> <input size="40" type="password" name="veri"> </span> <br><br> <hr> <center> <input name="chpass" id="submit" type="submit" value="Change Password" > </center> </form> Code:
<input size="40" type="password" name="newpass"> Code:
<input name="chpass" id="submit" type="submit" value="Change Password" > I guess its because they are both starting with the '<input', not sure.
__________________
█ MY MSN: Sith717@Hotmail.com █ PHP, HTML, and CSS Coding, Logo and Web Design - Professionally done. █ PM me anytime for HTML, PHP or web design help. I will be glad to help you out. |
|
|
|
|
|
PM User | #2 |
|
New to the CF scene Join Date: Nov 2009
Location: Florida United States
Posts: 9
Thanks: 1
Thanked 0 Times in 0 Posts
![]() |
Give spans classes
Try giving all your inputs that you want changed a class and call the class in the CSS.
Last edited by calebandchels; 11-07-2009 at 03:08 PM.. Reason: bad spelling |
|
|
|
|
|
PM User | #3 |
|
Regular Coder ![]() Join Date: Oct 2009
Location: United Kingdom
Posts: 229
Thanks: 2
Thanked 32 Times in 32 Posts
![]() |
as you say this is because submit starts with<input
two ways to rememdy this: either: Code:
input .textbox-only {
font-size:12px;
padding:4px 2px;
border:solid 1px #675f39;
}
<input class="textbox-only" size="40" type="password" name="newpass" />
Code:
input {
font-size:12px;
padding:4px 2px;
border:solid 1px #675f39;
}
input .button-no-style {
/* another style */
}
<input class="button-no-style" name="chpass" id="submit" type="submit" value="Change Password" >
|
|
|
|
|
|
PM User | #4 |
|
Regular Coder ![]() Join Date: Sep 2008
Posts: 346
Thanks: 1
Thanked 2 Times in 1 Post
![]() |
Its still giving me the same style as the input for the button-no-style
__________________
█ MY MSN: Sith717@Hotmail.com █ PHP, HTML, and CSS Coding, Logo and Web Design - Professionally done. █ PM me anytime for HTML, PHP or web design help. I will be glad to help you out. |
|
|
|
|
|
PM User | #5 |
|
Regular Coder ![]() Join Date: Oct 2009
Location: United Kingdom
Posts: 229
Thanks: 2
Thanked 32 Times in 32 Posts
![]() |
like i said, you need to either specify another style for the submit button if you want it different than the text boxes, or use the first method (class applied to text boxes only) if you don't want any styling applied to the submit
apologies for any confusion Code:
input .style {
font-size:12px;
padding:4px 2px;
border:solid 1px #675f39;
}
<input class="style" name="" type="text" /> /* styled */
<input type="submit" name="Submit" value="Submit" /> /* default */
|
|
|
|
|
|
PM User | #6 |
|
Regular Coder ![]() Join Date: Sep 2008
Posts: 346
Thanks: 1
Thanked 2 Times in 1 Post
![]() |
Okay, well I have done it my way and it works perfect.
I got a new problem: I want this: Code:
<span style="float: left;"> Main News Message: </span> <span style="align: right;"> <textarea style="border:solid 1px #675f39; padding:4px 2px;" name="mainnewsmessage" cols="40" rows="8"> <?php echo $row['mainnewsmessage']; ?> </textarea> </span> <hr> It would work before: Code:
<span style="float: left;"> Main News Message: </span> <span style="float: right;"> <textarea style="border:solid 1px #675f39; padding:4px 2px;" name="mainnewsmessage" cols="40" rows="5"> <?php echo $row['mainnewsmessage']; ?> </textarea> </span> <br /> <br /> <br /> <br /> <br /> <br /> <br /> <hr> Code:
<br /> <br /> <br /> <br /> <br /> <br /> <br /> <hr>
__________________
█ MY MSN: Sith717@Hotmail.com █ PHP, HTML, and CSS Coding, Logo and Web Design - Professionally done. █ PM me anytime for HTML, PHP or web design help. I will be glad to help you out. Last edited by bucket; 11-07-2009 at 03:47 PM.. |
|
|
|
|
|
PM User | #7 | ||
|
Master Coder ![]() Join Date: Mar 2007
Location: God's own country
Posts: 8,975
Thanks: 142
Thanked 1,192 Times in 1,184 Posts
![]() ![]() ![]() ![]() |
Quote:
__________________
Quote:
|
||
|
|
|
|
|
PM User | #8 |
|
Regular Coder ![]() Join Date: Sep 2008
Posts: 346
Thanks: 1
Thanked 2 Times in 1 Post
![]() |
so like?
Code:
input.style {
font-size:12px;
padding:4px 2px;
border:solid 1px #675f39;
}
__________________
█ MY MSN: Sith717@Hotmail.com █ PHP, HTML, and CSS Coding, Logo and Web Design - Professionally done. █ PM me anytime for HTML, PHP or web design help. I will be glad to help you out. |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Rate This Thread | |
|
|