Aditya Bhanose

+ Follow
since Nov 26, 2008
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Aditya Bhanose

Yes, my problem is about Byte order mark only. I think there is no way we can handle this in code.
I need to provide a proper XML editor to end users.
I have functionality which reads XML file, gets data from the nodes and take an appropriate action to execute the business logic. I am using the below code:

SAXBuilder builder = new SAXBuilder();
Document doc =;

XML file I am getting as an input is modified by the end user. He adds the data into it and then using my functionality that data is getting into system. In this scenario I am getting an JDOM parser exception "Document root element is missing.."
Reason is the editor used to modify XML appends some charachters at the begining of file and it fails in reading this.
Is there any way I can handle this problem? Either removing this chars or ignoring them. These chars are not predicatable, those might be some garbage values also.

I think I should go with using separator or manually adding spaces between the words.

Thanks For Reply

[ November 26, 2008: Message edited by: Aditya Bhanose ]
I need to display two diffrent values in the select box.

<option><%=lang.getName()%> <%=lang.getShortName()%> </option>

In this it becomes difficult for user to diffrentiat both the values. Putting a separater(-) is also not that helpful. I am looking for solution where user can easyly see both the values.

I have data like:

United States Of America USA
India Ind
South Africa SA

You can see first value in each row is not of fixed width, and Its difficult to understand which is short name (2nd value).Is there any way we can give fixed width to values in option?
I want to create a combobox in html where each word in each selection is a different color.

The following code makes an option in the combo box red:

<option style="color: #FF0000">Combo option</option>

However, I would like the word "Combo" to be red, and the word "option" to be green.

I've tried the following:

<option style="color: #FF0000">Combo <span style="color: #00FF00">option</span></option>

and also:

<option><span style="color: #FF0000">Combo</span> <span style="color: #00FF00">option</span></option>

but neither worked.