[CLOSED] Can't use more than one button
Posted: 2020-01-23 16:32
Hi,
Thank you for the Library..... I have a question though.... In the code below when I add it to the Event-tv.js it renders the 2 buttons but the link that it will go to is the same as the last link.... in other words if I even add another button it will show nice but all the buttons will go to the 3rd link
What do I have to do if I have more than one button and each button is separate?
jQuery(function(){
jQuery('#Filter').after('<button class="btn btn-warning" type="button" id="filter-button"><i class="glyphicon glyphicon glyphicon-link"></i> Go To - Event Dashboard</button>');
jQuery('button[id=filter-button]').click(function(){
window.location = 'dashboard-event-operations.php';
});
});
jQuery(function(){
jQuery('#Filter').after('<button class="btn btn-warning" type="button" id="filter-button"><i class="glyphicon glyphicon glyphicon-link"></i> Create a new event</button>');
jQuery('button[id=filter-button]').click(function(){
window.location = 'Event_view.php?addNew_x=1';
});
});
Thank you for the Library..... I have a question though.... In the code below when I add it to the Event-tv.js it renders the 2 buttons but the link that it will go to is the same as the last link.... in other words if I even add another button it will show nice but all the buttons will go to the 3rd link
What do I have to do if I have more than one button and each button is separate?
jQuery(function(){
jQuery('#Filter').after('<button class="btn btn-warning" type="button" id="filter-button"><i class="glyphicon glyphicon glyphicon-link"></i> Go To - Event Dashboard</button>');
jQuery('button[id=filter-button]').click(function(){
window.location = 'dashboard-event-operations.php';
});
});
jQuery(function(){
jQuery('#Filter').after('<button class="btn btn-warning" type="button" id="filter-button"><i class="glyphicon glyphicon glyphicon-link"></i> Create a new event</button>');
jQuery('button[id=filter-button]').click(function(){
window.location = 'Event_view.php?addNew_x=1';
});
});