jhodara Posted December 12, 2010 Share Posted December 12, 2010 Hi, I have these variables for pages I navigate to because I pass them in the query string. However, I need a variable for the homepage (index.php), before any query string is created. I cant declare a vari $_GET['intro'] ; $_GET['about'] ; $_GET['contact'] ; However, I need a variable for the homepage (index.php), before any query string is created. I cant declare a variable in index.php because it will be used throughout the entire website. I also cant declare the variable in home.php (the bulk content of the homepage) because I need to use the variable before home.php is included. Is their a trick for this? Thanks! Quote Link to comment https://forums.phpfreaks.com/topic/221370-want-to-declare-variable-for-homepage/ Share on other sites More sharing options...
dreamwest Posted December 12, 2010 Share Posted December 12, 2010 RewriteRule ^$ index.php?var1=statement&var2=statement [L,QSA] Quote Link to comment https://forums.phpfreaks.com/topic/221370-want-to-declare-variable-for-homepage/#findComment-1146080 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.