Jump to content

Text size in php form!


brmcdani

Recommended Posts

This is driving me crazy because I know it is so simple.  I can't find any sources to help.  I am trying to make my text bigger in this table and form.  Can someone show me how to edit the text size and style in at least one line in the form and one in the table please?

 

Thanks

 

    echo "<table border=\"0\" cellspacing=\"3\" cellpadding=\"3\">\n";
    echo "<form method=\"post\" action=\"register.php\">\n";    
    echo "<tr><td>Username</td><td><input type=\"text\" name=\"username\"></td></tr>\n";
    echo "<tr><td>Password</td><td><input type=\"password\" name=\"password\"></td></tr>\n";
    echo "<tr><td>Confirm</td><td><input type=\"password\" name=\"passconf\"></td></tr>\n";
    echo "<tr><td>E-Mail</td><td><input type=\"text\" name=\"email\"></td></tr>\n";
    echo "<tr><td>First Name</td><td><input type=\"text\" name=\"name\"></td></tr>\n";
    echo "<tr><td>Last Name</td><td><input type=\"text\" name=\"aim\"></td></tr>\n";
    echo "<tr><td>Verification letters</td><td><input type=\"text\" name=\"verification\"></td></tr>\n";
    echo "<tr><td colspan=\"2\" align=\"center\"><input type=\"submit\" name=\"submit\" value=\"Register\"></td></tr>\n";
    echo "</form></table>\n";
    
    echo "<table border=\"0\" cellspacing=\"3\" cellpadding=\"3\">\n";
    echo "<tr><td>Verification letters to be entered into form:</td></tr>\n";
    echo "<tr><td>$rand[$keys]</td></tr>\n";
    echo "</table>\n";

Link to comment
Share on other sites

Hi brmcdani,

 

It would be better to use CSS for this, but as a quick fix, change your code to read:

 

echo "<tr><td><font size=\"18px\">Username</font></td><td><input type=\"text\" name=\"username\"></td></tr>\n";

 

The above would make only "Username" appear in a 18px font.  To change both the text and the size of the text inputted into each input field to a size of 18px change your code to read:

 

echo "<tr><td><font size=\"18\">Username</font></td><td><input type=\"text\" name=\"username\" style=\"font-size: 18px\" ></td></tr>\n";

 

Obviously, change the 18 to a lesser or greater number depending on your requirements.

 

However, as I mentioned, it would be better to style your tables and inputs using CSS.

 

Hope this helps.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.