I'm trying to use CDATA tags in a PHP doc, but unfortunately when it outputs, anything between the CDATA tags is commented out. Does anyone know why?
$fields = 'data=<?xml version="1.0" encoding="UTF-8"?>
<post>
<employer_email>#</employer_email>
<employer_password>#</employer_password>
<position_title>'.$post_title.'</position_title>
<position_ref>'.$postID.'</position_ref>
<position_region>'.$region1.'</position_region>
<position_city>'.$position_city1.'</position_city>
<position_industry>'.$job_category1.'</position_industry>
<position_job_type>'.$job_type1.'</position_job_type>
<position_job_description><![CDATA['.$mm.']]></position_job_description>
</post>';
echo "<pre>";
print_r ($fields);
Then it outputs the product_job_description
section like this:
<position_job_description><!--[CDATA[Associate Dentist /Penzance, Cornwall / Full Time.MBR Dental are currently assisting a dental practice located in Penzance, Cornwall to recruit an Associate Dentist to join their team.Full Time opportunity.5000 UDAs.£10 per UDA.Strong Private Potential.45/55 Private Fees .For more information please send your CV to #]]--></position_job_description>