Results 1 to 9 of 9

Thread: I cant hide a field on my site

  1. #1
    Join Date
    Nov 2011
    Location
    Cider Region
    Posts
    1,132
    Thanks
    158
    Thanked 3 Times in 3 Posts

    Default I cant hide a field on my site

    Hello
    I have a site of which i am putting together for a bit of fun and to teach myself but i need a little help from the masters of script if i may.
    I have a line of text but need it hidden but whatever i do i cant get it to work.
    It is on my contact page with HTML & a recaptcha & also a php file.
    What you see on my site is the following.
    name then empty field box
    email address then empty field box
    subject then field box prefilled with WEB SITE ENQUIRY
    comments then empty field box.
    What i would like is for the complete line in BOLD above to be hidden so
    it cant be seen on the website BUT i can see it when the email is received by me.
    I am having a bad day by not being able to complete this small task.
    Any help would be nice if somebody could edit the script for me.
    Many thanks
    Code:
    </script>
    	<div class="email">
    	
    		<table>
        </tr>
        		<tr>
    				<td align="justify">
    				<p align="justify"><label for="name"><b>Name</b> *</label> </td>
    				<td valign="top" align="justify">
    				<p align="justify">
    				<input  type="text" name="name" maxlength="50" size="40"> </td>
    			<tr>
    				<td valign="top" align="justify">
    				<p align="justify"><label for="email"><b>Email Address</b> *</label> 
    				</td>
    				<td valign="top" align="justify">
    				<p align="justify">
    				<input  type="text" name="email" maxlength="100" size="40"> </td>
    
    			<tr>
    				<td valign="top" align="justify">
    				<p align="justify"><label for="subject"><b>Subject</b> *</label>
    				</td>
    				<td valign="top" align="justify">
    				<p align="justify">
    				<input  type="text" name="subject" value="WEB SITE ENQUIRY" maxlength="50" size="40">
    				</td>
    			</tr>
    			<tr>
    				<td valign="top" align="justify">
    				<p align="justify"><label for="comments"><b>Comments</b> *</label>
    				</td>
    				<td valign="top" align="justify">
    				<p align="justify">
    				<textarea  name="comments" maxlength="2000" cols="40" rows="6"></textarea>
    				</td>
    			</tr>
    		</table><input class="reset" type="reset" value="Reset All">
    Last edited by jscheuer1; 12-04-2011 at 06:43 PM. Reason: Format

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    Replace the table with:

    Code:
    <table>
     <tr>
     <td align="justify">
     <p align="justify"><label for="name"><b>Name</b> *</label> </td>
     <td valign="top" align="justify">
     <p align="justify">
     <input type="text" name="name" maxlength="50" size="40"> </td>
     </tr>
     <tr>
     <td valign="top" align="justify">
     <p align="justify"><label for="email"><b>Email Address</b> *</label> 
     </td>
     <td valign="top" align="justify">
     <p align="justify">
     <input type="text" name="email" maxlength="100" size="40"> 
     <input type="hidden" name="subject" value="WEB SITE ENQUIRY">
     </td>
     </tr>
     <tr>
     <td valign="top" align="justify">
     <p align="justify"><label for="comments"><b>Comments</b> *</label>
     </td>
     <td valign="top" align="justify">
     <p align="justify">
     <textarea name="comments" maxlength="2000" cols="40" rows="6"></textarea>
     </td>
     </tr>
     </table><input class="reset" type="reset" value="Reset All">
    Note: I left off the preceding </script> and <div> tags. I kept the trailing reset button.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  3. #3
    Join Date
    Nov 2011
    Location
    Cider Region
    Posts
    1,132
    Thanks
    158
    Thanked 3 Times in 3 Posts

    Default

    Perfect
    Works a treat.

    Thanks very much

  4. #4
    Join Date
    Nov 2011
    Location
    Cider Region
    Posts
    1,132
    Thanks
    158
    Thanked 3 Times in 3 Posts

    Default

    Hello.
    One other question please if i may.
    The field boxes next to name,email etc how can i line them up with the recaptcha box & the central them to the screen.
    I have tried but the box either goes to far right & then the text drops down a line or two or it all becomes out out sync.
    I know what i am doing to a point but beyond that i would like to ask for help if i may so i dont make it worse.

  5. #5
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    I'm not sure I understand where you want the recaptcha box and in any event, you haven't shown the code for it, or enough code for the page to determine how to center anything.

    Do you have a live demo? If not, put one up. It doesn't have to do anything or be linked to or from anything. It just has to show the current layout.

    Post a link to it, and explain exactly where you want things.

    I think I understand that you want this centered horizontally on the page. But if I have that wrong, let me know. I'm not sure where you want the recaptcha box though, "line up with" is kind of vague.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  6. #6
    Join Date
    Nov 2011
    Location
    Cider Region
    Posts
    1,132
    Thanks
    158
    Thanked 3 Times in 3 Posts

    Default

    Here is the page
    http://www.ianparsons.info/email.htm
    As you can see the boxes / text are all over the page
    I would just like it to look central & a bit better than what is currently shown.

    Thanks for the help.

  7. #7
    Join Date
    Nov 2011
    Location
    Cider Region
    Posts
    1,132
    Thanks
    158
    Thanked 3 Times in 3 Posts

    Default

    Hello,
    Having a think about it i would say the best option is to have the text above each respective field box & central to the page.
    So name,email & comments text & boxes need to be arranged.

    Thanks so much for the help.

  8. #8
    Join Date
    Nov 2011
    Location
    Cider Region
    Posts
    1,132
    Thanks
    158
    Thanked 3 Times in 3 Posts

    Default

    ?????????????

    what does that mean address not complete ?

  9. #9
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    After looking at the page, I see this has now become more of a basic question about layout and could be approached in a variety of ways, and is a new question. Generally it's the policy of this forum to start a new thread for a new question. Please do so, as I'm closing this thread.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •