Wasiu0607
04-19-2004, 12:02 AM
I was wondering if I can make a HTML page ending in html or htm and also install PhPNuke in the same page? Thanks
|
Click to See Complete Forum and Search --> : HTML & PHP Together?! Wasiu0607 04-19-2004, 12:02 AM I was wondering if I can make a HTML page ending in html or htm and also install PhPNuke in the same page? Thanks ray326 04-19-2004, 12:17 AM Not without causing the PHP processor to parse all pages, even straight static ones. Wasiu0607 04-19-2004, 08:29 PM So it'll work if I rename it to .php? What if I want a frame page for my content page? Doesn't the content page have to end in .htm?? Can I do both? Thanks. PeOfEo 04-19-2004, 08:32 PM no, it can end in a php, but stop using frames in general because frames suck. If you want accessability and a site that has a layout do not go near frames. Php can work from a static html page if you have a form and you are calling a php script with that form action, but that is going to limit your functionaliy, it is the same way with cgi, jsp, asp, asp.net, and others, you can call a script from a form action but you are still using a static page so it accomplishes little. If you have a thing for the .html extnetion you can make the server parse that extention like a .php extention, I do not know php, nor claim too, but I have seen the word 'chmod' come up and I think that is what you do on apache when you change the extentions. The php extnetion is just fine, infact you will be using html with php, because php outputs html to the browser, all of my pages have a .aspx format because I use asp.net, but the output is either xhtml 1.1 or html 4.01 transitional. The Cheat 04-19-2004, 11:01 PM If you have a thing for the .html extnetion you can make the server parse that extention like a .php extention, I do not know php, nor claim too, but I have seen the word 'chmod' come up and I think that is what you do on apache when you change the extentions. chmod is a unix command that you use to change file permissions. to make the .html extention be processed by php, create a .htaccess file and add the line: AddType application/x-httpd-php .html then save it and as .htaccess (not whatever.htaccess -, it is just .htaccess) Then simply upload the .htaccess file in the same folder that you put all of your web pages However i'd ask your host to make sure you are allowed to do this if i were you. In fact, If i were you i'd just use .php. oh yeah, one more thing. If you decide to use the method above to make .html processed by php, You may need to add the line: <?php Header ("Content-type: text/html"); ?> to the top of every .html page. good luck. EDIT: Forgot to say that .htaccess will probably only work for apache webserver (which most likely is your webserver, if you use php). PeOfEo 04-19-2004, 11:02 PM ahhh, well I was almost on target, oh well... You can tell I do not know my unix commands! neenach2002 04-20-2004, 12:59 AM And you call yourself a Super Moderator?....Just kidding...;) EDIT:....er....it has been brought to my attention that PeOfEo is not a Super Moderator....but a Super Terrific Moderator...so...lol...sorry PeOfEo!;) Wasiu0607 04-20-2004, 09:27 PM Thanks guys :) . I'm unfamiliar with PHP... Is there a PHP script that acts like SSI so I don't have to put in the whole layout code for every single page I make? Conor 04-20-2004, 09:45 PM include("whatever.ext"); Wasiu0607 04-20-2004, 09:51 PM Is there a website that teaches me about putting the "include" codes into the main layout page? Conor 04-20-2004, 09:59 PM http://us4.php.net/include/ PeOfEo 04-20-2004, 10:18 PM Originally posted by neenach2002 And you call yourself a Super Moderator?....Just kidding...;) No, I am a super terric moderator, I am a moderator who is also a super terrific person. neenach2002 04-20-2004, 10:27 PM Fixed it....happy?....j/k...:p Wasiu0607 04-21-2004, 12:42 AM 1 more question. Since the layout I'm making does not have unlimted height (its a square table), can PHP make a scrollable content page (not frames)? thx The Cheat 04-21-2004, 01:53 AM Originally posted by PeOfEo No, I am a super terric moderator, I am a moderator who is also a super terrific person. whats a terric (http://dictionary.reference.com/search?q=terric&db=*) :p Wasiu0607 04-21-2004, 02:59 PM Can PHP make a scrollable content page (not frames)? The Cheat 04-21-2004, 03:20 PM Originally posted by Wasiu0607 Can PHP make a scrollable content page (not frames)? Im kind of confused about your question...........But i think that you should just go learn html before you try and learn php or any server side language. PeOfEo 04-21-2004, 05:01 PM Originally posted by Wasiu0607 Can PHP make a scrollable content page (not frames)? No, it can't. Php is a server side language and this is a client side question. Php has the same client server boundry lines as asp cgi jsp asp.net and other things. If you want something to scroll without a frame use a div. <div style="height:500px; width:500px; overflow:auto;">content here will scroll when it is bigger then the div</div> Wasiu0607 04-21-2004, 05:29 PM Yeah, I was thinking of using DIV tags, but wouldn't DIV screw up my layout if it's viewed other than IE? Or not...... 1 more thing. If i want to use the php code "include" in my content page, I just add the code after my DIV codes right? thx :D PeOfEo 04-21-2004, 06:08 PM <div> will not screw up your layout in ie... ie supports height and width and the overflow css attributes, those are all fine, you are not digging into the box model with this <div> include </div> put the include between the beginning and end tags and the server will parse in the conetents of the external file. Wasiu0607 04-21-2004, 06:15 PM thx so much! solavar 04-22-2004, 03:28 AM Originally posted by PeOfEo If you want something to scroll without a frame use a div. Excellent! There I was sticking in iframes here and there just to allow certain sections to scroll. To discover I can do away with iframes! Thank you, thank you, thank you! PeOfEo 04-22-2004, 06:14 AM no problem. webdeveloper.com
Copyright WebMediaBrands Inc., All Rights Reserved. |