developer.jelix.org is not used any more and exists only for history. Post new tickets on the Github account.
developer.jelix.org n'est plus utilisée, et existe uniquement pour son historique. Postez les nouveaux tickets sur le compte github.

Opened 11 years ago

Closed 11 years ago

#948 closed bug (fixed)

htmlfragment : $this->_charset not properly define

Reported by: foxmask Owned by: laurentj
Priority: normal Milestone: Jelix 1.1.4
Component: jelix:core response Version: 1.1.3
Severity: minor Keywords:
Cc: Blocked By:
Blocking: Documentation needed: no
Hosting Provider: Php version:

Description

on line 145 of the class jResponseHtmlFragment.class.php

$this->_charset

is not define at all, like it is the case for the html response class.

we should declare $_charset, then set it in the constructor ; just like jResponseHtml

Attachments (1)

jresponsehtmlfragment_ticket_948.patch (1.4 KB) - added by foxmask 11 years ago.

Download all attachments as: .zip

Change History (7)

comment:1 Changed 11 years ago by foxmask

i could submit a patch later this evening

comment:2 Changed 11 years ago by laurentj

  • Severity changed from normal to minor

don't create a _charset property, just call directly $gJConfig->charset

comment:3 Changed 11 years ago by foxmask

If i'm not wrong jResponseHtmlFragment class was created from jResponseHtml where in this one the property $_charset is defined properly and set in the contructor by $gJConfig->charset

Es-tu sûr de preferer utiliser $gJConfig->charset et pas la façon dont a été codée jResponseHtml (à savoir definiton de $_charset + assignation dans le constructeur et utilisation tout au long de la class) ?

ps : je ne reproduis plus l'erreur. pourtant la ligne 145 est fausse (non?) . Et pire que cela, avec jResponseHtml cette fois ci , si je commente la ligne protected $_charset, je n'obtiens aucune erreur avec les "responses" html .

Changed 11 years ago by foxmask

comment:4 Changed 11 years ago by foxmask

  • review set to review?

j'ai fait comme tu le voulais avec $gJConfig.

comment:5 Changed 11 years ago by laurentj

  • review changed from review? to review+

ok. to commit on the trunk and 1.1.x branch.

comment:6 Changed 11 years ago by foxmask

  • Resolution set to fixed
  • Status changed from new to closed

r1449. fix in trunk and branch 1.1.x

Note: See TracTickets for help on using tickets.