Patriot Posted January 20, 2008 Share Posted January 20, 2008 Thanks for looking! I am making a public script and I'm wondering how the owner can edit a text file that has the name of the site. Then, when people view pages, the title will be the name of the site stored in the text file. I was going to do this with a MySQL query, but figured it makes more sense to retrieve it from a text file. Thanks, Gil Quote Link to comment https://forums.phpfreaks.com/topic/86853-help-with-dynamic-php-page-titles/ Share on other sites More sharing options...
pkSML Posted January 20, 2008 Share Posted January 20, 2008 Just have a file named settings.php. Make the file like so: <?php $title = "The Coolest Website Ever"; // The name of your site $other_variable = "true"; ... ?> And then include settings.php before any HTML is produced in the main script. Quote Link to comment https://forums.phpfreaks.com/topic/86853-help-with-dynamic-php-page-titles/#findComment-443916 Share on other sites More sharing options...
Patriot Posted January 20, 2008 Author Share Posted January 20, 2008 ??? Thanks, I didn't even think of this. For some reason, it seemed like people couldn't edit PHP files (wow, I need to think a little more) Quote Link to comment https://forums.phpfreaks.com/topic/86853-help-with-dynamic-php-page-titles/#findComment-444014 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.