Note that there are some explanatory texts on larger screens.

plurals
  1. POjquery don't continue executing rest of javascript code
    primarykey
    data
    text
    <p>This is my first question on this site (but the other discussions have helped me). </p> <p>In the following code:</p> <pre><code>$('#selObra').change(function() { var id_obra = $(this).val(); if (id_obra == '-1') { //Elimino todos los renglones de la tabla $('#tblSubcontratos tbody tr').remove(); } else { $('#tblSubcontratos').append('&lt;tr&gt;&lt;td class="center" colspan="6"&gt;&lt;img src="images/ui-anim_basic_16x16.gif" height="16" width="16" style="margin-left:auto;margin-right:auto" /&gt;&lt;/td&gt;&lt;/tr&gt;'); //Obtengo todos los contratos de la obra seleccionada $.ajax({ type: 'GET', dataType: 'xml', url: 'get_subcontratos.php', data: 'id_obra=' + id_obra, success: function(xml) { $('#tblSubcontratos tbody tr').remove(); if ($(xml).find('subcontratos').attr('status') == 'OK') { $(xml).find('subcontrato').each(function(){ var id_subcontrato = $(this).find('id_subcontrato').text(); var id_obra = $(this).find('id_obra').text(); var nombre_obra = $(this).find('nombre_obra').text(); var id_contratista = $(this).find('id_contratista').text(); var nombre_contratista = $(this).find('nombre_contratista').text(); var fecha_subcontrato = $(this).find('fecha_subcontrato').text(); var strRow = '&lt;tr class="ui-widget-content"&gt;' + '&lt;td&gt;' + id_subcontrato + '&lt;/td&gt;' + '&lt;td&gt;' + nombre_obra + '&lt;/td&gt;' + '&lt;td&gt;' + nombre_contratista + '&lt;/td&gt;' + '&lt;td&gt;' + fecha_subcontrato + '&lt;/td&gt;' + '&lt;td class="center view_details"&gt;&lt;img src="images/view.gif" /&gt;&lt;/td&gt;' + '&lt;td class="center"&gt;&lt;input type="radio" name="subcontratoSeleccionado" /&gt;&lt;/td&gt;' + '&lt;/tr&gt;'; $('#tblSubcontratos tbody').append(strRow); }); } else { var errno = $(xml).find('errno').text(); var error = $(xml).find('error').text(); $('#message').html(errno + ' - ' + error); $('#message').dialog('open'); } } }); } $("#divSubcontratos").dialog( "option", "position", 'center' ); }); </code></pre> <p>Centering the dialog is never executed... I can't see the mistake, the last line that firebug higlights is the bracket to close the else instruction... any comments will be appreciated. Thanks in advance.</p> <p>Marco.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload