html - Require php line of code not working -




very new of , having issues using line of code.

all trying have html file have require statement pulls php file not working. please help.

<?php require 'localhost/php/loginscreen.php'; ?> 

"all trying have html file have require statement pulls php file not working".

that me suggests you're using .html file base file pull in .php file.

unless you've instructed server treat .html files php, need rename file .php extension.

edit. consult following q&a on stack on how this:

your syntax require 'localhost/php/loginscreen.php'; incorrect.

you need either use full system path: (as example, replace system path).

require '/var/usr/public/php/loginscreen.php'; 

or relative path:

require 'php/loginscreen.php'; 

and using http://localhost rather possible file:/// url in browser.

"strange there no error. refresh html file nothing happens."

had viewed html source, have have seen code, rather parsed (php) directives. have been reason why did not see errors, least not php-wise.





wiki

Comments

Popular posts from this blog

Asterisk AGI Python Script to Dialplan does not work -

python - Read npy file directly from S3 StreamingBody -

kotlin - Out-projected type in generic interface prohibits the use of metod with generic parameter -