whoahorse Posted March 28, 2005 Posted March 28, 2005 I have the dumbest question. Can you have an index.html and an index.php in the same folder or would they conflict? I want to ask before I do something dumb here. LOL Weezy Quote
TCH-Thomas Posted March 28, 2005 Posted March 28, 2005 I don´t know much about php but I dont think so. Sorry. Quote
whoahorse Posted March 28, 2005 Author Posted March 28, 2005 WHAT? You don't know the answer? MR SMARTY PANTS! Caught ya on one! Weezy Quote
tomowa Posted March 28, 2005 Posted March 28, 2005 Yes, you can, but which one will display when just entering the directory name, will depend on what your index manager is told to what extensions to recognize as the 'index' page. If you want to be able to call up either page, you will have to spell out the whole path to the file name, complete with the extension, .php or .html. HTH, Tom Quote
TCH-Bruce Posted March 28, 2005 Posted March 28, 2005 Yes, you can have both in the same folder. Problem is if you access the site with just the folder the index.html is the one that will load. But you could access the php file by entering it in the broswer or linking to it. If you remove the index.html the index.php file will be displayed by default. Quote
TCH-Thomas Posted March 28, 2005 Posted March 28, 2005 Cool. TCH Forums - You learn something, everyday. Now, I´ll go and hide and memorize that until next time Weezy asks it. Quote
whoahorse Posted March 28, 2005 Author Posted March 28, 2005 (edited) THANKS Bruce & Tom! You even answered the next question I was going to ask!!! Thanks a ton PHP is new to me, I never worked with it until I moved my sites to TCH and was introduced to all these totally kewl free programs! Weezy Edited March 28, 2005 by whoahorse Quote
whoahorse Posted March 28, 2005 Author Posted March 28, 2005 Cool. TCH Forums - You learn something, everyday. Now, I´ll go and hide and memorize that until next time Weezy asks it. <{POST_SNAPBACK}> Quote
bizmo Posted March 28, 2005 Posted March 28, 2005 (edited) you can also create a .htaccess file and have it point to whatever index file that you want to be the index file. Redirect /index.html http://domain.com/index.php Edited March 28, 2005 by bizmo Quote
whoahorse Posted March 28, 2005 Author Posted March 28, 2005 you can also create a .htaccess file and have it point to whatever index file that you want to be the index file. Redirect /index.html http://domain.com/index.php <{POST_SNAPBACK}> Thanks! Great info! Weezy Quote
tomowa Posted March 29, 2005 Posted March 29, 2005 Your welcome Weezy PHP is new to me, I never worked with it until I moved my sites to TCH andwas introduced to all these totally kewl free programs! It's new to me too, but where does one find time to play with all the neat PHP scripts that are out there Quote
whoahorse Posted March 30, 2005 Author Posted March 30, 2005 OK I have to show you what I did - so you know what I was talking about. This site is NOT done, this is not a chance to critique it. LOL!!! http://www.whoahorse.com/JKL/ Weezy Quote
tomowa Posted March 30, 2005 Posted March 30, 2005 Ok, I see the reason for your question that started this topic. You are using frame's, and from the index.html it is linking to an index.php, which is in the same directory. It all works, and you can call for the page just by it's directory name, as it looks for the index.html. Now, to really make it cool (not a critique LOL!!!), you would make the 'header' a PHP page, and then using the php 'include' function, make all those various pages you link to include that header right into them. Then you would not have the scroll bar looking 'out of place', it appearing on the target pages, but not on the header. I just got my PHP book last week to start in on PHP, but have only had time to glance through it so far and not write any code yet, but the PHP includes was one of the first concepts I read about in it Isn't this fun Quote
whoahorse Posted March 30, 2005 Author Posted March 30, 2005 Those are all super ideas (THANKS!!!), but I don't think frontpage supports PHP and that is what I build with Weezy Quote
stevevan Posted March 30, 2005 Posted March 30, 2005 I don't think it does natively, but you can always enter code into the HTML tab on Frontpage! I've done that in the past and it works just fine! Quote
whoahorse Posted March 30, 2005 Author Posted March 30, 2005 Hey Steve, Is there an advantage to coding in PHP? Weezy Quote
stevevan Posted March 30, 2005 Posted March 30, 2005 I think it makes life a little easier to update pages if you use includes. It's also easy to incorporate databases into your site. The are, by no means, the only reasons to use PHP. Compared to some of the other family members here, I have limited experience with PHP. However, what little I am using, makes updating on my site VERY quick and easy. (And I always try to find the easies way possible! ) Quote
whoahorse Posted March 30, 2005 Author Posted March 30, 2005 Hey Steve! That is interesting info, I will have to investigate PHP more. Weezy Quote
bizmo Posted April 5, 2005 Posted April 5, 2005 I also use FrontPage for my site, and have no problems editing and publishing my PHP files. The key is that when you make an edit, Save, but don't close the file once you have edited it. Then publish, and see if you get the desired results. If not, or if your site breaks (as mine has many times, lol) then you simply hit the Undo button to undo all the changes that you made, republish, and the site is working again. Just remember not to close the file/page until it is working as you want it to. Quote
stevevan Posted April 5, 2005 Posted April 5, 2005 Thanks for the info bizmo! I'll have to file that one away in my data banks. Quote
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.