Ever felt like ASP.NET web pages doing postback by themselves? Or better, someone click on Enter and instead clicking on the default button on the webpage, the page just "refreshing" itself.
Well, try this great code snippets in your body tag:
BODY onkeydown = "return (event.keyCode!=13)"
This code will prevent auto postback of your page when user clicks on Enter. More options are available in the mentioned webpage.
Keep Performing!
Monday, June 29, 2009
Sunday, June 21, 2009
How to choose a PHP IDE?
Check out this great review of PHP IDE features, what you need, and which product has one.
The Big PHP IDE Test: Why Use One And Which To Choose
The Big PHP IDE Test: Why Use One And Which To Choose
Tuesday, June 16, 2009
Shrinking Your SQL Server Log File
Well, did you ever found out that your MS SQL Server transaction log is just too large and its utilization is just too low (lets say 60GB size and only 100MB are used...) and SQL Server just don't let you shrink it?
Well Andrew Arnott found a great solution to get rid of this wasted space and truncate the log:
backup log [dbname] with truncate_only
go
DBCC SHRINKDATABASE ([dbname], 10, TRUNCATEONLY)
go
Keep Performing
RockeTier 1 Billion Events per Day Development Team
Well Andrew Arnott found a great solution to get rid of this wasted space and truncate the log:
backup log [dbname] with truncate_only
go
DBCC SHRINKDATABASE ([dbname], 10, TRUNCATEONLY)
go
Keep Performing
RockeTier 1 Billion Events per Day Development Team
Wednesday, June 10, 2009
Eclipse plugins
Morning there
Yesterday I visited the Aluna's "how to buid development enviroment in the Java / JavaEE world"; couple of words about it firstly:
On the other side of the Whale center there was a dentists congress of something,
and the most surreal thing there was an exhibition of the 3M tools for dentists right next to the ice cream and sweets...
Now to business: I would like to write about some interesting eclipse plugins
1. Tptp - Eclipse Test & Performance Tools Platform Project
o Test and performance tools platform
o Does not work with java 6 out of the box
o For java 6 you need to download special agent.
o Supports unitests
o More info - http://www.eclipse.org/tptp/
2. EMF - Eclipse Modeling Framework
o Provides the ability to create UML diagram \ class diagram and other design tools
o Provides simple modeling tools development framework
3. Bird
o Provides the ability to create reports
4. Log4e
o Enriches your environment with the ability to create logging mechanism in your code .
o More info - http://log4e.jayefem.de/
5. FileSync
o Automatically copy every change in the eclipse to the file path.
o More info -http://andrei.gmxhome.de/filesync/index.html
Yesterday I visited the Aluna's "how to buid development enviroment in the Java / JavaEE world"; couple of words about it firstly:
On the other side of the Whale center there was a dentists congress of something,
and the most surreal thing there was an exhibition of the 3M tools for dentists right next to the ice cream and sweets...
Now to business: I would like to write about some interesting eclipse plugins
1. Tptp - Eclipse Test & Performance Tools Platform Project
o Test and performance tools platform
o Does not work with java 6 out of the box
o For java 6 you need to download special agent.
o Supports unitests
o More info - http://www.eclipse.org/tptp/
2. EMF - Eclipse Modeling Framework
o Provides the ability to create UML diagram \ class diagram and other design tools
o Provides simple modeling tools development framework
3. Bird
o Provides the ability to create reports
4. Log4e
o Enriches your environment with the ability to create logging mechanism in your code .
o More info - http://log4e.jayefem.de/
5. FileSync
o Automatically copy every change in the eclipse to the file path.
o More info -http://andrei.gmxhome.de/filesync/index.html
Sunday, June 7, 2009
Hibernate Mapping Cheat Sheet
Ever been developing with Hibernate, and wished something would save your Time and Sanity? Here it is!
http://ndpsoftware.com/HibernateMappingCheatSheet.html
http://ndpsoftware.com/HibernateMappingCheatSheet.html
Thursday, June 4, 2009
Java Types and Annotations for Web Services
Sometimes you want to send data between different applications, different programming languages, different machines etc.
One of the standard ways of doing so is using SOAP. Java has built in support for it, just define the following. And then call Endpoint.publish(url, new myClass()) and you're done.
@WebService()
@SOAPBinding(parameterStyle=ParameterStyle.WRAPPED,style=Style.RPC)
public class myClass {
@WebMethod(action="myMethod")
public myOutput myMethod(myInput p_input) {
}
}
Then of course you want your input and output to have some structure, so the other application and/or programming language would understand the WSDL.
For that, see the following reference
Mapping Java Types to XML and WSDL Types
One of the standard ways of doing so is using SOAP. Java has built in support for it, just define the following. And then call Endpoint.publish(url, new myClass()) and you're done.
@WebService()
@SOAPBinding(parameterStyle=ParameterStyle.WRAPPED,style=Style.RPC)
public class myClass {
@WebMethod(action="myMethod")
public myOutput myMethod(myInput p_input) {
}
}
Then of course you want your input and output to have some structure, so the other application and/or programming language would understand the WSDL.
For that, see the following reference
Mapping Java Types to XML and WSDL Types
Wednesday, June 3, 2009
Hibernate again
This time , i'm posting here something that did not work for me , however i have found a nice workaround.
The hibernate projection will have to wait
SELECT NAME FROM PRODUCT
Here, the Projection class comes into play. The above query can be rewritten into a Criteria query as:
List products=session.createCriteria(Product.class)
. setProjection(Projection.property(\"name\"))
.list();
Subscribe to:
Posts (Atom)