dongxiandi8313 2017-10-14 07:50 采纳率: 100%
浏览 76
已采纳

添加字符串以输出PHP文件

So I have this code:

imagepng($image, 'Result.png');

It will create Result.png file in my server in the same folder

Now I wonder, how to create file like

Result123.png
Result1256.png

Both 123 and 1256 is a value of

$text

Thanks

  • 写回答

2条回答 默认 最新

  • dongshi6529 2017-10-14 07:52
    关注

    You need to do is:-

    imagepng($image, "Result$text.png");
    

    Note:- I assume that $text is a string variable containg different-different values every-time.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?