I have a table whose values are displayed from a database but on the 8th row second column it displays a value i.e. 8 which is a Canadian province i.e. ‘Ontario’ now i want the name of the province instead of the values. This is what the old site used and therefore, i do not want to change the data in the database as the it is really big in size. I want to use javascript so that it only shows this for the user to read rather than changing the values in the database.
The data is displaed in a table
<table>
<tr></tr>
...8th row<tr><td></td><td>Value lies here i.e. '8'</td></tr>
</table>
Here is how i want it
if the value is “0” it should show “Alberta”
if the value is “1” British Columbia
if the value is “2” Manitoba
if the value is “3” New Brunswick
if the value is “4” Newfoundland
if the value is “5” Nova Scotia
if the value is “6” Northwest Territories
if the value is “7” Nunavut
if the value is “8” Ontario
if the value is “9” Prince Edward Island
if the value is “10” Quebec
if the value is “11” Saskatchewan
if the value is “12” Yukon
“Thanks but the form is on a different page than where it shows the value” It should be using a if else statement that if 8th row second column shows ‘8’ then the value should display as ‘Ontario’
seems like a bad solution, but a simple selector
EDIT: