Found 2 elements with non-unique id

Please report bugs and any annoyances here. Kindly include all possible details: steps to reproduce, expected result, actual result, screenshots, ... etc.
Post Reply
Leving Tinoco
Posts: 12
Joined: 2018-01-04 18:39
Location: Canada

Found 2 elements with non-unique id

Post by Leving Tinoco » 2019-12-31 06:11

Hi,

I keep finding warning on my "developer tools" from google chrome every time on my table_view.php
"Found 2 elements with non-unique id ", look like is trying to add twice the button "Add new", "Print View", "Save CSV".

Is someone else having this problem?

Appgini version 5.81

Thanks.
Attachments
2019-Selection_019.png
2019-Selection_019.png (24.56 KiB) Viewed 4603 times

Alisson
Veteran Member
Posts: 81
Joined: 2017-02-25 20:32

Re: Found 2 elements with non-unique id

Post by Alisson » 2020-01-02 01:57

Since 5.81, I'm also having the same exact problem on all tables, and when I'm not inside a table this error also shows:
AppGini.currentTableName: Could not retrieve table name from page URL common.js.php:1428

User avatar
jsetzer
AppGini Super Hero
AppGini Super Hero
Posts: 1807
Joined: 2018-07-06 06:03
Location: Kiel, Germany
Contact:

Re: Found 2 elements with non-unique id

Post by jsetzer » 2020-01-02 04:06

Re: current table error message

Yes, there is that message on certain pages and we can ignore it. That error msg does not break the execution of the rest of our code.

I got the information that this debugging information will be removed in the future or at least will not have red error formatting in console tab, as this is irritating.
Kind regards,
<js />

My AppGini Blog:
https://appgini.bizzworxx.de/blog

You can help us helping you:
Please always put code fragments inside [code]...[/code] blocks for better readability

AppGini 24.10 Revision 1579 + all AppGini Helper tools

Leving Tinoco
Posts: 12
Joined: 2018-01-04 18:39
Location: Canada

Re: Found 2 elements with non-unique id

Post by Leving Tinoco » 2020-01-03 05:00

Well I think I found the problem, under the file datalist.php line 788
it is 4 line of code add twice the buttons line with differents class names

Code: Select all

$this->HTML .= '<div id="top_buttons" class="hidden-print">';
					/* .all_records: container for buttons that don't need a selection */
					/* .selected_records: container for buttons that need a selection */
					$this->HTML .= '<div class="btn-group btn-group-lg visible-md visible-lg all_records pull-left">' . $buttons_all . '</div>';
					$this->HTML .= '<div class="btn-group btn-group-lg visible-md visible-lg selected_records hidden pull-left hspacer-lg">' . ($actual_more_count ? $more_menu : '') . '</div>';
//					$this->HTML .= '<div class="btn-group-vertical btn-group-lg visible-xs visible-sm all_records">' . $buttons_all . '</div>';
//					$this->HTML .= '<div class="btn-group-vertical btn-group-lg visible-xs visible-sm selected_records hidden vspacer-lg">' . ($actual_more_count ? $more_menu : '') . '</div>';
					$this->HTML .= $this->tv_tools();
					$this->HTML .= '<p></p>';
				$this->HTML .= '</div>';
What I did was only is comment the last 2 lines .. class = "btn-group-vertical" and that fix my problem.

Post Reply