looking for some advice if possible, I know next to nothing about js so this has got me stumped but I can't help but think there must be an answer.
The code below appears ~100 times in each page
<script type="text/javascript">
$(function() {
$('#otherdetails_247').ready(function() {
$('#otherdetails_247').height($('#wrapper_247').height());
});
$('#assingeddetails_247').ready(function() {
$('#assingeddetails_247').height($('#assignedname_247').height());
$('#assigned_247').height($('#assingeddetails_247').height());
});
});
</script>
I want to call this from an external js file but the numbers change each time, is there a way to call this whilst changing the numbers using some form of argument passed to the function?
I know that the assingeddetails is spelt wrong but I have inherited this code so can't change that easily!
The code below appears ~100 times in each page
<script type="text/javascript">
$(function() {
$('#otherdetails_247').ready(function() {
$('#otherdetails_247').height($('#wrapper_247').height());
});
$('#assingeddetails_247').ready(function() {
$('#assingeddetails_247').height($('#assignedname_247').height());
$('#assigned_247').height($('#assingeddetails_247').height());
});
});
</script>
I want to call this from an external js file but the numbers change each time, is there a way to call this whilst changing the numbers using some form of argument passed to the function?
I know that the assingeddetails is spelt wrong but I have inherited this code so can't change that easily!