tematres / TemaTres-Vocabulary-Server

Web application for management formal representations of knowledge, like controlled vocabularies, taxonomies, thesauri and glossaries
https://vocabularyserver.com
118 stars 52 forks source link

The installation content is not displayed after selecting the language #74

Closed chenkuncloud closed 11 months ago

chenkuncloud commented 2 years ago

Hi,

I'm installing TemaTres according to the tutorial, but when I start php:7.4-apache and run vocab/install.php, the installation content is not displayed, and this page is still displayed when I select the language:

95606dd1bc4b2067977f9974c1cb1be

Did I do something wrong?

Here's my environment:

TemaTres:latest from github
mysql:5.7.27 - InnoDB
php:7.4-apache

Here's my db.tematres.php:

<?php
/*
 *  db.tematres.php
 *
 *  Copyright 2011-2020 diego ferreyra <diego@r020.com.ar>
 *
 *  This program is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation; either version 2 of the License, or
 *  (at your option) any later version.
 *
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program; if not, write to the Free Software
 *  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
 *  MA 02110-1301, USA.
 */

/*
    Configuarcion de base de datos - Database Configuration
    Select driver to use
    Default: MySQLi , can be mysqli,postgres, oci8, mssql, and more: http://phplens.com/adodb/supported.databases.html
    To default value, leave empty eg: $DBCFG["DBdriver"] ="";
*/

$DBCFG["DBdriver"] ="";

/** Dirección IP o nombre del servidor - IP Address of the database server */
$DBCFG["Server"]      = "10.0.90.117";

/** Nombre de la base de datos Database name */
$DBCFG["DBName"]     = "tematres";

/** Nombre de usuario - login */
$DBCFG["DBLogin"]    = "root";

/** Passwords */
$DBCFG["DBPass"] = "mypass";

/** Prefijo para tablas # Prefix for tables */
$DBCFG["DBprefix"] = "lc_";

/**
 *  In almost cases, you don't need to touch nothing here!!
 */

 /** Default charset for the database */
$DBCFG["DBcharset"] ="utf8";

/** Modo debug = 1 // debug mode = 1 */
$DBCFG["debugMode"] = "0";

/** Persist connection to DB. TRUE = 1 // FALSE mode = 0. Default: TRUE */
$DBCFG["DBpersist"] = "1";

/** Use or not DSN. Default: DSN */
$DBCFG["DBmodeConnect"] = "DSN";

/** Config MySql engine type:  MyISAM / InnoDB  (default MyISAM to maintain back compatibility)*/
$DBCFG["DBengine"] = "InnoDB";

/** Define if storage hashed passwords or not  (1 = Yes, 0 = No: default: 0) */
define('CFG_HASH_PASS', '0');

/** Change to whatever timezone you want */
if (date_default_timezone_get()!=ini_get('date.timezone')) {
    date_default_timezone_set('Etc/UTC');
}

/**  Absolute path to the directory where are located /common/include. */

if (!defined('T3_ABSPATH')) {
/** Use this for version of PHP < 5.3 */
    //define('T3_ABSPATH', dirname(__FILE__) . '/../');

    /**
*
 * Use this for version of PHP >= 5.3
*/
    define('T3_ABSPATH', dirname(__DIR__) . '/');

    /**
*
 * Use to define specific local path for common/include directory
*/
    //define('T3_ABSPATH', '/var/www/html/');
};

Best Regards

tematres commented 2 years ago

Hi, your params looks OK. Can you enable the debug mode?

/* Modo debug = 1 // debug mode = 1 / $DBCFG["debugMode"] = "1";

ZookieSwag commented 1 year ago

Hello, I also have this problem. This is my db file:

<?php`
/*
 *  db.tematres.php
 *
 *  Copyright 2011-2020 diego ferreyra <diego@r020.com.ar>
 *
 *  This program is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation; either version 2 of the License, or
 *  (at your option) any later version.
 *
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program; if not, write to the Free Software
 *  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
 *  MA 02110-1301, USA.
 */

/*
    Configuarcion de base de datos - Database Configuration
    Select driver to use
    Default: MySQLi , can be mysqli,postgres, oci8, mssql, and more: http://phplens.com/adodb/supported.databases.html
    To default value, leave empty eg: $DBCFG["DBdriver"] ="";
*/

$DBCFG["DBdriver"] ="";

/** Dirección IP o nombre del servidor - IP Address of the database server */
$DBCFG["Server"]      = "localhost:";

/** Nombre de la base de datos Database name */
$DBCFG["DBName"]     = "tematres";

/** Nombre de usuario - login */
$DBCFG["DBLogin"]    = "root";

/** Passwords */
$DBCFG["DBPass"] = "pass";

/** Prefijo para tablas # Prefix for tables */
$DBCFG["DBprefix"] = "lc_";

/**
 *  In almost cases, you don't need to touch nothing here!!
 */

 /** Default charset for the database */
$DBCFG["DBcharset"] ="utf8";

/** Modo debug = 1 // debug mode = 1 */
$DBCFG["debugMode"] = "1";

/** Persist connection to DB. TRUE = 1 // FALSE mode = 0. Default: TRUE */
$DBCFG["DBpersist"] = "1";

/** Use or not DSN. Default: DSN */
$DBCFG["DBmodeConnect"] = "DSN";

/** Config MySql engine type:  MyISAM / InnoDB  (default MyISAM to maintain back compatibility)*/
$DBCFG["DBengine"] = "MyISAM";

/** Define if storage hashed passwords or not  (1 = Yes, 0 = No: default: 0) */
define('CFG_HASH_PASS', '1');

/** Change to whatever timezone you want */
if (date_default_timezone_get()!=ini_get('date.timezone')) {
    date_default_timezone_set('Etc/UTC');
}

/**  Absolute path to the directory where are located /common/include. */

if (!defined('T3_ABSPATH')) {
/** Use this for version of PHP < 5.3 */
    define('T3_ABSPATH', dirname(__FILE__) . '/../');

    /**
*
 * Use this for version of PHP >= 5.3
*/
    //~ define('T3_ABSPATH', dirname(__DIR__) . '/');

    /**
*
 * Use to define specific local path for common/include directory
*/
    //~ define('T3_ABSPATH', '/home/my_name/tematres/');
};

And this is the error gotten: Unable to connect to database server localhost: with the user root. Please check your file configuration for the database connection (http://localhost/vocab/db.tematres.php).

tematres commented 1 year ago

Hi @ZookieSwag I think there are a problem in the name of the database server, in you configuration are included a ":" in the end: $DBCFG["Server"] = "localhost:";

and must to be: $DBCFG["Server"] = "localhost";

(Sorry about my english). Please download the latest pre-release. The last code is 8.x compatible.

best regards

ZookieSwag commented 1 year ago

My bad on that, im still using an older version of tematres. I am also trying to run it in a container but I cant get them to connect. This is my docker compose file:

version: '3'

services:
  web:
    #image: "php:7.4-apache"
    build:
      #context: ./php-apache-7.4
      dockerfile: ./Dockerfile
    restart: 'always'
    depends_on:
      - mariadb
    restart: 'always'
    ports:
      - '8081:80'
    platform: linux/x86_64
    volumes:
     - "./app:/var/www/html"
    links:
      - mariadb
    networks:
      - rede

  mariadb:
      image: "mariadb:5"
      restart: 'unless-stopped'
      volumes:
       - "/var/lib/mysql"
       #- "/var/lib/mysql/logs:tematres"
       - /var/docker/mariadb/conf:/etc/mysql
      environment:
       MYSQL_ROOT_PASSWORD: pass
       MYSQL_DATABASE: tematres
       MYSQL_USER: tematres
       MYSQL_PASSWORD: pass
      expose:
       - 3306
      networks:
       - rede

  phpmyadmin:
    image: phpmyadmin/phpmyadmin
    environment:
      PMA_HOST: mariadb
      PMA_PASSWORD: pass
    volumes:
      - ./config:/usr/local/etc/php/conf.d/php-phpmyadmin.ini
    ports:
      - '8080:80'
    networks:
      - rede
    restart: unless-stopped

networks:
  rede:
    driver: bridge

  #tematres:
  #  build: .
  #  container_name: tematres
  #  ports:
  ##    - '8080:8080'
  #  depends_on:
  #    - web
  #    - mariadb

And this is my php build file:

FROM php:7.4-apache

RUN docker-php-ext-install mysqli

I changed it back to "localhost" and they still do not connect.

ZookieSwag commented 1 year ago

I actually ended up fixing my problem, thank you for your help!