|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2007-06-16 16:22 UTC] roberto at spadim dot com dot br
Description: ------------ FROM THE SAME EMAIL TO alan_k@php.net hello alan, i was using bcompiler to act like an php source code compiler i write something like: $fh = fopen($destination, "wb"); $ret1=bcompiler_write_header($fh); $ret2=bcompiler_write_file($fh,$source); $ret3=bcompiler_write_footer($fh); fclose($fh); ok when i run the file on another path that wasn't the same that i "encoded" it apache send me this error: *Warning*: Could not redefine function spd_echo in */home/apache/172.16.0.1/work-rdm/encoder/rdm-business/index.spadim* on line *2* this is very strange, since my file is located at /home/apache/172.16.0.1/rdm-encoded/ and it's not a symbolic link it's a real file any idea? thanks if i could just "compile" the code could be easier :) since it's what i'm searching, i bought the byterun compiler but it don't work at php 5.2 Reproduce code: --------------- see description Expected result: ---------------- see description Actual result: -------------- see description PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 27 08:00:01 2025 UTC |
[2007-06-15 17:40:35] roberto at spadim dot com dot br i was thinking could you make an function like this: $content=bcompiler_get_compiled_data_from_file("file_that_i_want_bytecode_to_be_removed.php"); file_put_contents("file_encoded_with_byte_codes.php", "<?php bcompiler_execute_from_string(base64_decode(\"".base64_encode($content)."\")); ?>"); this is what i'm searching read an file get content data of bytecode, (since i don't know zend core very well, i can't get bytecode from my php source) create an file that load bytecode with this we remove problems of file location and other stuffs, since code is "bytecoded" and loaded again from another function (bcompiler_execute_from_string) thankx alan