HTML - Help With Opening/closing An Object
Hi. I am wondering if there is any way of opening/closing an object in HTML or CSS or Javascript?
For example, I have a Chat Box that is floating on the bottom left of the screen, I want to be able to close it if I don't want to see it, and if i want to open it up again, I would do so. If anyone can help, it would be greatly appreciated! Thanks, Chris Similar TutorialsI have a small window that shows site logins by ip address. I open it with window.open and get exactly the proper display in the proper position. But, I'm stuck with the browser page that called window.open(). Is there a way to close that browser? I've tried things like window.opener.close() with no luck. Remember, I want t close the browser, not just a window. Thanks, Mac must be a dumb question but my book dont say how when you want to simply have a link to say "close this window" ie for dummies that dont know to goto the big X up top, what it the code?? I understand that external CSS is great and a better choice, however, I am using a script that has many functions I need and is written this way. So I just want to finish up with what I have , instead of re-write this script. An "in-line css" suggestion worked fairly well except that I have a gap between the white background and the Header, and the white background and the Footer. Can someone help me eliminate this gap so the white background extends all the way to the Header and Footer, please? Here is the code, and I've attached an image for visual aid. Thanks! Code: <table style="background-color:#ffffff; font-family:Arial, Helvetica, sans-serif; width:200%"> <td align="left" valign="top"><font face="Arial" color="#000000" size="4"><b>text text text text text text text </b><br><font face="Arial" color="#990000" size="4"><b>TEXT TEXT TEXT TEXT TEXT TEXT TEXT </b></font><br> <font color="#FF9900">______________________________</font><br> <font face="Arial" color="#6B6B6B" size="3">Text Text Text text.<br><font face="Arial" color="#000000" size="3">TEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXTTEXT TEXT TEXT TEXT TEXT TEXT</font><br> </td></tr> </table> This web page has 3 things on it, when viewed: Choose A Transaction Transction Type and the button: Next And these things all have over an inch of space between them. Can you please help me close the gaps between the lines Choose A Transaction and Transaction Type. And can you please help me close the gap between Tansaction Type and "next" icon? Thank you. Code: <table width='770' border='0' cellpadding='0' cellspacing='0' id='maintable' align='center' valign='top' align='left' margin=0 padding=0 width='770' height='500' table style='background-color:#ffffff; font-family:Arial, Helvetica, sans-serif; width:'770' height:'500'></td> <link href='custom.css' rel='stylesheet' type='text/css'> <td id='menu' align='left' valign='top' rowspan='500' width='164'> <br> <img src='images/bullet.gif' alt='' width='10' height='10'><a href='index.php'><font color='#DDCEA2'><font face='Arial' size='2'>Home</a></font><br></a> <form method="POST" action="index.php"> <input class='field' type='hidden' name='command' value='account'> <input class='field' type='hidden' name='param' value='renew'> <input class='field' type='hidden' name='account_id' value='[account_id]'> <td colspan='2' class='pageTitle'><div class='hLine' display:inline;><font face="Arial" color="#EE7600" size="3"> Choose a Transaction</font></div></td> <tr><td class='fieldLabel' width="30%"><font face="Arial" color=#000000" size="3" Style="padding: 5px;"> <font face="Arial" color="#000000" size="3"> Transaction Type:</font><!--</td>--> <td align="left"><font face="Arial" color="#EE7600" size="2">[account_type_panel]</font></td> <tr><td align="center"></td> <td align="left"><input name="submit" type='submit' class='button' value='Next' /></td> </tr> </form> <tr height='30%' ><div class='hLine'display:inline;></div></td></tr> </table> Hi. I know this is fairly simple but havn't found a fix elsewhere. I created this form but can't close it. I'm guessing its to do with the table? Everytime i but a </form> tag in it either wont submit the form or screws up formatting. Any ideas. Thanks. Code: <table width="681" border="0" class="style26"> <tr> <td colspan="5" valign="middle"><p>My name is:<br> </p> </td> </tr> <tr> <td width="8" valign="middle"> </td> <td width="90" valign="middle"><span class="style30">given name(s)<br> </span></td> <td width="170" valign="middle"> <form action="lostform.php" method="post" name="form1"> <span id="sprytextfield1"> <label> <input type="text" name="gname" id="fname"> </label> </span> </form> </td> <td width="67" valign="middle" class="style30">surname</td> <td width="324" valign="middle"><span class="style30" id="sprytextfield2"> <label> <input type="text" name="sname" id="sname"> </label> </span><br></td> </tr> <tr> <td valign="middle"> </td> <td valign="middle">My email is:</td> <td colspan="3" valign="middle"><span id="sprytextfield3"> <label> <input type="text" name="email" id="email"> </label> <span class="textfieldRequiredMsg">A value is required.</span><span class="textfieldInvalidFormatMsg">Invalid format.</span></span><br> <br></td> </tr> <tr> <td colspan="3" valign="middle">My date of purchase was:</td> <td colspan="2" valign="middle"><span id="spryselect1"> <label> <select name="day" size="1" id="day"> <option selected>01</option> <option>02</option> <option>03</option> <option>04</option> <option>05</option> <option>06</option> <option>07</option> <option>08</option> <option>09</option> <option>10</option> <option>11</option> <option>12</option> <option>13</option> <option>14</option> <option>15</option> <option>16</option> <option>17</option> <option>18</option> <option>19</option> <option>20</option> <option>21</option> <option>22</option> <option>23</option> <option>24</option> <option>25</option> <option>26</option> <option>27</option> <option>28</option> <option>29</option> <option>30</option> <option>31</option> </select> </label> <span class="selectRequiredMsg">*</span></span> <span id="spryselect2"> <label> <select name="month2" size="1" id="month"> <option>JAN</option> <option>FEB</option> <option>MAR</option> <option>APR</option> <option>MAY</option> <option>JUN</option> <option>JUL</option> <option>AUG</option> <option>SEP</option> <option>OCT</option> <option>NOV</option> <option>DEC</option> </select> </label> <span class="selectRequiredMsg">*</span></span> <span id="spryselect3"> <label> <select name="year" size="1" id="year"> <option>1998</option> <option selected>1999</option> <option>2000</option> <option>2001</option> <option>2002</option> <option>2003</option> <option>2004</option> <option>2005</option> <option>2006</option> <option>2007</option> <option>2008</option> </select> *</label><span class="selectInvalidMsg"></span> </span><br></td> </tr> <tr> <td colspan="3" valign="middle">My Receipt Number was:</td> <td colspan="2" valign="middle"><span id="sprytextfield4"> <label> <input name="rcpt" type="text" id="rcpt" size="10" maxlength="8"> </label> <span class="textfieldRequiredMsg">A value is required.</span><span class="textfieldMinCharsMsg style32 style32">Invalid: Please check your receipt number</span><span class="textfieldMaxCharsMsg style32 style32">Invalid: Please check your receipt number.</span></span><br></td> </tr> <tr> <td colspan="3" valign="middle"><br> Other Comments:</td> <td colspan="2" valign="middle"> </td> </tr> <tr> <td valign="middle"> </td> <td colspan="4" valign="middle"><span id="sprytextarea1"> <label></label> <span class="textareaRequiredMsg">A value is required.</span></span> <div align="center"> <textarea name="message" id="message" cols="45" rows="5"></textarea> </div></td> </tr> <tr> <td> </td> <td colspan="4"><label> <input type="submit" name="submit" id="submit" value="Submit"> </form> <div align="center"></div> </label></td> </tr> </table> I am currently running this code. For as long as I've been validating web pages, I never realized that the closing </head> tag was optional in HTML. I feel as if I've missed the boat at times. While I'm all for trimming excess code, I just cannot for the life of me strip out closing tags because they are optional in HTML. I'd be concerned that something, somewhere would not parse the document correctly if I removed the closing </head> element. Are my concerns unfounded? I have a web page that has a gap between the main content page (lower) and the header piece(upper) and I can't figure out how to close this gap. If you're interested in taking a look at it. Here's the code and i've attached an image for a visual aid. Thanks. Code: <table width='770' border='0' cellpadding='0' cellspacing='0' id='maintable' align='center' table valign='top' align='left' cellpadding='0' width='770' height='500' table style='background-color:#ffffff; font-family:Arial, Helvetica, sans-serif; width:'770' height:'500'></td> <link href='custom.css' rel='stylesheet' type='text/css'> <td id='menu' align='left' valign='top' rowspan='500' width='165'> <br> <img src='images/bullet.gif' alt='' width='10' height='10'><a href='index.php'><font color='#DDCEA2'><font face='Arial' size='2'>Home</a></font><br> <img src='images/bullet.gif' alt='' width='10' height='10'><A href='index.php?command=signup_page'><font color='DDCEA2'><font face='Arial' size='2'>Sign Up</font></A> <br> <img src='images/bullet.gif' alt='' width='10' height='10'><a href='faq.html'><font color='DDCEA2'><font face='Arial' size='2'>FAQ</a><br> <img src='images/bullet.gif' alt='' width='10' height='10'><a href='legal.html'><font color='DDCEA2'><font face='Arial' size='2'>Terms of Use<br></a> <form method='POST' action='index.php'> <input class='field' type='hidden' name='command' value='account'> <input class='field' type='hidden' name='param' value='signup'> </form> <tr><td> </td></tr> <td valign=top colspan='2' class='pageTitle'><div class='hLine'><b> <font face='Arial' color='#EE7600' size='3'>Select The Payment Button Below To Continue</b></font></div></td></tr> <td class='fieldLabel' width='30%'> <font face='Arial' color='#A30100' size='2'><b>Transaction Type:</b></font></td> <td align='left' class='text' ><b>[account_type_title]</b></td> </tr> <tr> <td class='fieldLabel' width='30%'> <font face='Arial' color='#A30100' size='2'><b>Price:</b></font></td> <td align='left' class='text' ><b>$ [price]</b></td> </tr> <tr> <td class='fieldLabel' width='30%'> <font face='Arial' color='#A30100' size='2'><b>Subscription Period:</b></font></td> <td align='left' class='text' ><b><font face='Arial' color='#000000' size='2'>[period]</b> (month)</font></td></tr> <tr valign='top' height='55px' '> <td valign='top' class='fieldLabel' width='30%'> </td> <td valign='top'> <p><font face='Arial' color='#000000' size='2'>[payment_code]</font></p></td> </tr> <tr><td> </td></tr><tr><font face='Arial' color='#000000' size='2'></font> <tr height='30%' ><td colspan='2'><div class='hLine'> </div></td></tr> </table For as long as I've been validating web pages, I never realized that the closing </head> tag was optional in HTML. I feel as if I've missed the boat at times. While I'm all for trimming excess code, I just cannot for the life of me strip out closing tags because they are optional in HTML. I'd be concerned that something, somewhere would not parse the document correctly if I removed the closing </head> element. Are my concerns unfounded? For as long as I've been validating web pages, I never realized that the closing </head> tag was optional in HTML. I feel as if I've missed the boat at times. While I'm all for trimming excess code, I just cannot for the life of me strip out closing tags because they are optional in HTML. I'd be concerned that something, somewhere would not parse the document correctly if I removed the closing </head> element. Are my concerns unfounded? Hello, I am wondering if something is possible.. and if it is, how I would go about accomplishing the desired result.. This is a sample page to illustrate the problem http://comp.uark.edu/~bcagnin/test/index.html Is there a way to resize the object from a link that is within the website being displayed in that very same object?? Also, I am willing to use iframe if there is a solution that can be found with that... Thanks!! Tyrick Ok, I'm working on a website and I need to put in a text field where someone can effectively leave "updates" and little notes. The site will be saved on a network and used by multiple computers so I'm hoping it can be done without have to make multiple CSS files. So far so good. Essentially I want one computer to be able to type in text and close the window. Then I want to be able to open it up on another computer and still see that text. So far all that's happened is the text resets to a blank field after it's closed, which I expected, I just don't know how to fix it lol I'm using IE and not Firefox. For some reason, on my homepage (http://www.projectdisobey.com/disobeyclothing/) an extra '</div> <!-- content #end -->' is being created in the page source, AFTER the closing 'body' and 'html' tags. There is no mention of '</div> <!-- content #end -->' in my 'footer.php' file, so why does this show up in the page source? Please see the attachment. If anybody could point me in the right direction as to why this might be occurring, and how I might fix it, I would be eternally grateful! Thanks! I cant open my php file...ive downloaded wampserver to support the file but it still doesnt open...wat could b the problem here??? Hi Guys/Girls, Quick Question im in the process of creating a website, and i have a table that contains links to other pages on the website, im having trouble on one, what im trying to achieve is when they press the link which is named "Add to Favourites" then it will automatically open there "Add to Favourites" tab "located top of the browser" but unfortunately its not working for me :-/ im currently using firefox for my browser im not to sure if this is the correct place to paste such an issue but im not to sure...... my snippet of the code is below, hope some one can help me. HTML Code: <tr style="Height:20px"> <td style="width:20px"><img src="/images/TriangleOnBlue.jpg" width="10" height="10" border="0" align=middle></td> <td style="width:108px" align=left valign=middle><a href="javascript:window.external.AddFavorite(location.href,document.title);" class="BlueTiny">Add to Favorites</a></td> </tr> I will also point out that all my Java is enabled.... Hope someone can help. I created a page with a chromeless window. Clicking on 'enter' on the index page will open the homepage in a chromeless window. However, whenever you click enter on the index page, the index page itself is also loading the homepage. (so it's double, one on the index page and one in a chromeless window). How can I get it to stop, so that it only loads a chromeless window and the index page stays the same? I used the chromeless window codes from the following page: http://www.lissaexplains.com/javascript9.shtml Can someone post the code I would use to have a hyperlink on our webpage that would give visitors the option to view or download a pdf? Thanks! how can i make the open a new window code work as it is in this include file: <div id="footer"> <img src="images/footer.jpg" alt="" width="998" height="45" border="0" usemap="#footer" /> <map name="footer" id="Map2"> <area shape="rect" coords="0,0,162,45"href="http://www.myspace.com/spittinknowledge" alt="myspace" /> <area shape="rect" coords="184,0,308,45" href="affiliates.shtml" alt="affiliates" /> <area shape="rect" coords="328,0,482,45" href="#" onclick="MyWindow=window.open('webmaster.shtml','Contact Spittin-knowledge.com webmaster','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes, width=525,height=560'); return false;"></a> alt="webmaster" /> <area shape="rect" coords="501,0,655,45" href="disclaimer.shtml" alt="disclaimer" /> <area shape="rect" coords="672,0,998,45" href="#top"/> </map> </div><!-- end of nav --> I have a link on my website that opens up a new window, and that new window opens up and is resized to be smaller at 400X300. It works just fine on Internet Explorer and Safari, but when it's in Firefox the new window opens up on a separate tab in the same browser window and causes the whole window to resize to 400X300. Is there a way to fix this? Like is there a better coding to make sure Firefox will open this link in a new window for sure, and not just a separate tab? I'm using the coding target="_blank" right now..... heya guys i want to open a webpage in a new window when i click on a hotspot. can anyone tell me what i need to do? frosty |