Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Q
question2answer
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
outils
question2answer
Commits
fc1014f2
Commit
fc1014f2
authored
Nov 29, 2014
by
pupi1985
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Removed support for metadata.php files in favor of metadata.json files
parent
b5aca36a
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
30 deletions
+6
-30
admin.php
qa-include/app/admin.php
+3
-5
metadata.json
qa-lang/en-GB/metadata.json
+3
-0
metadata.php
qa-lang/en-GB/metadata.php
+0
-25
No files found.
qa-include/app/admin.php
View file @
fc1014f2
...
...
@@ -120,14 +120,12 @@
$options
=
array
(
''
=>
'English (US)'
);
// find all language folders
foreach
(
glob
(
QA_LANG_DIR
.
'*'
,
GLOB_NOSORT
)
as
$directory
)
{
$metadataUtil
=
new
Q2A_Util_Metadata
();
foreach
(
glob
(
QA_LANG_DIR
.
'*'
,
GLOB_NOSORT
|
GLOB_MARK
)
as
$directory
)
{
$code
=
basename
(
$directory
);
$metadatafile
=
QA_LANG_DIR
.
$code
.
'/metadata.php'
;
if
(
is_file
(
$metadatafile
))
{
$metadata
=
include
$metadatafile
;
$metadata
=
$metadataUtil
->
fetchFromAddonPath
(
$directory
);
if
(
isset
(
$metadata
[
'display_name'
]))
$options
[
$code
]
=
$metadata
[
'display_name'
];
}
// otherwise use an entry from above
else
if
(
isset
(
$codetolanguage
[
$code
]))
$options
[
$code
]
=
$codetolanguage
[
$code
];
...
...
qa-lang/en-GB/metadata.json
0 → 100644
View file @
fc1014f2
{
"display_name"
:
"English (UK)"
}
qa-lang/en-GB/metadata.php
deleted
100644 → 0
View file @
b5aca36a
<?php
/*
Question2Answer by Gideon Greenspan and contributors
http://www.question2answer.org/
File: qa-lang/en-GB/qa-lang-metadata.php
Description: Contains metadata about the translations
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
More about this license: http://www.question2answer.org/license.php
*/
return
array
(
'display_name'
=>
'English (UK)'
,
);
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment