Web Developer's Virtual Library: Encyclopedia of Web Design Tutorials, Articles and Discussions


WDVL Newsletter

Active Server Pages
JSP/Java Servlets
Microsoft SQL Server
Daily Backup
Dedicated Servers
Streaming Audio/Video
24-hour Support    

jobs.webdeveloper.com

Hiermenus


e-commerce
Partner With Us















Developer Channel
FlashKit.com
JavaScript.com
JavaScriptSource
Developer Jobs
ScriptSearch
StreamingMediaWorld
Web Developer's Journal
Web Developer's Virtual Library
WebDeveloper.com
Webreference
Web Hosts
XMLfiles.com

internet.com
IT
Developer
Internet News
Small Business
Personal Technology

Search internet.com
Advertise
Corporate Info
Newsletters
Tech Jobs
E-mail Offers


Importing an external file into an HTML File

Is there a way to import a section of HTML/JS/CSS code (not fully marked up HTML file) at a given point in an HTML file? In otherwords, same function as external .js file, but for a section only of HTML/JS/CSS code?

Try this:

<!-- #include "myfile.inc" -->

In the include file just put all the css or whatever you want. You can try a different extension for the file, but try inc first as it is pretty standard. And be sure that the file is made executable, either by "chomd'ing" it to 755, or by setting the directory up within the Web server admin console (if you're using a Windows-based Web server).



Up to => Home / WDVL / Forum




Jupiter Online Media: internet.comearthweb.comDevx.commediabistro.comGraphics.com

Search:

Jupitermedia Corporation has two divisions: Jupiterimages and Jupiter Online Media

Jupitermedia Corporate Info


Legal Notices, Licensing, & Permissions, Privacy Policy.

Web Hosting | Newsletters | Tech Jobs | Shopping | E-mail Offers