{"id":63531,"date":"2023-07-24T01:53:49","date_gmt":"2023-07-23T17:53:49","guid":{"rendered":"http:\/\/lrxjmw.cn\/?p=63531"},"modified":"2023-07-24T01:53:49","modified_gmt":"2023-07-23T17:53:49","slug":"peachpie-net-php","status":"publish","type":"post","link":"https:\/\/lrxjmw.cn\/peachpie-net-php.html","title":{"rendered":"Peachpie\u5347\u7ea7\u4e86\uff0c\u4f53\u73b0PHP\u8de8\u5e73\u53f0\u4f18\u8d8a\u6027"},"content":{"rendered":"
\u5728\u5bf9 Peachpie \u7684\u7528\u6cd5\u8fdb\u884c\u4e86\u4e00\u4e9b\u5de5\u4f5c\u4e4b\u540e\uff0c\u73b0\u5728\u56de\u5230\u4e86\u5728\u7f16\u8bd1\u5668\u672c\u8eab\u5b9e\u73b0\u7684\u6838\u5fc3\u529f\u80fd\u3002\u76ee\u524d\u6b63\u5728\u66f4\u52a0\u63a5\u8fd1\u5b8c\u6210\u9879\u76ee\u7684\u201c\u521d\u8877\u201d \u2014 \u80fd\u591f\u8fd0\u884c\u5b8c\u6574\u7684\u73b0\u5b9e\u4e16\u754c\u7684\u5e94\u7528\u7a0b\u5e8f
\n<\/p>\n
<?php\r\nsession_start(); \/\/ this actually initializes $_SESSION from ISession service\r\necho $_SESSION['counter']++; \/\/ here we change PHP session variable\r\nsession_commit(); \/\/ and this serializes $_SESSION back into ISession and saves the session object\r\n<\/pre>\n\u8bc4\u4f30\u4ee3\u7801<\/strong><\/span><\/div>\n<?php function main() \r\n{ \/\/; \/\/ g : Generator\r\n<\/pre>\nVSCode \u6269\u5c55<\/strong><\/span><\/div>\n\u5bf9\u56fe\u50cf\u548c GD2 \u7684\u5b9e\u9a8c\u6027\u652f\u6301<\/strong><\/span><\/div>\n\n\u00a0\u53d1\u5e03\u4e3b\u9875<\/a><\/p>\n
\n\nPeachpie \u662f\u4e00\u4e2a\u7528\u4e8e\u00a0.NET \u5e73\u53f0\u4e0a\u7684\u7684 PHP \u7f16\u8bd1\u5668\u548c\u8fd0\u884c\u65f6\u3002\u4f5c\u4e3a PHP \u8bed\u8a00\u7684\u5b8c\u5168\u91cd\u65b0\u5b9e\u73b0\uff0c\u5b83\u5141\u8bb8\u5b8c\u5168\u4f7f\u7528\u00a0.NET \u8fdb\u884c\u7f16\u5199\uff0c\u5e76\u5728 .NET Framework\u3001NET Core \u548c Mono \u4e0a\u8fd0\u884c PHP\u3002Peachpie \u53ef\u4ee5\u65e0\u7f1d\u5229\u7528 .NET \u5bf9\u8c61\uff0c\u53e6\u4e00\u65b9\u9762\uff0c\u4e5f\u53ef\u4ee5\u8ba9 C# \u4ee3\u7801\u76f4\u63a5\u8bbf\u95ee\u5df2\u7f16\u8bd1\u7684 PHP \u51fd\u6570\u3001\u53d8\u91cf\u548c\u7c7b\u3002<\/p>\n
Peachpie \u9879\u76ee\u7684\u76ee\u6807\u662f\u5c06 PHP \u4ee3\u7801\u5e93\u8fc1\u79fb\u81f3 .NET\uff0c\u4ece\u800c\u53ef\u901a\u8fc7\u5404\u81ea\u7684 API \u4e3a PHP \u63d0\u4f9b .NET \u548c ASP.NET \u8fd0\u884c\u65f6\u3002<\/p>\n<\/div>\n<\/div>\n
\n\u76f8\u5173\u94fe\u63a5<\/div>\n\n
- Peachpie \u7684\u8be6\u7ec6\u4ecb\u7ecd\uff1a\u70b9\u51fb\u67e5\u770b<\/a><\/li>\n
- Peachpie \u7684\u4e0b\u8f7d\u5730\u5740\uff1a\u70b9\u51fb\u4e0b\u8f7d<\/a><\/li>\n<\/ul>\n<\/div>\n
\r\n\r\n\u672c\u7ad9\u6587\u7ae0\u9664\u6ce8\u660e\u8f6c\u8f7d\u5916\uff0c\u5747\u4e3a\u672c\u7ad9\u539f\u521b\u6216\u7f16\u8bd1\u3002\u6b22\u8fce\u4efb\u4f55\u5f62\u5f0f\u7684\u8f6c\u8f7d\uff0c\u4f46\u8bf7\u52a1\u5fc5\u6ce8\u660e\u51fa\u5904\uff0c\u5c0a\u91cd\u4ed6\u4eba\u52b3\u52a8\u5171\u521b\u5f00\u6e90\u793e\u533a\u3002<\/div>\r\n\u8f6c\u8f7d\u8bf7\u6ce8\u660e\uff1a<\/span>\u6587\u7ae0\u8f6c\u8f7d\u81ea \u5f00\u6e90\u4e2d\u56fd\u793e\u533a [http:\/\/www.oschina.net]<\/a><\/div>\r\n\u672c\u6587\u6807\u9898\uff1a<\/span>Peachpie 0.7.0 \u7684\u65b0\u7279\u6027\uff0c.NET \u5e73\u53f0\u4e0a\u7684 PHP \u7f16\u8bd1\u5668<\/div>\r\n