Inserting an html file into a div

I have an html file that includes jQuery script, CSS and image links (a rotating banner). I need to insert it into the wrapper template on the front of my site.
Currently there is a rollover image where I need the banner to go;
<!-- InstanceBeginEditable name="content" --><link rel="shortcut icon" href="favicon.ico" >
<!--  start banner  -->
<div id="promotional" padding="0"><a href="../programming/legislature.html" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('cornerlegis','','../images/legis3hover.jpg',0)"><img src="../images/corner_legis3.jpg" name="cornerlegis" width="220" height="157" border="0" id="cornerlegis" /></a>
<!-- end banner  -->
<div id="newsfeature">
This banner and it's  jQuery scripts are located in the root folder of the site.
How can I get the banner ito this div location? I'm using Dreamweaver CS4.
Thanks for your help.

we210 wrote:
I have an html file that includes jQuery script, CSS and image links (a rotating banner). I need to insert it into the wrapper template on the front of my site.
Currently there is a rollover image where I need the banner to go;
<!-- InstanceBeginEditable name="content" --><link rel="shortcut icon" href="favicon.ico" >
<!--  start banner  -->
<div id="promotional" padding="0"><a href="../programming/legislature.html" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('cornerlegis','','../images/legis3hover.jpg',0)"><img src="../images/corner_legis3.jpg" name="cornerlegis" width="220" height="157" border="0" id="cornerlegis" /></a>
<!-- end banner  -->
<div id="newsfeature">
This banner and it's  jQuery scripts are located in the root folder of the site.
How can I get the banner ito this div location? I'm using Dreamweaver CS4.
Thanks for your help.
Use an include file?
Create a new file and save it as banner.ssi
Insert all the code related only to the banner into the banner.ssi (it should contain nothing else, no <body>, meta, <title> tags etc.
Change the extention to the file name of the page into which you want the banner to be include to .shtml
So for instance if I want the banner to appear in a file called 'aboutus; instead of 'aboutus.html' it would become 'aboutus.shtml'
In the .shtml page place the below code between the <div></div> tags in which you want the banner to appear.
<div id="promotional">
<!--#include virtual="banner.ssi"-->
</div>
Finally link the jquery scripts to the .shtml page NOT the banner.ssi file.
The include should show in Design View and Live View in the Dreamweaver environment.
Alternatively if you know a little bit about php you can use that:
<div id="promotional">
<?php include("banner.php"); ?>
</div>

Similar Messages

  • Can I insert an html file as an image into an HTML page?

    The site I'm working on (www.ngospen.com) has PNGs for background art - 10 - 15 kb per image. As the site is intended for settings with low bandwidth, I'd like these background images to be as small as possible.
    When saving for the web, one of the options is Save As HTML file. When I open the file, the artwork appears the same as the PNG (no lost resolution), but it is a much smaller file size (1 - 2 KB).
    Is it possible to insert these HTML files into my HTML pages?
    Thanks!
    Ken D
    Creative Director
    Grateful Creative

    Are you meaning that you work with fireworks?
    If so the html and the images you export are flattened images (slices), you have to put those images directly into your html page.
    If you want to save the file (fireworks) as a flattened image you could also goto save as -> flattened png.
    If you save your image from fireworks just as png it contains the layer information etc. etc. from fireworks, that's why you should save them as flattened png, or just export the slices.
    http://www.dreamweaverfan.nl

  • How to load an exteranl html file in a div

    All-
    Im sure this has been covered but I can't find what I'm looking for.
    How do I load content from an external html file into a div in Edge?
    I want my client to have the option of updating the html files so i don't have to edit them in edge
    The files are inside of a folder called "content"and the index.html file is outside of this folder.
    Thanks

    I tried this and it works. Thanks.
    How can I control the EA timeline with the loaded HTML? I would like to animate the "webPageDisplayPort" div on stage when a user click a button or image inside the loaded HTML.
    HTML code:
    <div class="image" onClick="comp.play();"></div>

  • Can I insert the image file into PDF file  in Adobe X Standard ?

    can I insert the image file into PDF file in Adobe X Standard ?

    http://matt.coneybeare.me/how-to-make-an-html-signature-in-apple-mail-for-maveri cks-os-x-10-dot-9/

  • Insert one html page into another html page

    Hi there,
    I wonder if sombody can help. I am trying to insert one short
    html page into another page. I could not find any option or feature
    in Dreamweaver that allow me to insert the page at all. The page I
    want to insert has the links and it is a short page, just like a
    banner. When I update the links on that page it will update all
    other pages in the website. I do not have to open many pages to
    update. I have been using FrontPage and I am now converting to
    Dreamweaver. Some codes from FrontPage does not work in
    Dreamweaver. I would very much appreciate if somebody can help with
    the codes.
    This is my website so that you can understand what I mean. At
    the top of the screen there are many links that are from one page I
    inserted into index.html. I use FrontPage. But, Dearmweaver does
    not work that way.
    Thank you. Kevin

    Be aware that IFrames carry all the disadvantages that frames
    do, for both
    you and your client's visitors.
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    http://www.projectseven.com/go
    - DW FAQs, Tutorials & Resources
    http://www.dwfaq.com - DW FAQs,
    Tutorials & Resources
    ==================
    "polarl light" <[email protected]> wrote in message
    news:g06ad0$2rm$[email protected]..
    >
    >> I wonder if sombody can help. I am trying to insert
    one short html page
    >> into
    >> another page. I could not find any option or feature
    in Dreamweaver that
    >> allow
    >> me to insert the page at all. The page I want to
    insert has the links
    >> and it
    >> is a short page, just like a banner. When I update
    the links on that
    >> page it
    >> will update all other pages in the website. I do not
    have to open many
    >> pages
    >> to update. I have been using FrontPage and I am now
    converting to
    >> Dreamweaver.
    >> Some codes from FrontPage does not work in
    Dreamweaver. I would very
    >> much
    >> appreciate if somebody can help with the codes.
    >
    > Depending on what you want to do you can use SSIs or an
    Iframe. SSIs are
    > good for things such as headers, menus and nav bars that
    you want to stay
    > the same across a range of pages. Iframes let you load
    an external HTML
    > file into a predefined area of your page so you can
    display different
    > content while staying on the same page.
    >

  • How to insert a image file into oracle database

    hi all
    can anyone guide me how to insert a image file into oracle database now
    i have created table using
    create table imagestore(image blob);
    but when inserting i totally lost don't know what to do how to write query to insert image file

    Hi I don't have time to explain really, I did have to do this a while ago though so I will post a code snippet. This is using the commons file upload framework.
    Firstly you need a multi part form data (if you are using a web page). If you are not using a web page ignore this bit.
    out.println("<form name=\"imgFrm\" method=\"post\" enctype=\"multipart/form-data\" action=\"FileUploadServlet?thisPageAction=reloaded\" onSubmit=\"return submitForm();\"><input type=\"FILE\" name=\"imgSource\" size='60' class='smalltext' onKeyPress='return stopUserInput();' onKeyUp='stopUserInput();' onKeyDown='stopUserInput();' onMouseDown='noMouseDown(event);'>");
    out.println("   <input type='submit' name='submit' value='Submit' class='smalltext'>");
    out.println("</form>"); Import this once you have the jar file:
    import org.apache.commons.fileupload.*;Now a method I wrote to upload the file. I am not saying that this is correct, or its the best way to do this. I am just saying it works for me.
    private boolean uploadFile(HttpServletRequest request, HttpSession session) throws Exception {
            boolean result = true;
            String fileName = null;
            byte fileData[] = null;
            String fileUploadError = null;
            String imageType = "";
            String error = "";
            DiskFileUpload fb = new DiskFileUpload();
            List fileItems = fb.parseRequest(request);
            Iterator it = fileItems.iterator();
            while(it.hasNext()){
                FileItem fileItem = (FileItem)it.next();
                if (!fileItem.isFormField()) {
                    fileName = fileItem.getName();
                    fileData = fileItem.get();
                    // Get the imageType from the filename extension
                    if (fileName != null) {
                        int dotPos = fileName.indexOf('.');
                        if (dotPos >= 0 && dotPos != fileName.length()-1) {
                            imageType = fileName.substring(dotPos+1).toLowerCase();
                            if (imageType.equals("jpg")) {
                                imageType = "jpeg";
            String filePath = request.getParameter("FILE_PATH");
            session.setAttribute("filePath", filePath);
            session.setAttribute("fileData", fileData);
            session.setAttribute("fileName", fileName);
            session.setAttribute("imageType", imageType);
            return result;  
         } And now finally the method to actually write the file to the database:
    private int writeImageFile(byte[] fileData, String fileName, String imageType, String mode, Integer signatureIDIn, HttpServletRequest request) throws Exception {
            //If the previous code found a file that can be uploaded then
            //save it into the database via a pstmt
            String sql = "";
            UtilDBquery udbq = getUser(request).connectToDatabase();
            Connection con = null;
            int signatureID = 0;
            PreparedStatement pstmt = null;
            try {
                udbq.setUsePreparedStatements(true);
                con = udbq.getPooledConnection();
                con.setAutoCommit(false);
                if((!mode.equals("U")) || (mode.equals("U") && signatureIDIn == 0)) {
                    sql = "SELECT SEQ_SIGNATURE_ID.nextval FROM DUAL";
                    pstmt = con.prepareStatement(sql);
                    ResultSet rs = pstmt.executeQuery();
                    while(rs.next()) {
                       signatureID = rs.getInt(1);
                    if (fileName != null && imageType != null) {
                        sql = "INSERT INTO T_SIGNATURE (SIGNATURE_ID, SIGNATURE) values (?,?)";
                        InputStream is2 = new ByteArrayInputStream(fileData);
                        pstmt = con.prepareStatement(sql);
                        pstmt.setInt(1, signatureID);
                        pstmt.setBinaryStream(2, is2, (int)(fileData.length));
                        pstmt.executeUpdate();
                        pstmt.close();
                        con.commit();
                        con = null;
                if(mode.equals("U") && signatureIDIn != 0) {
                    signatureID = signatureIDIn.intValue();
                    if (fileName != null && imageType != null) {
                        sql = "UPDATE T_SIGNATURE SET SIGNATURE = ? WHERE SIGNATURE_ID = ?";
                        InputStream is2 = new ByteArrayInputStream(fileData);
                        pstmt = con.prepareStatement(sql);
                        pstmt.setBinaryStream(1, is2, (int)(fileData.length));
                        pstmt.setInt(2, signatureID);
                        pstmt.executeUpdate();
                        pstmt.close();
                        con.commit();
                        con = null;
            } catch (Exception e) {
                con = null;
                throw new Exception(e.toString());
            return signatureID;
       }

  • Drag and drop of html-files into Firefox 3.0.1 no longer works after going from XP to Win7

    I use firefox portable 3.0.1 on an external disk.
    Used to have a portable PC with XP SP2, now have a new Windows7 Professional machine.
    On the XP machine I was able to open Firefox from the USB disk and drag&drop html-files into its window to open them. Suddenly on Windows7 this no longer works?? Any ideas/fixes?
    Note: I do have to start the portable Firefox in XP SP2 compatibility mode, after which it seems to work fine (apart from this issue thus far)
    A lot of configuration went in this Firefox portable install, so it would be nice to get this to work with a quick fix instead of having to start from scratch with a newer version.

    -
    It, .. or they, don't within either browser that I have installed - and am using, ..
    .. they had previously, ... don't know what I did exactly to caused this circumstance.
    .. is my question. (.. if not fully clear.)
    Just looking to try to find out what I can do, either whether to "back-off" from what I've done - more recently, regarding the two different downloads that I've pointed to above, .. apparently - only, having, superseded a more simply configuration .. previously working.
    This, or either, adjust the settings - broader / somewhere (more generally) - otherwise, .. in order to have these files, play, .. in browser.
    Rm(richard583)

  • How to convert a HTML files into a text file using Java

    Hi guys...!
    I was wondering if there is a way to convert a HTML file into a text file using java programing language. Likewise I would also like to know if there is a way to convert any type of file (excel, power point, and word) into text using java.
    By the way, I really appreciated the help that you guys gave me on my previous topic on how to extract tests from a pdf file.
    Thank you....

    HTML files are already text files. What do you mean you want to convert them?
    I think if you search the web, you can find things for converting those MS Office files to text (or extracting text from them, as I assume you mean).

  • Inserting flash .swf file into template

    I want to insert a flash file into the right sidebar to appear on all pages of the website.  I know I need to do this via the template.  I think I need to click in the insertion point, then copy the code (make sure the files are in the correct location).   I've done this before with galleries ect..  but not in DW and not from a template.  What's a little confusing is there are 3 templates.  The first is in it's own folder (design template), the other two (theme 01 design & theme 01 design from template) are in the root folder, but the theme 01 design one doesn't seem to be changeale.  Which template should I be working with?
    www.wranglergirl.net
    Thanks from a newbie!  Amy

    Are each of these 'templates' actually DW templates (i.e., are they named with a *.dwt extension)?  If so, then they must all be located within the Templates folder at the root level of the site - it doesn't sound like that is the case.  Also, why do you need three templates?  Finally, which version of DW are you using?  It's likely that you will have to make any links to your Flash element with ROOT relative links to be successful.

  • How to put html file into a canevas?

    How to put html file into a canevas?

    Hi,
    would require you to write a JavaBean that interprets the HTML (there are commercial versions of this available)
    Frank

  • How to insert a JPG file into a Table from a Form?

    I create a Schema and a Table as follows:
    SQL> create user myphoto identified by myphoto;
    User created.
    SQL> grant connect,resource to myphoto;
    Grant succeeded.
    SQL> create table myphoto.photo_table
    2 (photo_id varchar2(10) primary key,
    3 photo_content blob);
    Table created.
    I would like to build an Oracle Form with a Text Item to enter the full path and filename to be uploaded and inserted into the photo_table; and a Push Button to insert the jpg file into the photo_table.
    Can any one give me details on how this could be done?

    Hi,
    have a look at webutil on otn.oracle.com/products/forms ---> Webutil
    Webutil has the capability to load files into the database.
    Frank

  • How to insert a gif file into a table?

    Hi,
    I need to insert a gif file into a table. Can anyone tell me where I can find the information on how to create this kind of table, how to insert a gif file into a table and how to select?
    Thanks,
    Helen

    Hi Helen,
    You could read about that in the documentation which is available online.
    For a starter: BLOB. And I bet there are many examples to be found on the web.
    Good luck. :)
    Regards,
    Guido

  • How can I insert a completed file into another PDF file I am developing?

    How can I insert a completed file into another PDF file I am developing?

    Please refer : http://acrobatusers.com/tutorials/how-to-insert-a-pdf-into-a-pdf

  • Converting html file into zip file and send email attaching zip file

    Hi Experts,
    I am trying to send email with attachment(html). Which contains more than 7MB. So, It is throwing an error like Size exceeded.
    So, Now i need to compress the data for less than 7MB.
    I decided to convert HTML File into ZIP File.
    Kindly suggest me to convert the HTML file into ZIP file and sending email with attached ZIP file.
    Correct answer rewarded,
    Thanks & Regards,
    N. HARISH KUMAR

    Hi Experts,
    *// HTML_TAB converting into ZIP File
       DATA  : zip_tool TYPE REF TO cl_abap_zip,
               filename TYPE string ,
               filename_zip TYPE string .
       DATA  : t_data_tab TYPE TABLE OF x255,
               bin_size TYPE i,
               buffer_x TYPE xstring,
               buffer_zip TYPE xstring.
    filename = text-007.                                                                          "'HTML_TAB
    *describe the attachment
       DESCRIBE TABLE html_tab LINES tab_lines.
       bin_size = tab_lines * 255.
       CALL FUNCTION 'SCMS_BINARY_TO_XSTRING'
         EXPORTING
           input_length = bin_size
         IMPORTING
           buffer       = buffer_x
         TABLES
           binary_tab   = html_tab.
       IF sy-subrc <> 0.
    *     message id sy-msgid type sy-msgty number sy-msgno
    *     with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
       ENDIF.
    *create zip tool
       CREATE OBJECT zip_tool.
    *add binary file
       CALL METHOD zip_tool->add
         EXPORTING
           name    = 'FSSAI_MAIL.HTML'
           content = buffer_x.
    *get binary ZIP file
       CALL METHOD zip_tool->save
         RECEIVING
           zip = buffer_zip.
       CLEAR: t_data_tab[],bin_size.
       CALL FUNCTION 'SCMS_XSTRING_TO_BINARY'
         EXPORTING
           buffer        = buffer_zip
         IMPORTING
           output_length = bin_size
         TABLES
           binary_tab    = html_tab.
    Thanks & Regards,
    N. HARISH KUMAR

  • HT3529 How do I insert a pdf file into my message?

    How do I insert a pdf file into my message? please help!

    thank you James! I suspected that this could be the solution, but i am new to iPads and it is a pain to find a file on iPad in order to do this operation, in windows there is windows explorer and i cannot see anything like that on iPad.. any hints would be appreciated!

Maybe you are looking for