Welcome Guest, Not a member yet? Register   Sign In
Shield auth messages - I would like to use mine
#1

(This post was last modified: 01-01-2025, 09:13 AM by TipoIT.)

Hello!

I have a simple practical question about CodeIgniter 4 shield, which I'm using in one of my new web applications. However, I would like to use my language for some of the Shield auth messages (not validation messages, I know how to overwrite these). I'm talking about the messages which are located at \vendor\codeigniter4\shield\src\Language\en folder and in the Auth.php file inside this folder. I will give you an example, there is a message in this file that goes like this: "Passwords cannot contain re-hashed personal information.". I would like to overwrite these messages with my own. I cannot use other language folders since the language that I would like to use is not offered (croatian) yet in the CodeIgniter installation. Any ideas?
-- AI can't have sex with your wife --
Reply
#2

Bump.
-- AI can't have sex with your wife --
Reply
#3

(This post was last modified: 01-05-2025, 03:56 AM by InsiteFX.)

You should not over write the Shield Auth Language files!

You Create a new language file that has your two character language name like en for English
Language
-- en
-- fr
-- ja
-- your language name


CodeIgniter 4 User Guide - Building Responses - Localization
What did you Try? What did you Get? What did you Expect?

Joined CodeIgniter Community 2009.  ( Skype: insitfx )
Reply
#4

Yes, but where do i put them / it? I guess it would go into app/Config and then something? Thanks.
-- AI can't have sex with your wife --
Reply
#5

If it's Italian then it should go under Language/it

You can download all the CodeIgniter translations from here:

CodeIgniter 4 Translations
What did you Try? What did you Get? What did you Expect?

Joined CodeIgniter Community 2009.  ( Skype: insitfx )
Reply




Theme © iAndrew 2016 - Forum software by © MyBB