My Blog List

Tuesday, June 26, 2012

free template site

free template site

http://stoptospade.tistory.com/17

Sunday, June 24, 2012

mysql unique setting

ALTER TABLE [table] ADD UNIQUE (USER_ID)

First of all, you can make some column unique when creating table

CREATE TABLE Persons
(
seq int NOT NULL,
LastName varchar(255) NOT NULL,
FirstName varchar(255),
UNIQUE (seq)
)
Second, when you alter table.

ALTER TABLE TB_USER ADD UNIQUE (USER_ID);


Thursday, June 21, 2012

Tuesday, June 19, 2012

javaScript Confirm Box


<!DOCTYPE html>
<html>
<body>

<p>Click the button to display a confirm box.</p>

<button onclick="myFunction()">Try it</button>

<p id="demo"></p>

<script type="text/javascript">
function myFunction()
{
var x;
var r=confirm("Press a button!");
if (r==true)
  {
  x="You pressed OK!";
  }
else
  {
  x="You pressed Cancel!";
  }
document.getElementById("demo").innerHTML=x;
}
</script>

</body>
</html>

Thursday, June 14, 2012

load balancing apache -> http.conf




LoadModule jk_module modules/mod_jk.so



JkWorkerProperty worker.list=ajp13w
JkWorkerProperty worker.ajp13w.type=lb
JkWorkerProperty worker.ajp13w.balanced_workers=WAS1,WAS2
JkWorkerProperty worker.sticky_session=true


JkWorkerProperty worker.WAS1.type=ajp13
JkWorkerProperty worker.WAS1.host=localhost
JkWorkerProperty worker.WAS1.port=8009
JkWorkerProperty worker.WAS1.lbfactor=1

JkWorkerProperty worker.WAS2.type=ajp13
JkWorkerProperty worker.WAS2.host=192.168.0.32
JkWorkerProperty worker.WAS2.port=8009
JkWorkerProperty worker.WAS2.lbfactor=1



JkLogFile logs/jk.log
JkLogLevel info
JkLogStampFormat "[%a %b %d %H:%M:%S %Y]"
#JkMount /*.jsp ajp13w
JkMount /* ajp13w
JkMount /example/* ajp13w

JkUnMount /*.html ajp13w
JkUnMount /*.gif ajp13w
JkUnMount /*.jpg ajp13w
#JkMount /servlet/* ajp13w

Apache2.2 and Tomcat 7.x

톰캣 7.x  + 아파치 2.x + mod_jk

http://blog.naver.com/PostView.nhn?blogId=gkdrhd93&logNo=10117411982