Advanced options

Top  Previous  Next

--asp-tags   

 

Enables the use of ASP-like <% %> tags in source code. Use this option if you use asp-style tags in your PHP scripts.

 

 

--short-tags 

 

Enables the use of short PHP's <? ?> tags in source code. Use this option if you use short PHP's tags in your PHP scripts.

 

 

-p "code"    

 

Prepend header code. You may put any code to be executed BEFORE the protected scripts code. This code WILL NOT BE ENCODED. This may be either HTML text or PHP code. For PHP code - you should use <?php ?> tags. This option is usually used for including copyrights into protected scripts. You should prepend all double quote characters with a back slash if you want to include them into the code ( " -> \" ).

 

Example 1:

 

-p "<!-- My protected script. Copyright by \"My Name\" -->"

 

Example 2:

 

-p "<span class=\"bold\">My protected script. Copyright by My Name</span>"

 

Example 3:

 

-p "<?php echo \"My protected script. Copyright by My Name\"; ?>"

 

 

-j "code"    

 

It is possible for you to change the default loader error code. This option allows you to change the default error action of the protected script if it cannot find an appropriated ixed loader. The default action is just to print an error message "This script is protected by SourceGuardian™  and requires file ... " and stop executing. You may use any HTML text or PHP code here and it will be displayed or executed as a replacement to the default SourceGuardian™  loader error. This code WILL NOT BE ENCODED. This may be either HTML text or PHP code. For PHP code - you should use <?php ?> tags. You should prepend all double quote characters with a back slash if you want to include them into the code ( " -> \" ).

 

Example 1:

 

-j "<a href=\"email:admin@domain.com\">Contact administrator</a>"

 

Example 2:

 

-j "<?php header(\"Location: /myhandler.php\"); exit(); ?>"

 

 

Prepend header code and Loader error code may be loaded from a file

 

Prepend header code option -p and Loader error code option -j may load the source from a file. Use @filename as a parameter for -p or -j.

 

Example: encode4 -p @prepend.php -j @loadererr.php myscript.php

 

The code is loaded during encoding and stored as is *non encoded* as that code should be executable when no ixed loader is loaded yet.

 

 

-n           

 

Don't integrate the ixed loader. you may use this option if you don't want to include a default loader into the protected script. Any script encoded using this option will not be able to automatically find and load the appropriate ixed loader and you have to install the ixed loader manually to run this script. See the section above about the manual ixed installation. This option may not used with -j option.

 

-z[0-9] - compression level.  Higher compression level gives smaller output scripts which run faster but encoding process will be slower (and vice versa).