• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Getting duplicate tags

New Here ,
Aug 15, 2006 Aug 15, 2006

Copy link to clipboard

Copied

Hello, we are just about to laucnh a new website. I am the customer. My developer is using Cold Fusion and creating many of the pages dynamically. Unfortunately, I just noticed that all of the pages have duplciate tags because they are pulling from several different .cfm files. Oneis called, application.cfm. One is called audio.cfm. And then there's the actual page, index.cfm, home.cfm etc. Right now, the code looks bad. Take a look at some of these pages: http://www.thevoiceforgod.com/ or http://www.thevoiceforgod.com/home.cfm

There are duplicate html tags, title tags, body tags, everyting is duplicate becuaes the application.cfm file and the actual index.cfm or home.cfm files have all of those tags too. So, when they get combined, there's double trouble.

What can we do about this? Don't the application or the audio.cfm files hae to have these tags too? or don't the index and home.cfm pages have to have these basic tags too?

I want to laucnh the site now, but I want to resolve this first so search engine spidres don't freak out.

Thank y ou.
TOPICS
Advanced techniques

Views

491

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Aug 16, 2006 Aug 16, 2006

Copy link to clipboard

Copied

My first advice would be to avoid having any HTML in Application.cfm.

Find another common place to store that HTML and include it from within the file itself.

For example, a common method is to have a header.cfm and a footer.cfm that have the header and footer HTML, respectively. You can then include those files at the top of the page. It may seem tempting to include these files from Application.cfm, but don't do so. It will cause you headaches later.

Including header and footer files is the most common method for this.

I also like using what I call layout components (full disclosure, I wrote this article):
Layout Components

Hope that helps.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Aug 16, 2006 Aug 16, 2006

Copy link to clipboard

Copied

Thank you. My developer at some point may be able to figure this out. It sounds complicated. Is there a really simpler, easier solution? Something that even I could do to the pages?

Thank you.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Aug 16, 2006 Aug 16, 2006

Copy link to clipboard

Copied

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Aug 16, 2006 Aug 16, 2006

Copy link to clipboard

Copied

Thanks. I just ended up cutting the title, html, and body tags, and ended up with this and it all seems to work ok. Thank you.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Aug 18, 2006 Aug 18, 2006

Copy link to clipboard

Copied

Cutting off the HTML tags is another way of saying that the doctype of the Application file is not html. So, why not go all the way?

<cfset DSN="voiceforgod">
<cfset Datatype="ODBC">



Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Aug 18, 2006 Aug 18, 2006

Copy link to clipboard

Copied

Sorry. I am just technical enough to be dangerous. What do you mean by go all the way? Can you be more specific and exact so I can follow your advice?

Thanks.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Aug 19, 2006 Aug 19, 2006

Copy link to clipboard

Copied

LATEST
what BKBK tries to explain is that now you dont have any HTML code inside your application.cfm file. The doctype of this file is not html, so the following code is not needed in your application.cfm file:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

As you deleted all HTML code from your applicacion.cfm file, there is no need for this.

It seems that the only code you need in your application.cfm file is the variables assignment.

I hope this helps.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation