ionCube Logo
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


 
Post new topic   Reply to topic    ionCube Forum Index -> ionCube PHP Encoder

PHP : Keep a comment readable in the encoded file.

Author Message
goozak



Joined: 07 Nov 2012
Posts: 3
Location: Montreal, QC

PostPosted: Tue Jul 26, 2016 4:13 pm    Post subject: PHP : Keep a comment readable in the encoded file. Reply with quote

I want some of my encoded PHP files to contain a (sometimes long) comment explaining how to use each script. Is there a way to have those comments in each file and be preserved by the encoding?

I tried with documentation comments (and the --no-doc-comments option), but these seem to always be removed/encoded, no matter if the "Suppress doc comments" is checked or not...

The "Header text" option (--add-comment) is not really practical as it needs to be set separately.

Here is a sample file for my test :

Code:
<?php

/**
 * This comment should be preserved
 */

phpinfo();
?>
Back to top
View user's profile Send private message
liaison
ionCube Support


Joined: 16 Dec 2004
Posts: 2771

PostPosted: Wed Jul 27, 2016 5:48 pm    Post subject: Reply with quote

Any custom comments apply to all files encoded, but you could encode different files with different runs of the Encoder. Doc comments are metadata associated with elements of the code such as classes that are programmatically retrievable via the related PHP functions. Ordinarily these are not part of encoded files but they can be preserved if software does need to retrieve such metadata.
_________________
Community Admin
Back to top
View user's profile Send private message
goozak



Joined: 07 Nov 2012
Posts: 3
Location: Montreal, QC

PostPosted: Wed Jul 27, 2016 7:49 pm    Post subject: Reply with quote

Thanks for the reply!

I guess I could save the comments in a text file and use that when encoding the file on its own. I was hoping for a 'one file' solution, but this 'two files' option might also work.

Smile
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    ionCube Forum Index -> ionCube PHP Encoder All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum