File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Beginning Java and the fly likes embedding style tag in java syntax Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "embedding style tag in java syntax" Watch "embedding style tag in java syntax" New topic
Author

embedding style tag in java syntax

gradnash nash
Greenhorn

Joined: Mar 14, 2006
Posts: 11
Hello all,

I would like to know whether there is any way for me to embed a style in java like

ifPrint() {
<style> noprint.display:none; </style>
}


Is this possible, please let me know.

Thanks,
Ilja Preuss
author
Sheriff

Joined: Jul 11, 2001
Posts: 14112
Are you perhaps talking about *Javascript*?


The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
Jan Groth
Ranch Hand

Joined: Feb 03, 2004
Posts: 456
or JSP (java server pages)?

you cannot embed anything in your java-code which is not java syntax. but that's obvious ;-)

what you can do is mixing java-code with markup code, which assumes that you are working in a servlet environment. in this case you have to mark the source code (usually a jsp-page) which section contains the markup code (usually html)






[/CODE]
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: embedding style tag in java syntax
 
Similar Threads
CSS : z-index: property not working
how to fetch the value of the checkbox in jsp?
nested tiles
pulling data from xml using javascript
The styleclass on h:selectOneMenu component is not working