Skip to main content
added 119 characters in body
Source Link
greenstork
  • 14.5k
  • 2
  • 45
  • 71

Visualforce takes over element Ids and often alters them. Have you checked the actual Id that is being rendered by Visualforce on your button? You may need to get creative with your Javascript to select your button.

EDIT: One common way to deal with this Id issue is to use the jQuery EndsWith() selector:

j$('[id$="btn"]');

Visualforce takes over element Ids and often alters them. Have you checked the actual Id that is being rendered by Visualforce on your button? You may need to get creative with your Javascript to select your button.

Visualforce takes over element Ids and often alters them. Have you checked the actual Id that is being rendered by Visualforce on your button? You may need to get creative with your Javascript to select your button.

EDIT: One common way to deal with this Id issue is to use the jQuery EndsWith() selector:

j$('[id$="btn"]');
Source Link
greenstork
  • 14.5k
  • 2
  • 45
  • 71

Visualforce takes over element Ids and often alters them. Have you checked the actual Id that is being rendered by Visualforce on your button? You may need to get creative with your Javascript to select your button.