Jump to content

Variables not Outputting


xyn

Recommended Posts

Hi Guys,
I have got a website, which uses a Configuration file, and the config
variables will NOT output. an example is below:

config.php
[code=php:0]<?php
$website_url = "http://www.example.com/folder/";
$website_name = "my web name";
?>[/code]

functions.php
[code=php:0]<?php
retuire("config.php");
function  register(){
do the register bit.
echo ($website_name . "- Activation sent!"); // problem here!
echo ("Bla bla bla");
}
?>[/code]

index.php
[code=php:0]<?php
require("config.php");
require("functions.php");
?>
HTML GOES HERE
<?php
register();
?>
HTML ENDING BITS GO HERE[/code]
Link to comment
https://forums.phpfreaks.com/topic/32276-variables-not-outputting/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.