开发者

Can i use this statement

i this a valid command

$fp = fopen($hyphen + ".html","w");

I ha开发者_运维技巧ve declared $hyphen already.But it doesn't seem to be working


string concatenation in php works by using . (instead of + like other languages use (java, javascript, c++ ...)), so you have to change your script to this:

$fp = fopen($hyphen . ".html","w");
                // ^^^ this has to be a dot, not a plus


Nope. Join the two parts of the filename using a dot instead of a plus sign, and it should work.


There is an error. Try:

$fp = fopen($hyphen . ".html","w");
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜