Description

This function sets the OptimizeWS module's environments.

  • If mod_deflate rules exist in the account's .htaccess file, the function attempts to parse them and change the {'deflate_selected'} environment's value to  'list'.
  • The function will send the value to the list of currently compressed file types.
 

Examples


$cpanel = new CPANEL(); // Connect to cPanel - only do this once.
$load_settings = $cpanel->api1('OptimizeWS', 'loadoptimizesettings'); // Call the function.

my $cpliveapi = Cpanel::LiveAPI->new(); # Connect to cPanel - only do this once.
my $load_settings = $cpliveapi->api1(OptimizeWS, loadoptimizesettings); # Call the function.

<cpanel Module="OptimizeWS::loadoptimizesettings ()">
cpapi1 --user=username OptimizeWS loadoptimizesettings

This function does not return output, but sets the following environments for the OptimizeWS functions:

  • {'deflate_selected'} = 'disabled'

  • {'deflate_mime_list'} = 'text/html text/plain text/xml'
  • {'optimize_apache_version'} = Current Apache version.

Parameters

This function does not accept parameters.

Returns

This function does not return output, but sets the following environments for the OptimizeWS functions:

  • {'deflate_selected'} = 'disabled'

  • {'deflate_mime_list'} = 'text/html text/plain text/xml'
  • {'optimize_apache_version'} = Current Apache version.

.