Se añade version 1.0 de parser html

correciones menores a codigo anterior realizado.
Se añade html de prueba
Se añaden librerias de restapi
parent 6f53d926
......@@ -482,7 +482,7 @@ class CampaniaController extends Controller {
return $this->render("backend_content/pages/campanias/listadoCampanias.html.twig", array("campanias" => $campanias));
}
public function cargarHtmlFrontAction() {
public function cargarHtmlFrontAction(Request $request) {
$data = array('id' => 24);
$data_json = json_encode($data);
$htmlContent = array();
......@@ -498,6 +498,7 @@ class CampaniaController extends Controller {
$ch = curl_init($url);
//curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json'));
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_USERAGENT, $request->headers->get('User-Agent'));
curl_setopt($ch, CURLOPT_POSTFIELDS, $data_json);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_TIMEOUT, 60);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment