Hello
I’m trying to manage Handsontable to import easy “only for the user” some data from excel. Already manage to visualize some data from a table, but I no find any solution to retrieve the JavaScript variable (only one array) to make SC manipulating the array and insert the data in the table, I know its more simple other options but I don’t what manage the security of the insert. I want put a button to export the array to SC and return to the previews page
This is the code of the Blank application
$prueba_sql = "SELECT *
FROM sec_groups_apps
LIMIT 10";
sc_lookup(prueba, $prueba_sql);
$contador = count({prueba});
$test = 0;
while($test < $contador){
$uno = {prueba[$test][0]};
$dos = {prueba[$test][1]};
$tre = {prueba[$test][2]};
$for = {prueba[$test][3]};
$five = {prueba[$test][4]};
$six = {prueba[$test][5]};
$seven = {prueba[$test][6]};
$cadena_array[] = "['$uno', '$dos', '$tre', '$for', '$five', '$six', '$seven']";
$test++;
}
$cadena = "[".implode(', ', $cadena_array)."]";
$jquerry_path = $this->Ini->path_prod;
//echo "esta es la cadena <br> $cadena";
$direccion_pagina = $_SERVER['HTTP_HOST'].$_SERVER['SCRIPT_NAME'];
//aqui se coloca todo lo que se quiere para que muestre la pagina
[COLOR="#3333FF"]echo "<html xmlns=\"http://www.w3.org/1999/xhtml\" xml:lang=\"en\" lang=\"en\">
<head>
<title>sin t?tulo</title>
<meta http-equiv=\"content-type\" content=\"text/html;charset=utf-8\" />
<meta name=\"generator\" content=\"Geany 1.24\" />
<!--
Loading Handsontable (full distribution that includes all dependencies apart from jQuery)
-->
<script data-jsfiddle=\"common\" src=\"$jquerry_path/dist/handsontable.full.js\"></script>
<link data-jsfiddle=\"common\" rel=\"stylesheet\" media=\"screen\" href=\"$jquerry_path/dist/handsontable.full.css\">
<script type=\"text/javascript\" src=\"$jquerry_path/third/jquery/js/jquery.js\"></script>
<script type=\"text/javascript\">
$(document).ready(function(){
$(\".accordion h3:first\").addClass(\"active\");
$(\".accordion p:not(:first)\").hide();
$(\".accordion h3\").click(function(){
$(this).next(\"p\").slideToggle(\"slow\")
.siblings(\"p:visible\").slideUp(\"slow\");
$(this).toggleClass(\"active\");
$(this).siblings(\"h3\").removeClass(\"active\");
});
});
</script>
<script>
$(document).ready(function(){
$(\"button\").click(function(){
$.ajax(
{
url: \"$direccion_pagina\",
dataType: 'json',
type: 'POST',
data: {matriz: miContenedor.misDatos},
success: function ()
{}
});
});
</script>
</head>
<body>%3