Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [ajax] advajax i kilka funkcji
grzegorz_g
post
Post #1





Grupa: Zarejestrowani
Postów: 259
Pomógł: 0
Dołączył: 26.10.2004

Ostrzeżenie: (0%)
-----


mam oto taki kod
  1. <script language="JavaScript">
  2. advAJAX.setDefaultParameters ({
  3. onSuccess : function(obj) {
  4. if (obj.responseText!="NO") {
  5.  
  6. alert("cos");
  7.  
  8. }
  9. }
  10. });
  11.  
  12.  
  13. function sprawdz() {advAJAX.get({ tag: "spr", url: "includes_bets/live_score_test.php" })}
  14. window.setInterval(sprawdz,10000);
  15.  



teraz zalezy mi by w miejsce funkcji alert("cos"); wstawic kolejne funkcje wykorzystującą advajax:

np.

function wynik() {advAJAX.get({ tag: "wynik", url: "includes_bets/wynik_live.php" })}
function podglad() {advAJAX.get({ tag: "kursy_live", url: "includes_bets/kursy_live.php" })};

już kombinowałem na różne sposoby, mam pytanie czy wogole sie tak da a jezeli tak to może jakas sugestia.

Za wszelkie info dzięki
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi
grzegorz_g
post
Post #2





Grupa: Zarejestrowani
Postów: 259
Pomógł: 0
Dołączył: 26.10.2004

Ostrzeżenie: (0%)
-----


mam taki kod ale on nie wywoluje funckcji wynik(), podglad()

  1. <script language="JavaScript">
  2. advAJAX.setDefaultParameters({
  3.  
  4. onSuccess : function(obj) { alert(obj.responseText); }
  5. });
  6.  
  7. function wynik() {advAJAX.get({ tag: "wynik", url: "includes_bets/wynik_live.php" })};
  8. function podglad() {advAJAX.get({ tag: "kursy_live", url: "includes_bets/kursy_live.php" })};
  9.  
  10.  
  11.  
  12.  
  13. advAJAX.setDefaultParameters ({
  14. onSuccess : function(obj) {
  15. if (obj.responseText!="NO") {
  16.  
  17. wynik();
  18. podglad();
  19.  
  20. }
  21. }
  22. });
  23.  
  24.  
  25. function sprawdz() {advAJAX.get({ tag: "spr", url: "includes_bets/live_score_test.php" })}
  26. window.setInterval(sprawdz,10000);
  27.  
  28.  
  29.  
  30.  
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
2 Użytkowników czyta ten temat (2 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 15.10.2025 - 17:15