Git Product home page Git Product logo

adminerevo's Introduction

AdminerEvo

Adminer - Database management in a single PHP file
Adminer Editor - Data manipulation for end-users

A bit of history

The original Adminer was created and maintained by Jakub Vrána in the vrana/adminer repository. Not being maintained for more than two years and being a daily user of Adminer, I've tried to get in touch with the original developer to propose my help to continue the project, but without success, I got no answer. I have then started to search if someone would be interested in continuing the project with me and found someone who seemed to have the same interest and view on the future of this project. I am now starting to take over the project under a slightly different name and will try to keep compatibility with all current database engines but also to give Adminer a new features, layout, etc.

Before participating

Before you start developing around AdminerEvo, please carefully read the roadmap, the status of open issues, and even get in touch with us. It would be sad spending time/energy on development of a feature which would not be accepted into the main project.

License

This work is dual-licensed under Apache 2.0 and GPL 2.0. You can choose between either one of them if you use this work.

SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-only

Information from the original developer

Supports MySQL, MariaDB, PostgreSQL, SQLite, MS SQL, Oracle, Elasticsearch, MongoDB, SimpleDB (plugin), Firebird (plugin), ClickHouse (plugin)
Requirements PHP 5+
Licence Apache License 2.0 or GPL 2

 

File Purpose
adminer/index.php Run development version of Adminer
editor/index.php Run development version of Adminer Editor
editor/example.php Example customization
plugins/readme.txt Plugins for Adminer and Adminer Editor
adminer/plugin.php Plugin demo
adminer/sqlite.php Development version of Adminer with SQLite allowed
editor/sqlite.php Development version of Editor with SQLite allowed
adminer/designs.php Development version of Adminer with adminer.css switcher
compile.php Create a single file version
lang.php Update translations
tests/katalon.html Katalon Automation Recorder test suite

If downloaded from Git then run: git submodule update --init

adminerevo's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

adminerevo's Issues

Timeout error: git submodule update --init

When you run this command git submodule update --init you will get timeouts for:

github.com/vrana/JsShrink
github.com/vrana/jush

Problem is a wrong url in .gitmodules file. Just replace "git:" with "https:" and everything is fine again and you can use compile.php without errors.

Undefined array key when editing

Environment:
Debian 11.8 Local
Apache 2.4.56 FPM/FastCGI Local
mariadb-10.5.21/MySQLi
PHP 8.3.0 error_reporting E_ALL
AdminerEvo 4.8.4-dev (code_no_warnings Commits on Dec 11)

http://xxxx/adminer/?server=&username=UseR&db=MyBd&select=gs_preference_asso&modify=1
table with: id_pref design_pref val_pref ↓
message val_pref =
2 - Undefined array key "id_pref" - .../adminer/select.inc.php:361
2 - Undefined array key "design_pref" - .../adminer/select.inc.php:361
2 - Undefined array key "val_pref" - .../adminer/select.inc.php:361

http://xxxx/adminer/?server=&username=UseR&db=MyBd&edit=gs_preference_asso&where%5Bid_pref%5D=1
2 - Undefined array key "id_pref" - .../adminer/include/functions.inc.php:500

mysql8 int type length deprecated

Integer display width is deprecated and will be removed in a future release.

demo sql:
CREATE TABLE t1 (
id int(11) NOT NULL auto_increment,
PRIMARY KEY (id)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

id int(11) is error.

Question marks instead of number in Tables and Size columns of Select Database view

Hello @admin

First, thank you so much for releasing AdminerEvo v4.8.2. This fixed an issue with Adminer v4.8.0 and v4.8.1 where text was blank and numbers were just question marks. The issue appears to be resolved for the most part.

However, the issue seems to persist when viewing the Select Database view:
image

As you can see, the numbers for the Tables and Size are still just appearing as question marks.

FYI: I am using MariaDB 10.4.28 with PHP 8.2 and Apache on Windows.

Anything you can do to fix this issue would be most appreciated.

Best regards,

Michael Milette

Search 'regular expression' and 'LIKE%%' results reversed

To reproduce:

Database: wordpress

Tables and views/Search data in tables

Search for 'db_'

'as regular expression' - not ticked
returns results as 'regular expression' with the underscore matching any single character

'as regular expression' - ticked
returns results as 'like%%'

Use adminer for automated backup of database

I want to use Adminer's export functionality to perform regular database backups of my database. I think the Export functionality is a decent candidate, but looking at the form it sends POST request, so I was wondering if there is a way to perform an Export through command line (or for example using curl to download it from something like /?server=database&username=blah&db=exampledb&dump=gzip ...).

I also assumed I could restore the database via Adminer Import command (I can download backup file and place it as adminer.sql.gz next to the adminer.php file and then execute something like: /?server=database&username=blah&db=exampledb&import=adminer.sql.gz to restore?

Any ideas would be welcome, as I rather utilize Adminer than to install a new tool

Use select instead of radio for enum columns

Enum columns should use a select > option input tag instead of a bunch of input radio labels, specially if you are using an enum columns with a bunch of options... also they are more readable IMO

Example:
image

Release 4.8.2

As the master branch of adminerevo is currently 21 commits ahead of vrana:master, could we maybe release 4.8.2?
Even if the commits are minor updates, it would be quite symbolic to submit a new release after two years without releases.

PostgreSQL invalid search for ip address type data

To repeat the error:

  1. create a table:
CREATE TABLE user_ip (  
 id   SERIAL PRIMARY KEY, 
 name varchar(64) DEFAULT '', 
 ip inet
);
  1. adding data:
INSERT INTO user_ip (name, ip) VALUES ('demo', '192.168.1.1');
  1. we are trying to find data using the built-in tools in the adminerevo
    select

the problem is how the search works, look at the search bar:
SELECT * FROM "user_ip" WHERE CAST("ip" AS text) = '192.168.1.1' LIMIT 50
nonefind

if you specify the address directly then everything is fine, The entry in the table can be found:

SELECT *
FROM user_ip
WHERE ip = '192.168.1.1';

find_ok

additionally, an error appeared during the search:
Warning: Undefined property: stdClass::$table in /home/user/www/adminer.php on line 1523

Bugs - session_start() and undefined $dg variable in server error.log

Hello,

First of all, thank you for your work on this fork. I've been using Adminer for many years and it's really sad that the original version is no longer supported. Is there any way to support your work?

With the current original version of adminer, I get hundreds of log lines in server error.log. I checked your commits and didn't see anything about this. So maybe you can fix these problems in the next releases of your version?

2023/07/07 00:55:08 [error] 1569199#1569199: *2613661 FastCGI sent in stderr: "PHP message: PHP Warning: session_start(): Session cache limiter cannot be sent after headers have already been sent (output started at /home/mysite/html/docs/wms-adminer-6450fd65cc2742f7.php:683) in /home/mysite/html/docs/wms-adminer-6450fd65cc2742f7.php on line 72" while reading upstream, client: 185.209.196.145, server: mysite.com, request: "GET /wms-adminer-6450fd65cc2742f7.php?username=dbuser123&db=dbname123&dump= HTTP/2.0", upstream: "fastcgi://unix:/run/php/php-mysite-81.sock:", host: "mysite.com", referrer: "https://mysite.com/wms-adminer-6450fd65cc2742f7.php?username=dbuser123&db=dbname123&edit=xxxxx"

2023/07/07 00:55:08 [error] 1569199#1569199: *2613661 FastCGI sent in stderr: "PHP message: PHP Warning: Undefined variable $dg in /home/mysite/html/docs/wms-adminer-6450fd65cc2742f7.php on line 868PHP message: PHP Warning: Undefined variable $dg in /home/mysite/html/docs/wms-adminer-6450fd65cc2742f7.php on line 868PHP message: PHP Warning: Undefined variable $dg in /home/mysite/html/docs/wms-adminer-6450fd65cc2742f7.php on line 868PHP message: PHP Warning: Undefined variable $dg in /home/mysite/html/docs/wms-adminer-6450fd65cc2742f7.php on line 868PHP message: PHP Warning: Undefined variable $dg in /home/mysite/html/docs/wms-adminer-6450fd65cc2742f7.php on line 868PHP message: PHP Warning: Undefined variable $dg in /home/mysite/html/docs/wms-adminer-6450fd65cc2742f7.php on line 868PHP message: PHP Warning: Undefined variable $dg in /home/mysite/html/docs/wms-adminer-6450fd65cc2742f7.php on line 868" while reading response header from upstream, client: 185.209.196.145, server: mysite.com, request: "GET /wms-adminer-6450fd65cc2742f7.php?username=dbuser123&db=dbname123&script=db HTTP/2.0", upstream: "fastcgi://unix:/run/php/php-mysite-81.sock:", host: "mysite.com", referrer: "https://mysite.com/wms-adminer-6450fd65cc2742f7.php?username=dbuser123&db=dbname123&dump="

Editor: foreign key column questions

How does AdminerEvo Editor determine the column to show for the drop-down list on the edit page?

I was curious if it is possible to override the function and select a specific column by name. Or to otherwise customize the drop-down to show more information.

For example, in my current db all the lookup tables have the format: id, code, name, description. It would be nice to be able to choose either code or name as an option. Alternatively, to have the name or description show up as a tooltip when hovering over the selected value.

For some lookups the option of displaying an image from a hyperlink field or blob field along with the description would be ideal.

I am hoping the above is possible with a plugin or function override.

source tarball missing externals

I'm looking to include adminerevo in Debian instead of adminer.

Provided source packages lack externals (JsShrink and jush) and thus adminer.php cannot be build without using git and pull submodules. Would it be possible to provide a full source tarball? The alternative for me is to package those files as external dependencies.

Please advise what works for everybody.

Project direction and nature, just a fork for stability and update or new one?

Hi @LionelLaffineur seem you manages this, as the author seems do no post a conclusive response and people suggest to continue.. there are several reason that point this project as new one event just a fork:

  1. Author is not active over the development and do not have a team managing the repository, you should not repeat same error, you must promoted a person to sencod you and/or build a team for: #3 (comment)
  2. This repo/project comment suggest to continue without him but, would mean that it would branch out so much that it would differentiate significativelly from original, and it would no longer be the same.
  3. The ideas for changes began to rain when we have not yet resolved all the Merge REquests that are pending, that is, we have not stabilized what is important (those MRs) and there are already strong changes proposed like the moving to bootstrap: #5

So then this looks more than a complete new directio more thant just a fork to mantain the project security and updates

Use of tags as branch names

Could you possibly use something like releases or stable as the branch name for the latest tag release? Otherwise the list of branches gets polluted with duplicates of tag names, and can cause confusion.

change requests from GET to POST

is it possible to replace the queries that are given for the SQL command from GET to POST? I have strong restrictions on the length of the string for the GET query, I cannot betray long and complex queries for SQL. Is it possible to solve this problem if you send commands for SQL via POST?

hide private data from the URL address

I ask you to change the logic of the script and not to transmit the most important data in the address line.
I ask you to remove from them the address of the SQL server, the name of the database, the user name.

When you open the program, all the data is in the address bar and can be intercepted, I ask you to store it in the PHP session and transmit it only through a POST request, not through a GET request.

This will increase the security and user confidence in the new version

docker images

will you be releasing docker images for you forked repo?

Fatal error when I click 2nd or 3rd or 4th page(pagination)

DB is SQL server. PHP 8.1
I found it's a bug of adminer, too.

Fatal error: Uncaught Error: Call to undefined method Min_PDOStatement::seek() in /home/vagrant/adminer/index.php:1777 Stack trace: #0 {main} thrown in /home/vagrant/adminer/index.php on line 1777

image

Warning: Undefined property: stdClass::$flags in index.php on line 237, php:8.2-fpm, PostgreSQL 16.0

version: Adminer 4.8.3 (https://download.adminerevo.org/4.8.3/adminer/adminer.zip)
env: docker php:8.2-fpm
db: PostgreSQL 16.0 (Debian 16.0-1.pgdg120+1)

When I export a table, it shows 7 of the errors I mentioned in the title just below the table structure, then it continues with the INSERT INTO section.

errors as codes:

<br />
<b>Warning</b>:  Undefined property: stdClass::$flags in <b>/code/index.php</b> on line <b>237</b><br />
<br />
<b>Warning</b>:  Undefined property: stdClass::$flags in <b>/code/index.php</b> on line <b>237</b><br />
<br />
<b>Warning</b>:  Undefined property: stdClass::$flags in <b>/code/index.php</b> on line <b>237</b><br />
<br />
<b>Warning</b>:  Undefined property: stdClass::$flags in <b>/code/index.php</b> on line <b>237</b><br />
<br />
<b>Warning</b>:  Undefined property: stdClass::$flags in <b>/code/index.php</b> on line <b>237</b><br />
<br />
<b>Warning</b>:  Undefined property: stdClass::$flags in <b>/code/index.php</b> on line <b>237</b><br />
<br />
<b>Warning</b>:  Undefined property: stdClass::$flags in <b>/code/index.php</b> on line <b>237</b><br />

PHP 8.3

Nice to see an update for Adminer.

There are a lot of Warning: Trying to access array offset on null in ... with PHP 8.3.
Can you... check them?

Improve favicon in dark mode

Hello,

Thanks for this fork :)
The favicon has changed compared to adminer, and in the browser's dark mode, the icon is not visible.
Would it be possible to use the old icon or to put this icon on a white background?

Copy to clipboard vs truncated queries

In case of truncated queries (...), the truncated query is copied to the clipboard. It should, of course, be the complete query that should be copied to the clipboard.

PHP 8.3 Undefined property warning

Undefined property: stdClass::$table in adminer-4.8.3.php on line 1525

I made a temporary fix to silence the warning, on line 1525, Col37, after the opening parenthesis, insert this
error_reporting(E_ERROR | E_PARSE);
to prevent the table being malformed by the error.

However, I wish we can port this to PHP8.3 and properly fix the issue.

PHP 8.3: Trying to access array offset on null in compile.php on line 254

Environment:
macOS 13.6.2
Apache 2.4.58
MySQL 8.2.0
PHP 8.3.0

When running php compile.php mysql en I get the following error:
Trying to access array offset on null in /adminerevo/compile.php on line 254

compile.php line 254:
if ($tokens[$i+2][0] === T_CLOSE_TAG && $tokens[$i+3][0] === T_INLINE_HTML && $tokens[$i+4][0] === T_OPEN_TAG

Might this be related to how PHP 8.3 now handles Increment/Decrement operators as described here ?:

Using the increment operator (++) on empty, non-numeric, or non-alphanumeric strings is now deprecated. Moreover, incrementing non-numeric strings is soft deprecated. That means no E_DEPRECATED diagnostic is emitted, but this feature should not be used when producing new code. The new str_increment() function should be used instead.

Make border softer and more beautiful for buttons and input fields

you have made the border for elements that can be clicked and edited very large and dark. It is very unusual to look at these elements, they look very rough. you can remove such a thick and large frame and return it as it was in the old version from: vrana/adminer

compare the two versions:

Old version vrana/adminer 4.8.1 ↓
1old

New version 4.8.3 ↓
2new

Warning

php8.3,mysql5.7,mysqli,adminerevo 4.8.3
Warning: Trying to access array offset on null in adminerevo.php on line 1491
Warning: Trying to access array offset on null in adminerevo.php on line 1517
1818

PostgreSQL exports data incorrectly

To repeat the error:

  1. I create a table (please note that the id field has an auto-increment)
CREATE TABLE client (  
 id   SERIAL PRIMARY KEY, 
 name varchar(64) DEFAULT '', 
 email varchar(128) UNIQUE NOT NULL
);
  1. adding data (please note that we are adding 3 entries):
INSERT INTO client (name, email) VALUES ('demo', '[email protected]');
INSERT INTO client (name, email) VALUES ('demo2', '[email protected]');
INSERT INTO client (name, email) VALUES ('demo3', '[email protected]');
  1. we are exporting data
    export

  2. we delete the table in order to import it later:

DROP TABLE IF EXISTS client;
  1. we do the import and see that everything is well and correctly exported: executed OK

  2. we are trying to continue adding data to the table:

INSERT INTO client (name, email) VALUES ('demo4', '[email protected]');

we see an error when adding an entry:

Error in query: ERROR: duplicate key value violates unique constraint "client_pkey"
DETAIL: Key (id)=(3) already exists.

the problem arose due to the fact that when exporting, the value of where to start auto-magnification seemed incorrect. the file specifies the value of the last added id, but you need the value of the next one from where the addition will be (need START 4).

...
CREATE SEQUENCE client_id_seq INCREMENT 1 MINVALUE 1 MAXVALUE 2147483647 START 3 CACHE 1;
...

client_bug_export.zip

uca1400_* collations

alter database, table do not show uca1400_* collations

version Adminer 4.8.2 MySQL 11.0.3-MariaDB-1:11.0.3+maria~ubu2204

Different colors for true and false

I often work with data that is of type true-false. for a better perception and understanding of the table, I ask you to make the display of these variables colored

color

provide newbie documentation for usage

the releases provide adminer.php and editor.php but the most newbie dont know how to setup.. cos dont know nothing about this is a fork.. as i suggested dont fork and made as new project

please provide directions and usage for newbies in https://docs.adminerevo.org/

thanks in advance.. and if you give me corrections i can write it for

SELECT DISTINCT vs extra column id

When the function DISTINCT is used in the SELECT page, whatever to which field the distinct should apply, the field id (table PK) is added making the result incorrect.
Why ? How to fix ?

image

Firefox "The byte stream was erroneous according to the character encoding that was declared. The character encoding declaration may be incorrect."

Hello,

I would like to report this error in the Firefox console:

image

The error happens on Firefox, not Chrome.

It also happens on a domain, no issue on localhost...

Here are some headers of the response for GET adminer.php
image

I have tried to encode the file to UTF-8, but this leads to other errors...

Please also note, I did not have this issue with adminer 4.8.1.

--Edit--
I do not have the issue with adminer 4.8.1 "English only"

SQL requests history

Hi,

It would be great to get the history of SQL requests done using adminerevo.
Or there is one probably but is it really complete?

Editor: left column missing descriptive table names

image

Compared to regular adminer the editor is missing descriptive table names in the left column.
This is caused by omitting the Show structure anchors, that show that table name. Which is completely fine and works as intended, as they are not relevant in editor.
But a visible table name would be helpful.

Relevant code:
Adminer:

echo '<li><a href="' . h(ME) . 'select=' . urlencode($table) . '"'
. bold($_GET["select"] == $table || $_GET["edit"] == $table, "select")
. " title='" . lang('Select data') . "'>" . lang('select') . "</a> "
;
echo (support("table") || support("indexes")
? '<a href="' . h(ME) . 'table=' . urlencode($table) . '"'
. bold(in_array($table, array($_GET["table"], $_GET["create"], $_GET["indexes"], $_GET["foreign"], $_GET["trigger"], $_GET["select"])), (is_view($status) ? "view" : "structure"))
. " title='" . lang('Show structure') . "'>$name</a>"
: "<span>$name</span>"
) . "\n";

Editor:

echo "<a href='" . h(ME) . 'select=' . urlencode($row["Name"]) . "'"
. bold($_GET["select"] == $row["Name"] || $_GET["edit"] == $row["Name"], "select")
. " title='" . lang('Select data') . "'>$name</a>\n"
;

Add adminer.js detection

The same as does with adminer.css file detection, an adminer.js detection could open a new spectrum of possibilities that could run from the client side without the classic Adminer plugins

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.