diff --git a/milfs/funciones/funciones.php b/milfs/funciones/funciones.php
index 95524b0..ef19342 100644
--- a/milfs/funciones/funciones.php
+++ b/milfs/funciones/funciones.php
@@ -120,6 +120,7 @@ if ( strlen($value)>3) {//no smaller than X and not in banned
$keywords="";
+ $cantidades="";
$count = 0;
foreach ($wordCounter as $key => $value){
@@ -127,6 +128,7 @@ foreach ($wordCounter as $key => $value){
if($count < $cantidad){
//$keywords[] =$key;
$keywords[] ="$key";
+ $cantidades[$key] ="$value";
}else{break;} $count++;
}
}
@@ -137,6 +139,9 @@ if($tags !=''){
$nube ="";
+$min = min($cantidades);
+$max = max($cantidades);
+ $diferencia = $max - $min;
foreach($tags as $c=>$valor){
//foreach($wordCounter as $c=>$valor){
//$valor = $tags[0];
@@ -160,11 +165,13 @@ foreach($tags as $c=>$valor){
$ht = str_replace(array(' '), '', $c);
$limpios[] = $c;
- $cant = $wordCounter[$c];
+ $cant = $cantidades[$c];
+ $valor_relativo = round((($cant - $min) / $diferencia) * 10);
+
$size = ($cant/4);
$tag_adicional .= "$c " ;
-
- $nube .= "$c " ;
+ $array_prueba = print_r($wordCounter,true);
+ $nube .= "$c " ;
}
}
}
@@ -176,7 +183,7 @@ foreach($tags as $c=>$valor){
return $array_nombres_compuestos[0];
}elseif($tipo=="nube") {
//return $compuestos;
- return $nube;
+ return "$nube";
}elseif($tipo=="limpio") {
//return $compuestos;
return $limpios;