Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.12.3

Request #2236 Error messages using gettext
Submitted: 2004-08-27 09:19 UTC
From: joho at webbplatsen dot se Assigned: danielc
Status: Wont fix Package: DB
PHP Version: 4.3.7 OS: Linux
Roadmaps: (Not assigned)    
Subscription  
Comments Add Comment Add patch


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 45 - 37 = ?

 
 [2004-08-27 09:19 UTC] joho at webbplatsen dot se
Description: ------------ I'm using DB(.php) 1.59 and was wondering if it wouldn't be a good idea to add gettext-wrappers around all error messages to prevent people from having to modify the actual class(es) to translate error messages. For example, the errorMessage() function maps error codes to error texts; in that mapping, would it not make sense to use _('already exists') instead of just 'already exists'. If no gettext is being used, it won't affect anything (or does PHP generate a RTE if the gettext extensions aren't compiled.. ?) Perhaps also, prefix the messages with _('PEARDB: already exists') so that you minimize the risk of running into conflicting translations.

Comments

 [2004-08-27 14:55 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2004-08-29 18:35 UTC] joho at webbplatsen dot se
I thought one of the many reasons for using PEAR-stuff was to maintain some level of transparency; this transparency surely isn't just meant to the interface to other component such as XML, HTTP, databases, etc. The less I have to fiddle with the module code as a developer, the more likely I am to stay up to date with new releases and incorporate them into my projects. Oh well, it was worth a try, and my two cents..