uploading data precaution Flashcards

1
Q

$name = preg_replace(“/[^A-Za-z0-9.]/”, “”, $name);

A

leaves only the characters A-Z, a-z, 0-9, and period in the string $nae, and strips out anything else

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

$name = strtolower(ereg_replace(“[^A-Za-z0-9.]”, “”, $name));

A

changes all uppercase characters to lowercase and strips out anything besides characters a-z, 0-9 and period.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly