Webmaster Forum

Go Back   Webmaster Forum > Web Development > Coding Forum

Coding Forum Problems with your code? Discuss coding issues, including JavaScript, PHP & MySQL, HTML & CSS, Flash & ActionScript, and more.


Reply
 
LinkBack Thread Tools Display Modes
Old 09-13-2009, 08:01 PM   #1 (permalink)
Junior Member
 
Join Date: 05-07-09
Posts: 4
iTrader: 0 / 0%
Latest Blog:
None

Zippey is liked by many
Converting static web pages to php

I'm planning on converting my static HTML pages to php but concerned about a few issues:

If I convert my HTML to files with php file extensions I will loose all my incomming links. Correct? Why do I need a php file extentions for HTML files with embedded php? Why does a HTML file need a php extension just because it has php in it?
Zippey is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-13-2009, 08:27 PM   #2 (permalink)
Super Moderator
 
htmlbasictutor's Avatar
 
Join Date: 10-29-07
Location: British Columbia, Canada
Posts: 3,301
iTrader: 0 / 0%
Latest Blog:
Website Testing

htmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web pro
Quote:
Originally Posted by Zippey View Post
If I convert my HTML to files with php file extensions I will loose all my incomming links. Correct?
Yes if you don't do a permanent 301 redirect for each and every page you convert.

Quote:
Originally Posted by Zippey View Post
Why do I need a php file extentions for HTML files with embedded php?
You don't. You can add the following to your .htaccess file and render php coding in HTML pages.

Code:
AddType x-mapp-php5 .html .htm
Assuming your web server uses PHP5. If it's using PHP4, then changing the 5 to a 4 should work.

Note: You won't see the PHP rendered coding when viewing the web page offline. e.g. if you use this for PHP includes, you won't see the included content until you upload the includes and page to the web server then view the live page.
Quote:
Originally Posted by Zippey View Post
Why does a HTML file need a php extension just because it has php in it?
It doesn't. Showed you above how to do it.
__________________
HTML Basic Tutor - Learn to code your web pages/blogs
Basic Computer Information - Computer Basics for website owners

Trouble getting indexed? Maybe it's something techincal - Pm me.
htmlbasictutor is online now  
Add Post to del.icio.us
Reply With Quote
Old 09-14-2009, 12:26 AM   #3 (permalink)
Contributing Member
 
bogs's Avatar
 
Join Date: 08-01-07
Posts: 1,095
iTrader: 0 / 0%
Latest Blog:
Scottish Fold Cat

bogs is a jewel in the roughbogs is a jewel in the roughbogs is a jewel in the roughbogs is a jewel in the roughbogs is a jewel in the roughbogs is a jewel in the rough
you don't have to use or add php on your site if its not necessary.. one reason of using it is for some online transaction and other functionalities..
bogs is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-14-2009, 05:04 AM   #4 (permalink)
Junior Member
 
Join Date: 05-07-09
Posts: 4
iTrader: 0 / 0%
Latest Blog:
None

Zippey is liked by many
I have a lot of data that's growing and I think things should be database driven. I think a php interface to a mySQL database is best way to go, unless someone can suggest otherwise.
Zippey is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-14-2009, 06:02 AM   #5 (permalink)
Moderator
 
Hades's Avatar
 
Join Date: 01-23-07
Location: Buenos Aires, Argentina
Posts: 1,261
iTrader: 0 / 0%
Hades is a web professional of the highest orderHades is a web professional of the highest orderHades is a web professional of the highest orderHades is a web professional of the highest orderHades is a web professional of the highest orderHades is a web professional of the highest orderHades is a web professional of the highest orderHades is a web professional of the highest orderHades is a web professional of the highest orderHades is a web professional of the highest orderHades is a web professional of the highest order
Keep the .html extensions, you can use the example given by htmlbasictutor to do so.

Then you can include php code in your files and make the application access the database to retrieve the content.
__________________
Hades,
Ancient god, King of the Nether World, and Guardian of the Dead.
...and on my free time I'm also a web developer, contact me if you need one!
Hades is online now  
Add Post to del.icio.us
Reply With Quote
Old 09-20-2009, 09:39 AM   #6 (permalink)
Contributing Member
 
JennyRipley's Avatar
 
Join Date: 08-03-09
Posts: 406
iTrader: 0 / 0%
Latest Blog:
None

JennyRipley is liked by many
Quote:
Originally Posted by Zippey View Post
If I convert my HTML to files with php file extensions I will loose all my incomming links. Correct?
Yes,if you covert your HTML to files with php file extensions you will
loose all your incoming links.
__________________
HostEase Web Hosting
Only $0.01 for the first month with coupon code TEST
24/7/365 Email | Livechat | Tel support
JennyRipley is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-21-2009, 12:08 AM   #7 (permalink)
Super Moderator
 
htmlbasictutor's Avatar
 
Join Date: 10-29-07
Location: British Columbia, Canada
Posts: 3,301
iTrader: 0 / 0%
Latest Blog:
Website Testing

htmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web prohtmlbasictutor is a highly respected web pro
Quote:
Originally Posted by JennyRipley View Post
Yes,if you covert your HTML to files with php file extensions you will
loose all your incoming links.
Quote:
Originally Posted by thegetpr View Post
if you change pages HTML to php loss search engines index pages.
Ahh, but you don't have to. Read my post above.
__________________
HTML Basic Tutor - Learn to code your web pages/blogs
Basic Computer Information - Computer Basics for website owners

Trouble getting indexed? Maybe it's something techincal - Pm me.
htmlbasictutor is online now  
Add Post to del.icio.us
Reply With Quote
Old 09-20-2009, 01:31 PM   #8 (permalink)
Contributing Member
 
Join Date: 06-12-09
Location: INDIA
Posts: 226
iTrader: 0 / 0%
thegetpr is liked by many
Send a message via Yahoo to thegetpr Send a message via Skype™ to thegetpr
if you change pages HTML to php loss search engines index pages.
__________________
Pagerank tool

thegetpr is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-21-2009, 01:01 PM   #9 (permalink)
Moderator
 
Join Date: 02-10-07
Location: Central Kentucky
Posts: 1,293
iTrader: 2 / 100%
Latest Blog:
None

ScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest order
Zippy,

Take note that the syntax can vary slightly depending on the flavor of Linux/Apache running. Your document declartions might affect that also. I am not really sure.Test it with a sample page that has some php includes on it before you change all your pages.
__________________
These forums are as good as the posts that you contribute to them.
~~
ScriptMan
Webmaster Help Articles
Domains & Sites For Sale by Owner
ScriptMan is online now  
Add Post to del.icio.us
Reply With Quote
Go Back   Webmaster Forum > Web Development > Coding Forum

Reply

Tags
php


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Forum SEO - Dynamic or static pages? dWhite SEO Forum 12 01-15-2009 03:53 AM
help need for converting xml to php vetrib2w Coding Forum 0 08-07-2008 05:54 AM
Generating static HTML pages for my phpLD vistadivine.com Web Directory Issues 8 11-02-2006 09:52 AM
Converting .swf to .jpg? Jason Web Design Lobby 6 05-12-2005 03:36 PM
Is having an archiver phpbb and static pages (html) SPAM? crazyhorse Google Forum 0 08-18-2004 10:23 AM


Sponsor Links
Get exposure! Contextual Links V7N SEO Blog V7N Directory


All times are GMT -7. The time now is 07:13 PM.
© Copyright 2008 V7 Inc
Powered by vBulletin
Copyright © 2000-2009 Jelsoft Enterprises Limited.


Search Engine Optimization by vBSEO 3.3.0 ©2009, Crawlability, Inc.