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
dd800b30
Commit
dd800b30
authored
Oct 20, 2016
by
pupi1985
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Minor refactoring of the lang check file
parent
3a5e3401
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
11 deletions
+18
-11
qa-check-lang.php
qa-include/qa-check-lang.php
+18
-11
No files found.
qa-include/qa-check-lang.php
View file @
dd800b30
...
...
@@ -35,10 +35,17 @@
<meta
http-equiv=
"content-type"
content=
"text/html; charset=utf-8"
/>
<title>
Question2Answer Language Check
</title>
<style>
code
{
font-size
:
125%
;}
body
{
font-family
:
arial
;
font-size
:
12px
;
}
code
{
font-size
:
125%
;}
.severe
{
color
:
#b83939
;}
.warning
{
color
:
#d2930d
;}
.includes
{
color
:
#999
;}
</style>
</head>
<body
style=
"font-family:arial; font-size:12px;"
>
<body>
<?php
function
get_phrase_substitutions
(
$phrase
)
...
...
@@ -52,8 +59,8 @@
return
$substitutions
;
}
echo
'<
font color="#cc0000"><code>Dark red = important to review.</code></font
><br>'
;
echo
'<
font color="#cc9999"><code>Light red = probably safe to ignore.</code></font
>'
;
echo
'<
code class="severe">Red = important to review.</code
><br>'
;
echo
'<
code class="warning">Orange = probably safe to ignore.</code
>'
;
echo
'<h1>Checking US English files in <code>qa-include</code>...</h1>'
;
...
...
@@ -207,14 +214,14 @@
function
output_lang_issue
(
$prefix
,
$key
,
$issue
,
$error
=
true
)
{
echo
'<font color="'
.
(
$error
?
'#cc0000'
:
'#cc9999'
)
.
'"><code>'
;
echo
'qa-lang-<b>'
.
qa_html
(
$prefix
)
.
'</b>.php:'
;
$colorClass
=
$error
?
'severe'
:
'warning'
;
if
(
strlen
(
$key
))
echo
"'<b>"
.
qa_html
(
$key
)
.
"</b>'"
;
$htmlKey
=
strlen
(
$key
)
>
0
?
"'<strong>"
.
qa_html
(
$key
)
.
"</strong>'"
:
''
;
echo
'</code></font> '
.
qa_html
(
$issue
)
.
'<br>'
;
echo
sprintf
(
'<code class="%s">qa-lang-<strong>%s</strong>.php:%s</code> %s<br>'
,
$colorClass
,
qa_html
(
$prefix
),
$htmlKey
,
qa_html
(
$issue
)
);
}
...
...
@@ -224,7 +231,7 @@
$oneread
=
false
;
echo
'<p
style="font-size:80%; color:#999;
">Reading: '
;
echo
'<p
class="includes
">Reading: '
;
}
...
...
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