From e23c41f96777c644b73491c266ecd3686df70dfb Mon Sep 17 00:00:00 2001 From: fredyrivera Date: Tue, 10 Oct 2017 20:40:23 -0500 Subject: [PATCH] correccion html entites en json --- index.php | 9 +++++++-- milfs/funciones/funciones.php | 6 ++++-- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/index.php b/index.php index 556fc0e..6a693cf 100755 --- a/index.php +++ b/index.php @@ -101,21 +101,26 @@ if ($variable !=''){ /// e = EMPRESA $id_empresa = $v[1]; $id =$id_empresa; - $logo = remplacetas('empresa','id',"$id_empresa",'imagen','') ; $titulo = remplacetas('empresa','id',"$id_empresa",'razon_social','') ; + if($titulo[0] !="") { + $logo = remplacetas('empresa','id',"$id_empresa",'imagen','') ; + $descripcion = remplacetas('empresa','id',"$id_empresa",'slogan','') ; //$background_imagen = buscar_imagen('',"","","$id_empresa"); $background_imagen = remplacetas('empresa','id',"$id_empresa",'imagen','') ; $background_imagen = $background_imagen[0]; $uri_set = ""; $acceso = 1; - $menu =" + $menu ="

Hola mundo( $titulo[0] $id_empresa )

"; $cols_interior ="10"; + }else { + $onload = " "; + } } elseif($v[0] =='b') { /// s= SET DE DATOS diff --git a/milfs/funciones/funciones.php b/milfs/funciones/funciones.php index 5df7288..f2343c1 100644 --- a/milfs/funciones/funciones.php +++ b/milfs/funciones/funciones.php @@ -5019,7 +5019,7 @@ while($row = mysqli_fetch_array( $sql )) $privado = @$privado[1]; /// PRIVACIDAD if($privado !='1') { - $array[$nombre_campo[0]] = "$contenido[0]"; + $array[$nombre_campo[0]] = html_entity_decode("$contenido[0]"); //$array['consulta'] = "$contenido[2]"; $array['timestamp'] = "$row[timestamp]"; $array['proceso'] = "$row[proceso]"; @@ -8742,10 +8742,11 @@ $mostrar = mostrar_areas($datos['id'],"","","api"); if($privado !='1') { if($datos['tipo']=="simple"){ $contenido = remplacetas('form_datos','id',$row["id_dato"],'contenido',"") ; + $contenido_limpio = html_entity_decode("$contenido[0]"); $id_campo = remplacetas('form_datos','id',$row["id_dato"],'id_campo',"") ; $nombre_campo =remplacetas('form_campos','id',$id_campo[0],'campo_nombre',"") ; - $features[] = "'$nombre_campo[0]' : '$contenido[0]'";//$row[id_campo]; + $features[] = "'$nombre_campo[0]' : '$contenido_limpio'";//$row[id_campo]; } else { if($campo_tipo[0] == '31') { @@ -8753,6 +8754,7 @@ $mostrar = mostrar_areas($datos['id'],"","","api"); $row['contenido']= $link_url; } + $row["contenido"] = html_entity_decode("$row[contenido]"); $features[] = $row; } }