Click to See Complete Forum and Search --> : Need Help With Label Inserting into HTML
cozforus
06-29-2008, 09:02 AM
I need to automatically display the name,
phone and email address of a contact,
located on a text or html file, into five
html pages so that I don't have to type
the data on each individual page. Similar
to merging data from a list into a Word
Document.
Financial discussions not permitted
Thanks. Steve
blakeelias
06-29-2008, 12:06 PM
You could use an iframe to embed the page:
<iframe src="page_with_info.html" />
I would also recommend the border="0" attribute so you don't get an ugly black border around it.
Another possible method if your server supports PHP (many do) is to put the following where you want the info to show:
<?php include("page_with_info.php"); ?>
If you use the PHP method, you should also change the extension of the page it's on to .php to be safe.
kiwibrit
06-29-2008, 04:45 PM
.......If you use the PHP method, you should also change the extension of the page it's on to .php to be safe.
Not necessarily, with .htaccess (http://www.besthostratings.com/articles/php-in-html-files.html)
blakeelias
06-29-2008, 05:25 PM
@cozforus:
Yeah, good point.
You can use that PHP if your server supports, and use the suggestion of cozforus to make the server parse your .html as PHP.
You might also be able to use SSI (server side includes) if your server supports.
http://httpd.apache.org/docs/1.3/howto/ssi.html
It will look like this:
<!--#include virtual="path/to/page.html" -->
And you may have to configure your .htaccess or httpd.conf file to make it work...good luck.
cozforus
06-30-2008, 10:49 AM
Hi Blake:
Thanks for your reply to my post. I appreciate your time in answering my question.
As I mentioned in my post, I am trying to put my name and phone number in one page and have that information automatically posted to either other pages.
This link will show you what the page looks like currently. Note: there is no line with my name and phone number in the header section.
http://www.surfdailyforcash.com/test/currently_income_page.htm
This link will show you what I wish the page to look like. Note: my name and phone number are indicated on one line in the header.
http://www.surfdailyforcash.com/test/goal_income_page.htm
My hosting company does not allow PHP files so I have to use html.
Based on the information that you posted, I created a name page. Click to see.
http://www.surfdailyforcash.com/test/name.html
Then, I added <iframe src="name.html"/> where I want my name to show.
Here is the result. Note: that the “Howard’s Proof of Income” line is gone and the header is been altered.
http://www.surfdailyforcash.com/test/result.htm
I have tried everything to fix this problem and can’t.
If you have any further suggestions or can fix this for me, I will gladly pay you for your time.
Thanks for your reply.
Steve
blakeelias
06-30-2008, 12:17 PM
Suggestion: Your code is not very efficient and furthermore, it does not validate: http://validator.w3.org/check?uri=http%3A%2F%2Fwww.surfdailyforcash.com%2Ftest%2Fcurrently_income_page.htm&charset=(detect+automatically)&doctype=Inline&group=0
I would recommend starting at the top of the list of errors and fixing them one by one. Sometimes one error can cause subsequent errors, so make sure to start at the TOP OF THE LIST. After fixing the errors, revalidate using validator.w3.org, and then put in the <iframe... /> code where you want it.
If you would like me to handle this project, please post your email address so we can discuss payment outside of the forum.
cozforus
07-01-2008, 01:01 PM
Suggestion: Your code is not very efficient and furthermore, it does not validate: http://validator.w3.org/check?uri=http%3A%2F%2Fwww.surfdailyforcash.com%2Ftest%2Fcurrently_income_page.htm&charset=(detect+automatically)&doctype=Inline&group=0
I would recommend starting at the top of the list of errors and fixing them one by one. Sometimes one error can cause subsequent errors, so make sure to start at the TOP OF THE LIST. After fixing the errors, revalidate using validator.w3.org, and then put in the <iframe... /> code where you want it.
If you would like me to handle this project, please post your email address so we can discuss payment outside of the forum.
blakeelias:
Thanks again for your reply.
My email address is steve.duval@yahoo.com.
I look forward to your response.
Thanks.
Steve