Question:

HTML input box alignement?

by  |  earlier

0 LIKES UnLike

okay so i'm a complete noob at html lol.. but i have a <input style"text" that i would like to be aligned to the bottom right.. in otherwords i want the input box itself on the bottom right of the page instead of the default top left. i don't know what commands to realign to were i want.. all i have right now is ..

<input type="text" name="q" size="31"

maxlength="255" value="" />

<input type="image" SRC="search.jpg"/>

what can i change to cause it to realign?

 Tags:

   Report

1 ANSWERS


  1. This requires style sheets. You can put the elements into an container element (here: &lt;div&gt;), and give it an style attribute. The position property is set to &quot;fixed&quot;, e. g. its position is independent of the surrounding text, and doesn&#039;t change with scrolling. The position is specified relative to the window perimeter. Here it is placed 10 pixels away of the right border, and 10 pixels off the bottom.

    &lt;div style=&quot;position: fixed; right: 10px; bottom: 10px;&quot;&gt;

    &lt;input type=&quot;text&quot; name=&quot;q&quot; size=&quot;31&quot;

    maxlength=&quot;255&quot; value=&quot;&quot; /&gt;

    &lt;input type=&quot;image&quot; SRC=&quot;search.jpg&quot;/&gt;

    &lt;/div&gt;

Question Stats

Latest activity: earlier.
This question has 1 answers.

BECOME A GUIDE

Share your knowledge and help people by answering questions.