regan
regan

Reputation: 405

php include file with / in name?

can anyone tell me if it's possible to include a file that includes a / in the filename? Does the name need to be escaped a certain way when calling it in include? Or not possible. ie. my.file/name.inc.php

Upvotes: 0

Views: 56

Answers (2)

Peter Kiss
Peter Kiss

Reputation: 9319

A filename can't contain directory separator in it's name on any platform so everything will be okay.

Upvotes: 1

Brad
Brad

Reputation: 163272

Yes, of course it's possible. Just include the file.

require_once('path/to/your/file.php');

Upvotes: 0

Related Questions