PHP中字符串的连接使用点,不是加号。换行\n需要用双引号括起来,不能用单引号。

eg.

<?php

print_r("hello"."\n");

print_r("world"."\n");

print_r('hello'.'world'."\n");

?>

结果:

hello

world

hello world

相关文章:

  • 2022-12-23
  • 2021-12-04
  • 2021-10-07
  • 2021-12-05
  • 2021-09-02
  • 2021-05-21
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2023-04-03
  • 2021-12-13
  • 2022-12-23
相关资源
相似解决方案