Include one more condition to run Script

Asked

Viewed 54 times

0

 $outracondicao = 'S';

    $script = new TElement('script'); 
    $script->type = 'text/javascript'; 
    $script->add("$(document).ready(function(){
    window.setTimeout(function(){ 
    var results = new RegExp('[\?&]class=([^&#]*)').exec(window.location.href);
    if('".__CLASS__."' == results[1])  
    __adianti_load_page('engine.php?class=AtendimentosEmProcessoList&method=onReload');
  }, 5000);
  • 1

    Clarify your specific issue or add other details to highlight exactly what you need. The way it’s written here, it’s hard to know exactly what you’re asking. See the How to Ask page for help clarifying this question.

  • 1

    As an addition to what has already been said, do not ask questions that only have code and not detailed description of the problem. Also missing include appropriate language tag, whether it appears to be php

  • Sorry staff, I’m new here. I have a PHP system with a datagrid that I need to update automatically. For this I found the scritp in javascritp above that works very well. However in this grid I have a button that opens a Twindow window and as the settimer is still turned on ends up closing my Twindow window. So I need to put in the script one more condition for it to run. Thanks.

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.