Closed Bug 325300 Opened 20 years ago Closed 20 years ago

incorrect capitalization of SeaMonkey?

Categories

(addons.mozilla.org Graveyard :: Public Pages, defect)

defect
Not set
minor

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: csthomas, Assigned: morgamic)

References

()

Details

We need to find a better solution than ucwords for http://lxr.mozilla.org/update1.0/source/extensions/index.php#45 (and probably lots of other places). It results in incorrect capitalization of SeaMonkey.
ucwords() doesn't remove caps. strtolower() does. (which is probably used in app manager so the app is stored in all lower case.) AFAIK, a proper display formatted field for the applications doesn't exist, does it.? Example From http://www.php.net/manual/en/function.ucwords.php: <?php $foo = 'hello world!'; $foo = ucwords($foo); // Hello World! $bar = 'HELLO WORLD!'; $bar = ucwords($bar); // HELLO WORLD! $bar = ucwords(strtolower($bar)); // Hello World! ?>
(In reply to comment #1) > ucwords() doesn't remove caps. strtolower() does. (which is probably used in > app manager so the app is stored in all lower case.) The admin panel does show SeaMonkey correctly, so it's not being strolower()ed there, I guess.
http://lxr.mozilla.org/update1.0/source/core/inc_global.php#83 83 $_GET["application"] = escape_string(strtolower($_GET["application"])); http://lxr.mozilla.org/update1.0/source/core/inc_browserdetection.php#78 78 $application = escape_string($_GET["application"]); Looks like it gets 'broken' in inc_global, though honestly, I don't see anywhere in that file that even uses the DB value for the application name (though the comparision used in the query on Line 84 of inc_global.php suggests that it'd be stored in the database as "Seamonkey".) So $application is really the $_GET["application"] all lower-case variable, passed through ucwords(). So its never really "correct" at all. If the DB has it right, then it just needs to get that. (if that'd break some part of inc_browserdetection, I don't recall though.)
The summary was clearly wrong, but we don't yet know what the problem is, or if it even still exists. The URL in the bug summary says "Mozilla Suite" now, so I think this is WORKSFORME, REOPEN with specific URLs to cases that have the wrong case.
Severity: normal → minor
Status: NEW → RESOLVED
Closed: 20 years ago
OS: Windows XP → All
Hardware: PC → All
Resolution: --- → WORKSFORME
Summary: ucwords() breaks capitalization of SeaMonkey → incorrect capitalization of SeaMonkey?
Target Milestone: 1.0 → ---
Version: 1.0 → 2.0
Product: addons.mozilla.org → addons.mozilla.org Graveyard
You need to log in before you can comment on or make changes to this bug.