Jumping from an HTML web page to a php page - Webmaster Forums - Webmaster forum for HTML, PHP, ASP, CSS and more
Webmaster Forums - Webmaster forum for HTML, PHP, ASP, CSS and more
Go Back   Webmaster Forums - Webmaster forum for HTML, PHP, ASP, CSS and more > Webmaster Tech > Programming > PHP Development

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old 05-31-2011, 04:02 AM   #1 (permalink)
Junior Member
 
Join Date: May 2011
Posts: 3
Default Jumping from an HTML web page to a php page

Hi, i'm new in php. I'm building a website for my project. My prof wants us to combine php and html. .i've created the web page and it's working fine. .but when i'm about to make a link from my html page to my php page something went wrong. .although it's jumping to the php page,but this was what happened:

Thanks for registering! "; } //The web form for input ability else { echo " \n"; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; //echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo "" ; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; //echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo " \n"; } // EOF ?>
Username: \n
Password: \n
First Name:
\n
Middle Name:
\n
Last Name:
\n
Nick Name:
\n
Gender:

all my php codings showed up on the page. the page should be neat. my php file is located on my c drive on wamp folder. then my html file are located on the d: drive. .

another help, if my php file is not in my wamp folder, let say its on another folder, how can i access it?. .

please help me, and be patient on this one . .thanks so much
polaric is offline   Reply With Quote
Sponsored Links
Old 06-29-2011, 11:23 AM   #2 (permalink)
Junior Member
 
Join Date: Jun 2011
Posts: 8
Default Re: Jumping from an HTML web page to a php page

Unless you're running the php code as a discrete application to be called at some point from within the .html it's going to be difficult to mix the two.

It's better to write the php into the .html file. In this case you would run php code enclosed in <?php [some php code] ; ?>.

The other option is to write html into a .php file, however, any html code has to be outside of the <?php [some php code] ; ?> tags.

You'er other issue could be that there's a directive within your .htaccess file preventing php code execution from within .htm(l) files.
CPUSmith is offline   Reply With Quote
Old 06-29-2011, 05:39 PM   #3 (permalink)
Junior Member
 
Join Date: May 2011
Posts: 23
Default Re: Jumping from an HTML web page to a php page

Put all of the html code within a php script:

<? echo "HTML CODE HERE"; ?>

You can see how I did it on Search Engine Optimization Services :: Online Marketing :: CFSEO.net

It's reliable and pretty easy to use, but it does have a couple issues that can come up, especially when you are switching back and forth a lot between HTML and PHP.

Are you sure there is no way for you to do this without HTML?
thetermy is offline   Reply With Quote
Old 07-05-2011, 04:51 AM   #4 (permalink)
Junior Member
 
Join Date: Jun 2011
Posts: 18
Default Re: Jumping from an HTML web page to a php page

yeah ,I think so!
hongshi is offline   Reply With Quote
Old 07-09-2011, 11:22 AM   #5 (permalink)
Junior Member
 
Join Date: Jun 2011
Location: Indonesia
Posts: 10
Send a message via Yahoo to bli_wedhooz Send a message via Skype™ to bli_wedhooz
Default Re: Jumping from an HTML web page to a php page

after you jump to php page then get the data using global _GET
bli_wedhooz is offline   Reply With Quote
Old 07-11-2011, 08:49 AM   #6 (permalink)
Junior Member
 
Join Date: Mar 2011
Posts: 61
Default Re: Jumping from an HTML web page to a php page

you may get help from w3schools.com
john9988 is offline   Reply With Quote
Old 07-14-2011, 07:29 AM   #7 (permalink)
Regular User
 
CyberSEO.net's Avatar
 
Join Date: Jul 2011
Posts: 20
Default Re: Jumping from an HTML web page to a php page

Quote:
Originally Posted by polaric View Post
Hi, i'm new in php. I'm building a website for my project. My prof wants us to combine php and html. .i've created the web page and it's working fine. .but when i'm about to make a link from my html page to my php page something went wrong. .although it's jumping to the php page,but this was what happened:

Thanks for registering! "; } //The web form for input ability else { echo " \n"; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; //echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo "" ; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; //echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo " \n"; } // EOF ?>
Username: \n
Password: \n
First Name:
\n
Middle Name:
\n
Last Name:
\n
Nick Name:
\n
Gender:

all my php codings showed up on the page. the page should be neat. my php file is located on my c drive on wamp folder. then my html file are located on the d: drive. .

another help, if my php file is not in my wamp folder, let say its on another folder, how can i access it?. .

please help me, and be patient on this one . .thanks so much
How exactly do you jump from your HTML page to the PHP one? Is it by hyperlink or it's an auto-redirect via JavaScript?
CyberSEO.net is offline   Reply With Quote
Old 07-15-2011, 05:28 AM   #8 (permalink)
Regular User
 
sannu123's Avatar
 
Join Date: Dec 2010
Posts: 27
Default Re: Jumping from an HTML web page to a php page

Hi.....According to me these are useful and helpful information in this site...Thanks for share with us....Thanks a lot


regards...

sannu
sannu123 is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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



» Sponsors

» Links

» Affiliates
Web Hosting
Online Backup Reviews
Marketing Find
Merchant Select
SiteMap Builder
Host Compare

» Links

» Sports Network
Paintball Forum
Football Forum
Hockey Forum
Golf Forum
Boxing Forum
Lacrosse Forum
Baseball Forum
SnowBoarding Forum
Soccer Forum
MMA Forum


All times are GMT -4. The time now is 04:48 PM.


Powered by vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.2
Webmaster Forums
Web Hosting | Chicago Web Hosting | Web Hosting