Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [PHP/Symfony/Prototype] problem z ajax.update
Exek
post 10.03.2008, 12:02:19
Post #1





Grupa: Zarejestrowani
Postów: 120
Pomógł: 10
Dołączył: 16.08.2007

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


Witam, mam problem z symfony + ajax.update.
Updatuje diva za pomocą ajax.update (metodą GET) i dostaje coś takiego (poprawne):
(kod przechwytuję firebugiem)

Kod
  <table class="bright-title">
  <tr>
    <td class="bright-title-left"></td>
    <td class="bright-title-center">[T]Edycja profilu[/T]</td>
    <td class="bright-title-right"></td>
  </tr>
</table>    

    <form name="editUser" id="editUser" onsubmit="new Ajax.Updater('main-content-ajax', '/~hellcoder/ogloszenia/web/frontend_dev.php/edycja-profilu', {asynchronous:true, evalScripts:true, encoding: 'utf-8', parameters:Form.serialize(this)}); return false;" action="/~hellcoder/ogloszenia/web/frontend_dev.php/edycja-profilu" method="post">

ąść

<div class="form-box">
[ CUT ... ]


Po zrequestowaniu za pomocą POST dostaję coś takiego:

Kod
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html><body>

<table class="bright-title"><tr>
<td class="bright-title-left"></td>
    <td class="bright-title-center">[T]Edycja profilu[/T]</td>
    <td class="bright-title-right"></td>
  </tr></table>

<form name="editUser" id="editUser" onsubmit="new Ajax.Updater('main-content-ajax', '/~hellcoder/ogloszenia/web/frontend_dev.php/edycja-profilu', {asynchronous:true, evalScripts:true, encoding: 'utf-8', parameters:Form.serialize(this)}); return false;" action="/~hellcoder/ogloszenia/web/frontend_dev.php/edycja-profilu"  method="post">

  <div class="form-box">
    <div class="form-box-title">
      W formularzu wyst&Auml;…pi&Aring;‚yb&Aring;‚&Auml;™dy: </div>

[CUT ...]


Jak widać pojawia się jakiś DOCTYPE, head, body z kosmosu. Przy okazji psuje się też kodowanie UTF-8.

Używam symfony 1.0.11 i prototype 1.6.0.2.

Czy ktoś wie w czym może leżeć problem?
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi (1 - 2)
Cysiaczek
post 10.03.2008, 12:30:23
Post #2





Grupa: Moderatorzy
Postów: 4 465
Pomógł: 137
Dołączył: 26.03.2004
Skąd: Gorzów Wlkp.




Wygląda to jak komunikat błędu. Masz może włączoną opcje repopulate: przy walidacji tego formularza? Ten kod wyglada jak komunikat od repopulate.
Pozdrawiam.


--------------------
To think for yourself you must question authority and
learn how to put yourself in a state of vulnerable, open-mindedness;
chaotic, confused, vulnerability, to inform yourself.
Think for yourself. Question authority.
Go to the top of the page
+Quote Post
Exek
post 12.03.2008, 12:17:55
Post #3





Grupa: Zarejestrowani
Postów: 120
Pomógł: 10
Dołączył: 16.08.2007

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


Człowieku, jesteś geniuszem! biggrin.gif

Winę ponosi filtr sfFillin, z tego co zauważyłem to ładuje/zwraca on stronę przez phpowską klasę DomDocument i pewnie stąd te dodatkowe tagi.

PS. Wie ktoś jak wyłączyć takie zachowanie DomDocument? tongue.gif
Go to the top of the page
+Quote Post

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

 



RSS Wersja Lo-Fi Aktualny czas: 25.06.2025 - 18:41