There is a grammar question in the process of linking php and mysql.

Asked 2 years ago, Updated 2 years ago, 43 views

I'm practicing linking php and mysql. If you look at the example, the way you approach the table column is a little different, but I wonder if they have the same meaning or not, and I want to know what the names are. 1)1).$rd[name] 2)2)$rd['name']

mysql php html

2022-09-22 20:22

1 Answers

Php 5.4 or higher

$rd[name]

This results in a warning (or error...).

$rd['name']

You should use quotation marks to access the key values.

The . (point) is used to associate variables with variables or strings.

$stringVar = "hello";
echo $stringVar." world";  // hello world


2022-09-22 20:22

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.