Jump to content

Problem including a template in php file


niza

Recommended Posts

I have a user registration area:
new_member.php - script that executes the registration
new_member.htm - contains the html registration form
template.htm - html template

If the user does not fill in all the required fields, new_member.htm is called in new_member.php, with the appropiate error message.

Now, I have problems including my template.htm file.

1.If I include it in the new_member.htm, whenever the user does not fill in the required fileds, the error message are displayed on top of the template.
2.If I include it in the new_member.php, the form is not displayed properly.

Any ideas?

By the way, the script for user registration I am using is this: [a href=\"http://www.phpfreaks.com/tutorials/40/0.php\" target=\"_blank\"]http://www.phpfreaks.com/tutorials/40/0.php[/a]
Link to comment
Share on other sites

[!--quoteo(post=367348:date=Apr 21 2006, 03:41 PM:name=niza)--][div class=\'quotetop\']QUOTE(niza @ Apr 21 2006, 03:41 PM) [snapback]367348[/snapback][/div][div class=\'quotemain\'][!--quotec--]
I have a user registration area:
new_member.php - script that executes the registration
new_member.htm - contains the html registration form
template.htm - html template

If the user does not fill in all the required fields, new_member.htm is called in new_member.php, with the appropiate error message.

Now, I have problems including my template.htm file.

1.If I include it in the new_member.htm, whenever the user does not fill in the required fileds, the error message are displayed on top of the template.
2.If I include it in the new_member.php, the form is not displayed properly.

Any ideas?

By the way, the script for user registration I am using is this: [a href=\"http://www.phpfreaks.com/tutorials/40/0.php\" target=\"_blank\"]http://www.phpfreaks.com/tutorials/40/0.php[/a]
[/quote]

I'm a bit confused as to what you're trying to do and why, and exactly what your problem is. Needless to say.. only PHP files will be parsed by the php interpreter server side. There is no way to include html files inside other html files without some server side language, so your description in that regards doesn't make much sense. Maybe it would help if you provided some source code.
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.