Commit Graph

330 Commits

Author SHA1 Message Date
Ferywir 20804d9182 feat: IP ban support (#185) (#188) 2026-06-09 15:15:27 +03:00
Catalin Novgorodschi 0e425f512f Fix deletion user
Fix deletion user code backend
2026-06-09 08:04:17 +03:00
novgorodschi catalin 0d046e0333 fix admin colour
fix admin colour
2026-06-05 12:54:48 +03:00
novgorodschi catalin eeb1bea701 Fix admin panel colour log
Fix admin panel colour log
2026-06-05 12:51:34 +03:00
novgorodschi catalin e69d8457d8 Admin panel design changed
Admin panel design changed
2026-06-05 12:30:13 +03:00
novgorodschi catalin 6e1899a21e Fix alliance capacity
Fix alliance capacity
2026-06-04 15:14:35 +03:00
novgorodschi catalin e2dfefa0b7 Close tr
Close tr
2026-06-04 13:56:29 +03:00
novgorodschi catalin 4eecf575a1 Fix some lang problems
Fix some lang problems & added in admin panel
2026-06-04 13:54:15 +03:00
novgorodschi catalin 33b7261b4b Change some file
Change some file
2026-06-04 13:39:59 +03:00
Catalin Novgorodschi 28ddc72c01 Merge pull request #175 from Ferywir/feat/per-user-language
Add per-user language selection (closes #166)
2026-06-04 13:15:24 +03:00
novgorodschi catalin 1a4014218c Fix something broken
Fix something broken
2026-06-04 12:35:53 +03:00
TravianZ Patcher 421915f774 Add per-user language selection (issue #166)
The profile already had a language selector (Templates/Profile/preference.tpl)
that saved the choice into users.lang and $_SESSION['lang'], but the saved
preference was never used to actually load the language: every page loads
include("Lang/".LANG.".php") with the server-wide LANG constant, so changing
the language in the profile had no visible effect.

This wires it up:

- Introduce SERVER_LANG (the server default) and make LANG the EFFECTIVE
  display language, resolved from the player's saved preference
  ($_SESSION['lang']) with a fallback to SERVER_LANG
  (install/data/constant_format.tpl).
  SECURITY: the value is sanitized to [a-z_] and the target Lang/<x>.php
  file must exist, otherwise we fall back to the server default. This
  prevents Local File Inclusion via include("Lang/".LANG.".php").

- Seed $_SESSION['lang'] from users.lang on login (GameEngine/Session.php,
  PopulateVar), so the chosen language applies right after logging in.

- Keep the SERVER default intact when an admin saves settings: the admin
  config regenerators and the "Server Settings"/config displays now use
  SERVER_LANG (the server default) instead of the per-user LANG, so an
  admin browsing in their own language can't accidentally overwrite the
  server default (6 Admin/Mods/edit*.php + editServerSet.tpl + config.tpl).

Note: existing installs must also add SERVER_LANG + the LANG resolution to
their generated GameEngine/config.php (and the Admin/Mods/constant_format.tpl
copy) since config is generated at install time.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-04 09:07:57 +02:00
novgorodschi catalin 11ce6e6052 Added Romanian Language
Added Romanian Language
2026-06-04 09:39:44 +03:00
Catalin Novgorodschi 950902f8e1 Merge pull request #171 from Ferywir/l10n/french-and-swiss-timezone
L10n/french and swiss timezone
2026-06-04 07:37:14 +03:00
Catalin Novgorodschi 5e6bb4f1ed Merge pull request #170 from Ferywir/fix/issue-169-install-and-admin-bugs
Fix install + admin bugs reported in issue #169
2026-06-04 07:35:51 +03:00
TravianZ Patcher 2f2f0f5a47 Add Swiss timezone (Europe/Zurich) to timezone selectors
The timezone lists are hardcoded. Add "Europe (Switzerland)" =
Europe/Zurich to:
- Admin/Templates/editServerSet.tpl (admin: edit server settings)
- install/templates/config.tpl (install wizard, index 14)
- install/index.php (install wizard tz index->name mapping, case 14)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-03 11:28:09 +02:00
TravianZ Patcher 46d63e737c Add French (fr) to the language selectors
The language dropdowns are hardcoded (they don't scan GameEngine/Lang/),
so the existing fr.php never appeared. Add a French option to:
- install/templates/config.tpl (install wizard)
- Admin/Templates/editServerSet.tpl (admin: edit server settings)
- Admin/Templates/config.tpl (admin: server config display)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-03 11:28:09 +02:00
novgorodschi catalin 18233f7c1b Redesign login page & main page in Admin Panel
Redesign login page & main page in Admin Panel
2026-06-03 11:43:59 +03:00
TravianZ Patcher 7a013c38e3 Fix install + admin bugs reported in issue #169
Addresses the five bugs found on master (6e139a1b) during a fresh
Docker install and admin testing:

1. Missing `details` column in gold_fin_log (HTTP 500 on finishing
   construction with gold, buying Gold Club, admin giving gold):
   - Add `details varchar(255)` to the gold_fin_log schema, matching
     every INSERT and the a2b2.php reader that already use it.
   - Fix the broken positional INSERT in Logging::goldFinLog() (it sent
     3 values for a 7-column table) which 500'd on the same gold path.

2. Admin "View Player Info" fatal error: `<? php` -> `<?php` in
   Admin/Templates/playerinfo.tpl.

3. "Reset Server" leaving the DB corrupted (Duplicate key name
   'idx_ft_bonus_xy'): move the croppers indexes inline into the
   CREATE TABLE IF NOT EXISTS so structure recreation is idempotent,
   and add `croppers` to the reset truncate list.

4. Install wizard crash on failed DB connection (mysqli_error(false)):
   use mysqli_connect_error() and show a friendly, actionable message
   (incl. the Docker "db" hostname hint).

5. PHP exposing errors/stack traces to end users: ship a production
   php.ini baseline + docker/php/zz-travianz.ini that turns off
   display_errors and logs to stderr instead.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-03 08:32:00 +02:00
novgorodschi catalin 37397a63bc Fix msg in admin panel
Fix msg in admin panel
2026-06-02 13:16:44 +03:00
novgorodschi catalin 888b4848e4 Fix hero svg in admin panel
Fix hero svg in admin panel
2026-06-02 12:17:08 +03:00
novgorodschi catalin 66a3c5d34f Translate some code
Translate some code
2026-06-02 11:35:35 +03:00
novgorodschi catalin 53cef401bf fix popup
fix popup
2026-06-02 11:10:42 +03:00
novgorodschi catalin 547e164143 Edit some access for MH user and recreate mass messaage
Edit some access for MH user and recreate mass message and new maintenance system view for admins
2026-06-02 10:59:35 +03:00
novgorodschi catalin dbe20c49b5 Some last fix for logs! 2026-05-28 13:22:27 +03:00
novgorodschi catalin 1d1f1dc72a Fix + Redesign
Fix some error programing code and redesign special medals, tribe medals, mh medals, taskmaster medals, natars medals, nature medals, protection medals, etc. Add some language code in Profile.php and preference.tpl. Change some description in struct database for Nature and Taskmaster
2026-05-28 12:25:28 +03:00
novgorodschi catalin a9650e1624 Fix caps look del alli
Fix caps look del alli
2026-05-27 13:22:35 +03:00
novgorodschi catalin b31a0a3f92 Fix edit resources
Fix edit resources
2026-05-27 13:09:24 +03:00
novgorodschi catalin 31c475e644 Fix + Credits + Start Language Coding
Fix Artefacts + Credits + Start Language Coding
2026-05-27 12:26:24 +03:00
novgorodschi catalin 1b119d2a35 Fix special medals
Fix special medals
2026-05-26 14:42:19 +03:00
novgorodschi catalin 24fb80371d Fix special medal system
Fix special medal system
2026-05-26 12:34:50 +03:00
novgorodschi catalin fe19587c90 Redesign install system & New Medal System
Redesign install system & New Medal System

Artefact Holder			[#ARTEFACT]
WW Builder			[#WWBUILDER]
Great Store			[#GREATSTORE]
Wall Master			[#WALLMASTER]
Hero 99+			[#HERO100]
2026-05-26 10:42:28 +03:00
novgorodschi catalin 8c3ab3e5eb Fix some bugs + added (coded delAli)
Fix some bugs + added (coded delAli)
2026-05-25 12:37:33 +03:00
novgorodschi catalin a4e2c506a8 Redesign Admin Panel
Full frontend & backend redesign and refactor
2026-05-25 10:23:39 +03:00
novgorodschi catalin a3100fb691 Redesign Admin Panel Second Round
Redesign Admin Panel Second Round
2026-05-22 15:16:47 +03:00
novgorodschi catalin 62c86380a4 Redesign Admin Panel First Round
Redesign Admin Panel First Round
2026-05-22 15:12:37 +03:00
novgorodschi catalin 3fa16f13b2 Full Refactor Admin Panel & Logs
Full Refactor Admin Panel & Logs (now you can see detailed logs in admin panel) - ONLY BACKED
2026-05-22 11:29:37 +03:00
novgorodschi catalin 1192e53b04 Fix admin error line 600
Fix admin error line 600
2026-05-21 13:18:12 +03:00
novgorodschi catalin 05bfde9063 Remove some unused code and some fix
Remove some unused code and some fix
2026-05-21 13:12:21 +03:00
novgorodschi catalin 878ecec687 Added Account transactions with History
Added Account transactions with History
2026-05-21 11:23:45 +03:00
novgorodschi catalin 4a2108e88e Change to english Admin - Change
Change to english Admin - Change
2026-05-18 09:21:01 +03:00
novgorodschi catalin 55e6dd60b5 Refactor + BugFix
1. Fix a bug in Admin Panel that you can edit by yourself your rank, now you cannot edit your rank anymore.

2. Now Alliance Leader can edit his own Position

3. Fix negative value on Demolition Building, now in database at lvl is appear new level not -1

4. Refactor Ajax map, now all is alligned (Ajax folder and Map folder)

5. Fix bug from Palace (when change capital now Automation recount population automaticaly on old capital and new capital)
2026-05-18 09:18:35 +03:00
Catalin Novgorodschi 850a46ae2d Some fixes & improovements
1. Fix ban access, 2. Fix profile ('"") , 3. Add on vacation Admin/MH and exclude rat from reinforcement.
2026-05-15 12:13:01 +03:00
Catalin Novgorodschi cd4a5cd957 Fix ban, forgot to change access
Fix ban, forgot to change access
2026-05-15 09:05:02 +03:00
Catalin Novgorodschi 60c2ed2f60 Incremental Refactor Templates 3
Incremental Refactor Templates 2
2026-05-07 11:20:05 +03:00
Catalin Novgorodschi a02be51969 Incremental Refactor Templates
Incremental Refactor Templates
2026-05-06 13:16:54 +03:00
Catalin Novgorodschi bff79d3006 Update version number in ver.tpl 2026-04-29 14:01:24 +03:00
Catalin Novgorodschi 0e21d17969 Update latest version in update_latest.tpl 2026-04-29 13:59:39 +03:00
Catalin Novgorodschi 624424dde9 Admin Natars/WW management
Admin Natars/WW management
2026-04-29 12:53:49 +03:00
Catalin Novgorodschi a7cedf06bd Added ban history
Added ban history
2026-04-29 08:46:25 +03:00