Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

424
Views
WARNING 'SimpleXMLElement::addChild(): unterminated entity reference

Trying to create xml file and get warning.

WARNING 'SimpleXMLElement::addChild(): unterminated entity reference Brantford Jonson'

so when i try to open xml file get error

This page contains the following errors:

error on line 3 at column 4: StartTag: invalid element name
Below is a rendering of the page up to the first error.,

i think my error is related with this php warning.

here is relevant code

  if ($value instanceof Zend_Config) {
       $child = $xml->addChild($key);
       $this->_addBranch($value, $child, $xml);
      } else {

          $xml->addChild($key, (string) $value);
             }

can you help me to pin point why this error occurs. Tried something like this

if ($value instanceof Zend_Config) {
     $child = $xml->addChild($key);
      $this->_addBranch($value, $child, $xml);
  } else {     
       $xml->$key((string) htmlspecilalchars($value));
      }
about 4 years ago · Santiago Trujillo
1 answers
Answer question

0

I ran across the error when there was an ampersand "&" in my XML. Maybe try escaping the string with htmlspecialchars().

about 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!