Best way to include javascript-script into different struts-pages

Hi,
I'm running a struts-based webapplication using the tiles-templates for my layout. Now I have to use some javascript-code for a pop-up window and another javascript for tracing on multiple pages but in different combinations. As I do n't want to copy-paste it on every page, but put it on a single place for better maintenance I'm wondering what would be the best way to do this together with the struts-logic.
I thought about the following options:
1.) Using the "template:put" feature like this:
<template:put name='js' content="/myJavascripts.jsp"> I don't think this would be a good option, as I always have to include the whole javascript and I cannot distinguish between my two different javascripts
2.) Using the template:insert feature like this:
<template:insert template="/myJavascripts.jsp"/>. This is a lot better, as I can split my two javascripts into two different files and can always decide, which one to include with the template:insert tag. But I'm not sure, if this is conforming with the struts-concept, as I do not use any template:put or template:set tags
3.) Using simple jsp:include or <%@ include ... %> tags.
This would be the easiest way to include my pages with <%@ include file='/myJavascripts.jsp' %>. Same advantages like template:insert but I don't need the additionally features of the template:insert-tag. But still the same question: is this the concept of struts? Or will I become any difficulties with this concept later??
Any recommendations or further ideas are greatly appriciated.
Thanx for your help
Thomas

Getting PDFs to download is fairly easy and the method is described here.....
http://www.iwebformusicians.com/WebMusic/PDFs.html
To get multi page docs to display in the browser requires the use of Google Docs viewer, ISSUU or some such thing....
http://www.iwebformusicians.com/PromoPage/ISSUU.html
Safari is the only browser I know of that will display PDFs in an iFrame without a plugin.

Similar Messages

  • What's the best way to include many files into a website?

    I have a several hundred documents that I would like to load onto my website. I'm trying to find a faster way than hyperlinking them all one by one. Right now they are in pdf format but that can change. I'm hoping for the end result to be one page (possibly with subpages) with the different links for the documents on them. The visitor doesn't necessarily need the ability to download them, just the ability to view them. Is there a faster way to bulk or batch load multiple files into a site? Thanks in advance.

    Getting PDFs to download is fairly easy and the method is described here.....
    http://www.iwebformusicians.com/WebMusic/PDFs.html
    To get multi page docs to display in the browser requires the use of Google Docs viewer, ISSUU or some such thing....
    http://www.iwebformusicians.com/PromoPage/ISSUU.html
    Safari is the only browser I know of that will display PDFs in an iFrame without a plugin.

  • Best way to include 1-800, 866, 877, 888 into Device/line approach to CSS

    I am running Call Mgr 4.1.3. Due to the number of small remote sites that we are expanding to, I have been using the Device/Line approach to Class of Service to minimize the number of CSSs and PTs. I used the textbook method of defining BlockLocal, BlockLD, BlockIntl, Block nothing. My LongDistance Translation Pattern is 9.1[2-9]XX[2-9]XXXXXX. This blocks 800, 866, 877, and 888 in my BlockLD partition. What is the best way to include these 8xx series toll free numbers into the Device/Line method so that they are included into the COS that allows local calling? My guess is that in the 9.1[2-9]XX[2-9]XXXXXX translation pattern assigned to the BlockLD partition, I would add 9.1800XXXXXXX, 9.1866XXXXXXX, etc, translations and click "route this pattern" and associate it also with the BlockLD partition.
    Is that the correct approach - or is there a better approach? Thank you.

    Thank you so much for the fast reply Preran. But for me the tricky part is to implement the html code from the sample page into actions within Edge and to those images I want to be affected.
    The html-code on the sample file is;
    <div id="cubeCarousel">
        <div id="cubeSpinner">
            <div class="face one">
                 <img class="img_slider active" src="img/black.jpg">
            </div>
            <div class="face two">
                <img class="img_slider" src="img/blue.jpg">
            </div>
            <div class="face three">
                <img class="img_slider" src="img/purple.jpg">
            </div>
            <div class="face four">
                <img class="img_slider" src="img/red.jpg">
            </div>
        </div>
            <div class="nav">
                <div class="left arrow"></div>
                <div class="right arrow"></div>
            </div>
    </div>
    What I don't understand is how write this code in Adobe Edge so the jQuery scripts connect to images in my Edge composition.
    Is there any guidelines for the syntax and how I should write these lines in Edge, or any tutorial that show this? Or do you have anu code example that I can use as "dummy"?
    BR
    /Bengt

  • What's he best way to include Adobe PDFs on my blog?

    What's he best way to include Adobe PDFs on my blog?
    I create worksheets as a teacher and would like to share them from my blog. Currently I am linking to Scribd etc to share PDFs. If I upload the worksheets as an image is there a way to adjust the size/resolution of the PDF for easier viewing? 
    Thanks!

    PDFs are just files. Can you upload files to your blog space? If yes, just upload the PDFs then, in a blog entry, provide the web link (URL) for each file (PDF).
    Or, place the PDFs into your free acrobat.com "files" storage (5GB free). You have one as you have an Adobe ID (needed to make your post here eh).
    https://cloud.acrobat.com/
    You can have acrobat.com provide a "share" link to the PDF. Place that into a blog entry.
    Or - same idea as above (use a "file share" service) -- Microsoft's OneDrive, Adobe's Creative Cloud, Google drive, DropBox, others ...
    Be well...

  • What is the best way to insert massive data into an existing excel file?

    dear gurus,
    i am wondering that what is the best way to insert massive data into an existing excel file, more performance perspective.
    the file is read from BDS , and we want to insert data into it .
    the way i can think of is
    1. OLE AUTOMATION
       i think performance will be a big problem
    2. Office integration
        i am not sure it's facing the same performance issue ?
    3 . XXL_SIMPLE_API/FULL_API
        I am not sure whether they can insert data into an existing excel file?
    could you please give me some advices?
    br.
    jun

    Hi,
    If you want to APPEND data( add data to an existing excel file) from SAP, then use GUI_DOWNLOAD fm with APPEND = 'X' paramter.
    Best regards,
    Prashant

  • What is the best way to turn line art into a 3D image in Illustrator? Thanks for your help.

    What is the best way to turn line art into a 3D image in Illustrator? Thanks for your help.

    What version of Illustrator? What do you mean by "Line Art"? What do you mean by "3d image"? Post images showing your starting artwork and an example of what you are trying to achieve.
    If you have Illustrator 12 or higher you can extrude or lathe a simple group or path using Effects > 3D > [Pick one]. You must start with vector data, not a placed raster image. You are very limited in what you can do, and you cannot model multiple objects within one 3D world. Each object you extrude/revolve/rotate is its own world, with its own perspective and camera. You can also make any art into a Symbol, then map that symbol onto any 3D surface you create. The results are, at best, acceptable, and often total garbage.

  • What is the best way to include an xml file in JSP?

    I have a jsp page that I need to include an xml file. The xml file
              uses an xsl to render the file. What is the best way to include the
              xml file and still maintain the structure of the style sheet?
              Thanks
              Jennifer
              

              The best way is using the tag lib. If you cannot, but you can use JAXP, you can
              try
              javax.xml.transform.Transformer.transform(Source xmlSource,
              Result outputTarget)
              throws TransformerException
              You construct the transformer with you xsl, use you xml file or DOM to form xmlSource,
              and use JSPWriter "out" to form outputTarget (StreamResult). But if your JSP page
              generates the xml itself, tag lib is the only way.
              [email protected] (Jennifer) wrote:
              >[email protected] (Jennifer) wrote in message news:<[email protected]>...
              >> I have a jsp page that I need to include an xml file. The xml file
              >> uses an xsl to render the file. What is the best way to include the
              >> xml file and still maintain the structure of the style sheet?
              >>
              >> Thanks
              >>
              >> Jennifer
              >
              >Or is there a way to parse the xml file with the jsp page to display
              >the information. I cannot use the Java Standard Tag Libraries as the
              >version of iplanet we are running does not support the JSTL
              >
              >Thanks
              >
              >Jennifer
              

  • Best way to build a website with hundreds of pages

    What is the best way to build a website with hundreds of pages that include businesses in every city of the U.S. I will be building it in Dreamweaver CS4 and pulling the data from an MS Excel spreadsheet.
    I started building it by building the first page and then saving a new page with new data and so on.
    There must be a way to pull from the Excel doc without copying and pasting each page of data, and there must be a way to build this site smaller and easier to make changes when needed.
    Thanks

    You already have other people addressing the DB issues - so I will bring up the other... You are just saving a copy as a new page and then copy and pasting the changed content into  it?
    What you want to do is take the first page, once you have your design done - and save it as a template (file - save as - Dreamweaver Template).
    Then you want to select the areas (most likely the divs you have content in) that will have content changed, and select the div or p or whatever element... and go to Insert - Template Objects - Editible Region.
    Make sure you don't made editable the areas that are the primary design - such as a logo element, a header image, the navigation etc.  If you want to change those - you would do so by making the change on the template, and then it will automatically update all pages made based on that template.
    Once you are done setting up the templates - go to your new page and choose Modify - Templates - Apply Template To Page
    Select the template you just created (note it will be placed inside of a new folder titled "templates" automatically by Dreamweaver).
    Now, any of the areas you selected to add different content into will be selectable, and you can copy/paste or however you are doing so.
    Good luck

  • What is the best way to create the layout for a single page website in Adobe Muse?

    I was wondering the best way to create the layout for a single page website in Adobe Muse. Does anyone have any suggestions?

    I know how to create a website but will that help me create a single page website? Below I will leave a demo of what I want. I want it to only have one page but multiple sections. What is the easiest way to create a single page website like the demo below?
    Demo Website

  • Best way to publish Edge files into html page?

    Ok,
    So im looking for the best way to add my edge files into my html page.
    I want to make it easy to integrate edge with dreamweaver html files, e.g if I change anything in my edge project and publish it I dont need to transfer the html over to my page again.
    I thought the best way to do this was put all the edge files into there own folder within my sites_files folder and then use iframe. However when I did this, I can not figure out how to use CSS to style the iframe.
    this is what I have tried    
    <iframe id="test" src="mackbyte1_files/animation/power-out-setup/power-out-preview.html" frameborder="0" height="400px" width="940px" scrolling="no" >Your browser does not support this animation. Get a real browses made for the 21st century! We recommend Chrome or Firefox...</iframe>
    I have tried using a ID for the iframe which didnt work.
    Without the iframe my animation is centred in the screen from the CSS with edge html e.g
    .edgeLoad-power-out-preview {
              visibility:hidden;
                        #Stage {
              height: 400px;
              width: 940px;
              margin-left: auto;
              margin-right: auto;
              border-radius: 7px;
              background-color: #CCC;
    I have given up and just manully copy/paste the html into the page I want it in. this works fine however, as stated if i make changes to my animation i have to amend the html which is a little annyoying.
    Is there a fix?
    Thanks in advanced

    joel_pau wrote:
    Hi,
    Can you copy and paste your html code from "mackbyte1_files/animation/power-out-setup/power-out-preview.html" ?
    hey mate,
    this is it
    <!DOCTYPE html>
    <html>
    <head>
              <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
              <meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=IE8"/>
              <title>p-o-preview</title>
    <!--Adobe Edge Runtime-->
        <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/chrome-frame/1/CFInstall.min.js"></script>
        <script type="text/javascript" charset="utf-8" src="power-out-setup_edgePreload.js"></script>
        <style>
            .edgeLoad-power-out-preview { visibility:hidden; }
                        #Stage {
              height: 400px;
              width: 940px;
              margin-left: auto;
              margin-right: auto;
              border-radius: 7px;
              margin-top: 20px;
        </style>
    <!--Adobe Edge Runtime End-->
    </head>
    <body style="margin:0;padding:0;">
              <div id="Stage" class="power-out-preview">
            <div id="Stage_pw-point" class="edgeLoad-power-out-preview"></div>
            <div id="Stage_usb-hub-pluged2" class="edgeLoad-power-out-preview"></div>
            <div id="Stage_usb-hub-unpluged2" class="edgeLoad-power-out-preview"></div>
            <div id="Stage_usb-for-hub" class="edgeLoad-power-out-preview"></div>
            <div id="Stage_usb-hub-pluged-unlit" class="edgeLoad-power-out-preview"></div>
            <div id="Stage_usb-cable" class="edgeLoad-power-out-preview"></div>
            <div id="Stage_imac" class="edgeLoad-power-out-preview"></div>
            <div id="Stage_usb_icon-power-out" class="edgeLoad-power-out-preview"></div>
            <div id="Stage_Lightning" class="edgeLoad-power-out-preview"></div>
            <div id="Stage_imac-off" class="edgeLoad-power-out-preview"></div>
            <div id="Stage_shutdown-page" class="edgeLoad-power-out-preview"></div>
            <div id="Stage_shutdown-page-30" style="display:none;"></div>
            <div id="Stage_imac-black-off" style="display:none;"></div>
            <div id="Stage_RoundRect" style="display:none;"></div>
            <div id="Stage_play-btn" style="display:none;"></div>
        </div>
    </body>
    </html>

  • Best Way to Define Employee Numbering For Different Countries

    HI all
    I am working on for a project which will be for Multiple countries.But Each country has different Instances.Now the questions is What could be the Best way to Define Employee numbering for all the Regions ? As for as My knowledge goes It would be Number prefixed by Country.Then How we can have Alpha numeric in employee Coding ? We need to have Fast Formula to Ahieve this task.If any body has come across this scenario please share your thoughts .Any thoughts are greatly Appreciated.
    Cheers
    Kumar cs

    If you have each country on a different instance and you want employees to retain their employee number on transfer between countries, I believe you have two options:
    i) Use manual numbering. One recent change to the system is that you can update the numbering profile from Auto to Manual and back to Auto again. So you could potentially leverage this manual workaround when a cross BG transfer happens.
    ii) Bespoke module to export all emp numbers into a 'central repository', e.g., flat file, that can be accessed by all instances, imported regularly and then referenced by your Fast Formula. You would also need processing to determine when a person is a transfer from another BG or a new hire; probably have to be some control field on flex. Basically, this is a requirement made difficult by the decision to host each legislation on a different instance; I would never recommend clients to go down this route but I guess it's too late in your case.
    If cross BG transfers are not common, e.g., less than 5 a week, I would recommend option 1.

  • Best way of including timing in a waveform graph?

    Hello all,
    I've been toying with a number of different ways to do this, but so far I haven't had all that much luck. I've posted a picture so you can see what's going on. All I have is 4 plots that need to be plotted with accurate timing information on the x-axis. I guess I'm just wondering what the best way to go about this is. This method seems to be the most cluttered and messy that I've done, but is the only one I've gotten to have the actual correct timing info on the graph. I would put a wait in the loop, but I need to acquire this data as fast as possible. Thanks for any help!
    Geoff
    Attachments:
    Graphing Test.jpg ‏74 KB

    The display options you have chosen are OK on their own.
    If you're looking to get more speed out of the code, try only graphing the data every 10 iterations or so. You can save the processed data (your waveforms) in a shift register where they can then be appended every 10 iterations.
    This will obviously not clean up your code. The best way to clean up your code might be to simply throw the conversions you're performing into a sub-vi. Or create a time input for your "meters" VI and have thr processing done there with correctly-scaled values being outputted.
    Hope this helps
    Shane.
    Using LV 6.1 and 8.2.1 on W2k (SP4) and WXP (SP2)

  • Best way to include appendices to pages document

    I am trying to transition from using MS office (for over a decade now) to using the Apple suite of apps.
    I am in grad school so I write a lot of papers. I am working on one now that requires appendices at the end. I am working on the paper in sections right now (main body, appendices 1, 2, 3, etc..) and was curious what the best way to do something this is in pages?
    Can you create different sections within one one document instead of simply copying and pasting the appendices at the end of my document? That would be a big hassle, going back and forth between different files. Like I said, I would like to be able to keep them all on one document.
    Any ideas? Do you think it's perfectly doable in grad school to use only Pages for your word processing needs? (I've had to many crashes with Office on my mac, and am ready for the full change over.) Any advice, or suggestions?

    Rick
    I am not a real user of Word but I can give you some of the obvious things that Word has that Pages does not.
    1. More layouts: Draft/Web/Outline/Print/Notebook/Publishing
    2. A real desktop in Publishing that you can move objects to and off that surrounds the page
    3. Themes which set basic fonts and color schemes
    4. Non-printing characters
    5. Much bigger collection of Objects/Shapes
    6. Sophisticated diagramming tools (SmartArt)
    7. ClipArt
    8. Symbols palette
    9. Libraries
    10. Citations
    11. Scrapbook for clippings
    12. Bilingual dictionaries with translation service
    13. Projects, a way of co-ordinating your files across MsOffice software including Entourage to merge/create bulk email
    14. Templates for tables
    15. WordArt a way of altering text decoratively
    16. Autofit
    17. Macros
    18. Labels/Envelopes/Letter Wizzard/Pre-Printed
    19. Format Painter to copy apply formatting
    20. Inbuilt Sorting
    21. A Work Menu
    22. Multiple (customizable) Toolbars
    23. Much bigger and extendable Autotext feature
    24. Much bigger selection of Auto-shapes
    25. Line Numbering
    26. Much bigger and more flexible T.O.C.
    27. Much wider choice of Hyperlinking both within and between documents, email and web pages
    28. Much bigger selection of languages
    29. More flexible document protection
    30. Customizable keyboard
    31. Document tiling
    32. Audio notes
    33. Proofing tools
    34. Much bigger preference choices
    35. 3D objects
    36. Multiple Master pages
    37. Varied page orientation and sizes within the same document
    38. Ability to swap images
    39. Hyphenation control
    40. Open XML
    41. Automator support
    42. Wider range of document formats
    43. Greater compatibility with PC formats
    44. Direct link to user community
    45. Autosave/Recovery
    This was what a quick browse revealed. I suggest you try both sets of applications and explore, as I have done, for things that you find interesting.
    Peter

  • Best Way to debug Javascript

    Hi,
    I have a random bug in Javascript which locks the loaded page
    sometimes when i executed the pages outside Dreamweaver. What is
    the best way to denug?
    Thanks.

    Found that microsoft provides a script debugger.. 
    Thanks..

  • Best way to import illustrator files into motion

    Whats the best way to import titles created in Illustrator into Motion5?
    Thanks in advanced for any help.

    Exporting as PDFs and importing into Motion is great. However, if your illustration is a grouping of paths intended for animation (e.g. a face with lips and eyes that you'd like to animate independently) then the PDF method can become fairly tedious.
    Unfortunately Motion doesn't support Adobe Illustrator's compound path type. Coming from Adobe AfterEffects I was fairly disappointed in this since much of what I did in AfterEffects required animation of my compound path vector art. However, compound paths can be simulated using masks in Motion fairly easily and although this method has limitations it works very well.
    Using Adobe's API I've written a free plugin for Illustrator called "Motionize" which allows an Illustrator user to select a shape in their Illustrator file and export it to a single Motion shape file. It supports simple shapes, lines, groups and compound paths as well. There is a sample file included to get you started and I would appreciate any feedback via my site as to how it can be improved.
    It currently supports only one selected item at a time and does not support gradients though I am working on these issues. I hope it helps! I use this too so it's something under constant development.

Maybe you are looking for

  • Search Help with in a serach help required in SRM 4.0

    Hi,                                                      Requirement: Search help required for Product Category field in the Search help for Product(BBPH_PRODUCT) in SRM portal. This search help is used in Create shopping Cart transaction. The hyper

  • Making a PDF X3 file for printing in only 1 colour (black)

    Hi, Sorry but it seems I need again some help. From InDesign CS 3 I am making (Print to Adobe PDF) a PDF file for a printing house (books and magazines). I need to do a PDF X3 compatible file, and among other settings it checks that indeed the file h

  • Multiple DMVPNs within separate VRF's using crypto keyring

    Hi All, I have deployed ASR's within a service provider environment acting as the DMVPN hubs for multiple customers networks contained within their own VRFs. In each case from the tunnel perspective the iVRF and fVRF are the same for a specific custo

  • Weblogic.application.ModuleException

    Hi, I am trying to deploy an Web application with EJB's. But it is giving me the below error. Please if anyone can help me out. Message: weblogic.application.ModuleException: Context path '/HelloWorldWeb' is already in use by the module: HelloWorldWe

  • WebUtil DLL files location with OAS v10.1.2.3 with Sun Java 1.5

    Question about the future Client (under MS Vista) which works with OAS. With MS Vista on the client, the certified versions are:- -Clientside: Sun Java 1.5_10 and above -OAS: v10.1.2.3 (apparently to be released in March 2008) See table and notes at