• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Bear Bibeault
  • Devaka Cooray
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Knute Snortum
  • Junilu Lacar
  • paul wheaton
Saloon Keepers:
  • Ganesh Patekar
  • Frits Walraven
  • Tim Moores
  • Ron McLeod
  • Carey Brown
  • Stephan van Hulst
  • salvin francis
  • Tim Holloway

calling java Script functin with in external jsp files  RSS feed

Ranch Hand
Posts: 174
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a js file in separate place.
It is icon.js

I have two separate jsp files too.

       <script src="js/icon.js"></script>

           <input type="image" class="btn" id="home" name="home" style="float: left" src="img/home.png" >
           <input type="image" class="btn" id="user" name="user" style="float: right; margin-left: 100px" src="img/user.png" >

           <input type="image" class="btn" id="delete" name="delete" style="float: right; margin-left: 40px" src="img/delete.png" onclick="deleteRow('dataTable')" disabled >
           <input type="image" class="btn" id="save" name="save" style="float: right; margin-left: 40px" src="img/save.png" onclick="readDataToSave('dataTable');" disabled >
           <input type="image" class="btn" id="modify" name="modify" style="float: right; margin-left: 40px" src="img/modify.png" onclick="modifyRow('dataTable')"disabled>
           <input type="image" class="btn" id="add" name="add" style="float: right; margin-left: 40px" src="img/add.png" onclick="clickSearch();addRow('dataTable');">


please don't mind about styles and other onclick functions...

next jsp file is

I want is this.

1.when i click add button only save button must be enable
2.when I click search button all save ,delete and modify buttons must be enable and add is disabe.

but when i run this only first task is success.But 2nd one???
chamini prashakthi
Ranch Hand
Posts: 174
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
yeh found the soluion
It was my mistake of

i add it with correct path.
now it is fine...

But now problem is when i click search button the buttons were suddenly enable and again become disable state.
Can soe one have a solution for this???
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!