Steve McCann

Ranch Hand
+ Follow
since Oct 20, 2004
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Steve McCann

I managed to do what I was after by creating a new managed bean which reads the .properties and then reference that to the parameter.

Should have thought about it a little more before posting.

Thanks for your help Tim.

Cheers
Steve
[ November 05, 2008: Message edited by: Steve McCann ]
9 years ago
JSF
I agree with what you are suggesting, though unfortunately in this case I don't think it solves my problem.

I am using a 3rd party API which has several JSF backing beans predefined in the faces-config.xml. One of these requires the host name (or IP) of a mapping server and it is this that I would like to change.


I would like to be able to set this something like

Which would then be set via a .properties file in my JBoss server.

Cheers
Steve
9 years ago
JSF
Hi

I have a JSF application that is going to be deployed on two different servers. Each copy of the application needs to access a service on one of another set of two servers.
e.g.
App on web server 1 ---> service running on Server A
App on web server 2 ---> service running on Server B

I am currently setting the host of the service inside my faces-config.xml file, but what I would like to do is set this with some kind of placeholder value which would tell the app to read this from another file, e.g. a properties file. I could then deploy the app without any changes onto any server and the external properties would take care of the host name value.

I have done something similar using Spring's config files, but can't get it to work in my faces-config. Is this possible?

Many thanks.
Steve
[ November 05, 2008: Message edited by: Steve McCann ]
9 years ago
JSF

Of course if your document was written by bozo software, and it doesn't correctly state its encoding...


Got it in one.
[ June 14, 2007: Message edited by: Steve McCann ]
Hi Manish

When you instantiate the StreamReader/Writer you can specify the character set to be used. Check out the Charset class for more info.

For example:


Cheers
Steve
The HWPF section covers Word files.

Cheers
Steve
[ May 31, 2006: Message edited by: Steve McCann ]
11 years ago
Check out the Jakarta POI project which does just this.

Cheers
Steve
[ May 31, 2006: Message edited by: Steve McCann ]
11 years ago
Hi

I have a need to convert static HTML pages into RTF dynamically for download.
Does anyone know of a tool/tools that can do this?

Cheers
Steve
11 years ago
JSP
Thanks Jessica.

Out of interest, how do you process your SSI's? I have heard that you can also use Tomcat for this but understood that using Apache in front of Jboss was the 'preferred' method.

Thanks.

Steve
12 years ago
Hi Jessica

I am using Jboss version 4.0.2.

I did a simple jsp page as you suggested to test with a Struts action that returns to the same page:

The first time I access the page the SSI is at the top as expected. Once I go through the action and the jsessionid is in the URL I don't see the SSI. If I manually remove the jsessionid from the URL it is back again. (I have cookies enabled.)

The only difference is ;jsessionid=A50BC28A812D3F20500898AC44C02ADF is appended to the URL in the second case. Also I am using Apache to process the SSI instead of Tomcat/Jboss.

Thanks
Steve
[ December 07, 2005: Message edited by: Steve McCann ]
12 years ago
Hi

I am having some trouble with server side includes when the jsessionid is added to the URL - i.e. they are not included at all and I can see the #include statements in the page source.

Once the session cookie has been set and the URL does not have the session id then everything works fine again.

Has anyone else overcome this problem?

Cheers
Steve
12 years ago
Got it now - thanks Sanju.

Cheers
Steve
[ November 29, 2005: Message edited by: Steve McCann ]
12 years ago
Hi
If I do not specify a session timeout in the web.xml of a webapp, is there a default value that is used or defined somewhere else? I am using JBoss 4.0.2.

Thanks
Steve
12 years ago
Hi Pete

You should not compare Strings with ==. This compares them and returns true if they are the same String rather than having the same value. Try replacing that line and use the String's equals() method like this:


Cheers
Steve
12 years ago
JSP

I thought of that, but the performance isn't the best and neither is the design.


I have used this design on a productive system and it worked well. The customer was very happy and due to it's flexibility the same db schema and application was used for further projects with some minor cosmetic changes. Consider that although you may lose a little performance in having this design, you gain huge amounts in flexibility.

Steve
[ November 10, 2005: Message edited by: Steve McCann ]
12 years ago