Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dolibarr
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container Registry
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Software_Artifact_Infrastructure_Repository
dolibarr
Commits
c7e4c338
Commit
c7e4c338
authored
15 years ago
by
Laurent Destailleur
Browse files
Options
Downloads
Patches
Plain Diff
More flexible usage of option MAIN_OPTIMIZE_SPEED
parent
3d685738
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
htdocs/main.inc.php
+2
-2
2 additions, 2 deletions
htdocs/main.inc.php
htdocs/translate.class.php
+1
-1
1 addition, 1 deletion
htdocs/translate.class.php
with
3 additions
and
3 deletions
htdocs/main.inc.php
+
2
−
2
View file @
c7e4c338
...
...
@@ -759,7 +759,7 @@ function top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs
require_once
DOL_DOCUMENT_ROOT
.
'/lib/ajax.lib.php'
;
$mini
=
''
;
$ext
=
'.js'
;
if
(
!
empty
(
$conf
->
global
->
MAIN_OPTIMIZE_SPEED
))
{
$mini
=
'_mini'
;
$ext
=
'.jgz'
;
}
// mini='_mini', ext='.gz'
if
(
isset
(
$conf
->
global
->
MAIN_OPTIMIZE_SPEED
)
&&
(
$conf
->
global
->
MAIN_OPTIMIZE_SPEED
&
0x01
))
{
$mini
=
'_mini'
;
$ext
=
'.jgz'
;
}
// mini='_mini', ext='.gz'
// This one is required for all Ajax features
if
(
!
defined
(
'DISABLE_PROTOTYPE'
))
...
...
@@ -1174,7 +1174,7 @@ function llxFooter($foot='')
if
(
!
empty
(
$_SERVER
[
'DOL_TUNING'
]))
{
$micro_end_time
=
dol_microtime_float
(
true
);
print
"
\n
"
.
'<script type="text/javascript">window.status="MAIN_OPTIMIZE_SPEED '
.
(
empty
(
$conf
->
global
->
MAIN_OPTIMIZE_SPEED
)
?
'off - '
:
'on -
'
)
.
'Build time: '
.
ceil
(
1000
*
(
$micro_end_time
-
$micro_start_time
))
.
' ms'
;
print
"
\n
"
.
'<script type="text/javascript">window.status="MAIN_OPTIMIZE_SPEED '
.
(
isset
(
$conf
->
global
->
MAIN_OPTIMIZE_SPEED
)
?
$conf
->
global
->
MAIN_OPTIMIZE_SPEED
:
'off
'
)
.
'
-
Build time: '
.
ceil
(
1000
*
(
$micro_end_time
-
$micro_start_time
))
.
' ms'
;
if
(
function_exists
(
"memory_get_usage"
))
{
print
' - Mem: '
.
memory_get_usage
();
...
...
This diff is collapsed.
Click to expand it.
htdocs/translate.class.php
+
1
−
1
View file @
c7e4c338
...
...
@@ -197,7 +197,7 @@ class Translate {
// Enable cache of lang file in memory (faster but need more memory)
// Speed gain: 40ms - Memory overusage: 200ko (Size of session cache file)
$enablelangcacheinmemory
=
empty
(
$conf
->
global
->
MAIN_OPTIMIZE_SPEED
)
?
0
:
$conf
->
global
->
MAIN_OPTIMIZE_SPEED
;
$enablelangcacheinmemory
=
((
isset
(
$conf
->
global
->
MAIN_OPTIMIZE_SPEED
)
&&
(
$conf
->
global
->
MAIN_OPTIMIZE_SPEED
&
0x02
))
?
true
:
false
)
;
//$enablelangcacheinmemory=true;
if
(
$alt
==
2
&&
$enablelangcacheinmemory
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment