Is there a table in the database that holes the URL (dolibarr_main_url_root)

Hi

Is there a table in the database that holds the URL and the Dolibarr version? The URL is in the CONF file called dolibarr_main_url_root, cant seem to find it, same question for the current Dolibarr version…

We want to access the URL base location from a module we are writting.

Many Thanks

The URL is accessible via the $conf object, have a look here.
I have no idea where to find the version number, try maybe in the same object

Hi,

For versions you have two things :
The program version that is written in the php file filefunc.inc.php https://github.com/Dolibarr/dolibarr/blob/develop/htdocs/filefunc.inc.php#L34
The database version, that is stored on the const table :

  • MAIN_VERSION_LAST_INSTALL
  • MAIN_VERSION_LAST_UPGRADE