Sunday, February 17, 2013
How to Take Ownership of a locked folders in Windows 7
takeown /f "C:\Locked Directory" /r /d y
icacls "C:\Locked Directory" /grant administrators:F /t
Tuesday, December 11, 2012
How to make inner float div inside the outer div
When you put some float div inside another div, The outer div will collapse in other words the size of dimension the outer div will small than the inner float div.
The solution is append a div with clear and block style in the end of the other float inner div as below:
<div id="outer_div">
<div class="float-style">Item 1</div>
<div class="float-style">Item 2</div>
<div class="float-style">Item 3</div>
<div style="clear:both;display:block;"></div>
</div>
Solution 2: using overflow:auto; in the outer div style can also prevent outer div collapsed. But this method may cause outer div appear scroll bar when new div adding to it.
<div id="outer_div" style="overflow:auto;">
<div class="float-style">Item 1</div>
<div class="float-style">Item 2</div>
<div class="float-style">Item 3</div>
<div style="clear:both;"></div>
</div>
related link: http://css-tricks.com/all-about-floats/
The solution is append a div with clear and block style in the end of the other float inner div as below:
<div id="outer_div">
<div class="float-style">Item 1</div>
<div class="float-style">Item 2</div>
<div class="float-style">Item 3</div>
<div style="clear:both;display:block;"></div>
</div>
Solution 2: using overflow:auto; in the outer div style can also prevent outer div collapsed. But this method may cause outer div appear scroll bar when new div adding to it.
<div id="outer_div" style="overflow:auto;">
<div class="float-style">Item 1</div>
<div class="float-style">Item 2</div>
<div class="float-style">Item 3</div>
<div style="clear:both;"></div>
</div>
related link: http://css-tricks.com/all-about-floats/
Friday, November 23, 2012
Create log off message for Windows
- Click Start > Run, type “regedit” click Ok button. Registry Editor window will popup.
- Find this path from left side of Registry Editor window: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon
- Double click LegalNoticeCaption from right side Registry Editor window. This will popup Edit String window. Type in Value data any name that you want to be your message window title. Click Ok button.
- Double click LegalNoticeText from right side Registry Editor window. This will popup Edit String window. Type in Value data any message, this message will show up on your message window. Click Ok button. Close your Registry Editor window.
- Log off from your computer.
Monday, November 12, 2012
Wednesday, November 7, 2012
How to check which process using TCP/IP Ports in Windows
Run the following command from a command prompt to find the PID of the process which is using TCP port 80 and/or 443.
netstat -aon | find ":80"
netstat -aon | find ":443"
You will see an output similar to the following. Remember the actual PID will vary from case to case.
TCP 0.0.0.0:80 0.0.0.0:0 LISTENING 3604
TCP 0.0.0.0:443 0.0.0.0:0 LISTENING 3320
Now using Task Manager you can easily find out to which process the above PID belongs and take appropriate action.
http://support.microsoft.com/kb/973094
Friday, July 13, 2012
Tuesday, July 10, 2012
Page Layout Using DIV
100% height and scroll able div
<html>
<body style="overflow:hidden;">
<div style="overflow:auto; position:absolute; top: 0px; left:0px; right:0px; bottom:0px">
</div>
</body>
</html>
Fix height header and footer and scroll able main content
<html>
<body style="overflow:hidden;">
<div id="header" style="overflow:hidden; position:absolute; top:0; left:0; height:50px;"><div>
<div id="leftNav" style="overflow:auto; position:absolute; top:50px; left:0px; right:200px; bottom:50px;"></div>
<div id="mainContent" style="overflow:auto; position:absolute; top:50px; left: 200px; right:0px; bottom:50px;"></div>
<div id="footer" style="overflow:hidden; position:absolute; bottom:0; left:0; height:50px"></div>
</body>
</html>
Note: for IE the main content div require doctype definition, without this the div height will not expand to the bottom position.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
Subscribe to:
Posts (Atom)

