nycmattw Posted June 6, 2010 Share Posted June 6, 2010 For some reason my index.php page is not showing on my website. The following code is used for the index.php page: <?php ////////////////////////////////////////////////// // FlowUI CMS Developer Edition // // Version 1.0 Alpha // ////////////////////////////////////////////////// include "funct.php"; $section = $_GET['p']; if($section == support) { include 'support.php'; } file_get_contents('home.html'); ?> I don't see anything wrong? Also to see the index.php page (its not gonna work anyway) it can be seen here: http://lacydic.com Link to comment Share on other sites More sharing options...
0 Stephen Veteran Posted June 6, 2010 Veteran Share Posted June 6, 2010 if($section == support) { should be if($section == "support") { Link to comment Share on other sites More sharing options...
0 nycmattw Posted June 6, 2010 Author Share Posted June 6, 2010 That still didn't fix the job. Link to comment Share on other sites More sharing options...
0 markwolfe Veteran Posted June 6, 2010 Veteran Share Posted June 6, 2010 (edited) Seems to work. Visit your site this way: http://lacydic.com/index.php?p=support And you will see content is included only when specifying "support" for "p" What is your intention with "file_get_contents", however? :unsure: EDIT: the function "file_get_contents" is intended to return the contents of a file into a string. For example: $page_in_string = file_get_contents('home.html'); Link to comment Share on other sites More sharing options...
0 nycmattw Posted June 6, 2010 Author Share Posted June 6, 2010 Seems to work. Visit your site this way: http://lacydic.com/index.php?p=support And you will see content is included only when specifying "support" for "p" What is your intention with "file_get_contents", however? :unsure: Mark, I'm trying to get into index.php not support.php Also if you look at my previous thread about translating html to php you'll see. Link to comment Share on other sites More sharing options...
0 RoomKid Posted June 6, 2010 Share Posted June 6, 2010 Mark, I'm trying to get into index.php not support.php Also if you look at my previous thread about translating html to php you'll see. <?php ////////////////////////////////////////////////// // FlowUI CMS Developer Edition // // Version 1.0 Alpha // ////////////////////////////////////////////////// include "funct.php"; $section = $_GET['p']; if($section == 'support') { include 'support.php'; } else { include 'home.html'; } ?> Link to comment Share on other sites More sharing options...
0 markwolfe Veteran Posted June 6, 2010 Veteran Share Posted June 6, 2010 Mark, I'm trying to get into index.php not support.php Also if you look at my previous thread about translating html to php you'll see. I don't typically search all of a user's posts when trying to help out. I expected the relevant information in the thread. Your index.php DOES include support.php. If your statement that you don't want support.php from this page, then you are going about it the wrong way, because it is certainly being included when you have a ?p=support in your url. Your "file_get_contents('home.html');" is probably what you are having problems with now. I think you intended on including and displaying the contents. The statement, as it exists, does nothing. You haven't said that is what you want to do, so I have to guess a bit. Anyhow, try doing an include "home.html"; and see if that is what you are after. Link to comment Share on other sites More sharing options...
0 nycmattw Posted June 6, 2010 Author Share Posted June 6, 2010 Hmm that actually worked. Thanks mark! Link to comment Share on other sites More sharing options...
0 markwolfe Veteran Posted June 6, 2010 Veteran Share Posted June 6, 2010 No problem. (Y) Link to comment Share on other sites More sharing options...
0 Andrew Lyle Global Moderator Posted June 6, 2010 Global Moderator Share Posted June 6, 2010 Appears you are also missing some <?php tags in Register.php.. your code is showing Link to comment Share on other sites More sharing options...
Question
nycmattw
For some reason my index.php page is not showing on my website. The following code is used for the index.php page:
<?php ////////////////////////////////////////////////// // FlowUI CMS Developer Edition // // Version 1.0 Alpha // ////////////////////////////////////////////////// include "funct.php"; $section = $_GET['p']; if($section == support) { include 'support.php'; } file_get_contents('home.html'); ?>I don't see anything wrong? Also to see the index.php page (its not gonna work anyway) it can be seen here: http://lacydic.com
Link to comment
Share on other sites
9 answers to this question
Recommended Posts