How to form index to the html files

While forming index to .html files it is giving the error.
Error:javax.servlet.ServletException: Servlet execution threw an exception
root cause
java.lang.NoSuchMethodError: org.apache.lucene.document.Field.<init>(Ljava/lang/String;Ljava/lang/String;Lorg/apache/lucene/document/Field$Store;Lorg/apache/lucene/document/Field$Index;)V
     sample.dw.paper.lucene.index.IndexManager.addDocument(IndexManager.java:78)
     sample.dw.paper.lucene.index.IndexManager.createIndex(IndexManager.java:56)
     sample.dw.paper.lucene.search.SearchManager.search(SearchManager.java:45)
     sample.dw.paper.lucene.servlet.SearchController.doPost(SearchController.java:29)
     sample.dw.paper.lucene.servlet.SearchController.doGet(SearchController.java:38)
     javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
     javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
note The full stack trace of the root cause is available in the Apache Tomcat/5.5.15 logs.
It is giing the error like this . I alredy palce the jar fiels of Org.apache.lucene.

While forming index to .html files it is giving the error.
Error:javax.servlet.ServletException: Servlet execution threw an exception
root cause
java.lang.NoSuchMethodError: org.apache.lucene.document.Field.<init>(Ljava/lang/String;Ljava/lang/String;Lorg/apache/lucene/document/Field$Store;Lorg/apache/lucene/document/Field$Index;)V
     sample.dw.paper.lucene.index.IndexManager.addDocument(IndexManager.java:78)
     sample.dw.paper.lucene.index.IndexManager.createIndex(IndexManager.java:56)
     sample.dw.paper.lucene.search.SearchManager.search(SearchManager.java:45)
     sample.dw.paper.lucene.servlet.SearchController.doPost(SearchController.java:29)
     sample.dw.paper.lucene.servlet.SearchController.doGet(SearchController.java:38)
     javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
     javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
note The full stack trace of the root cause is available in the Apache Tomcat/5.5.15 logs.
It is giing the error like this . I alredy palce the jar fiels of Org.apache.lucene.

Similar Messages

  • How do i change the HTML file names for existing index

    Hi,
    How do i change my existing HTML file names for indexes. The Html file name is disabled when we click on properties.
    Ex:   Index Keywork : Architecture
            Old HTML Page/URL =: Architecture.htm
    I want to change  Old HTML Page/URL =: Architecture.htm to architecture_new.htm
    Please find the screenshot attached.

    That's because you are looking at the Properties and that is not how you create index entries.
    Highlight the Index keyword ("Paste" in this example). It shows below what is already linked. If you delete that, the keyword will be displayed in bold to show no keyword is attached. You can add further keywords by dragging them from the Topic List.
    See www.grainge.org for RoboHelp and Authoring tips
    @petergrainge

  • How to update the HTML file so that we can Control our process in real time

    After installing following three steps as per the lookout 4 online help I am unable to Monitor and control the Process in HTML format, which was exported manually in lookout server.
    1) Creating a Web Client Page in Lookout
    2) Download a Lookout Web Client
    3) Setting Up Own Web Server
    My browser shows only the instance, which I have uploaded manually without any update
    Problem: How to automatically update/refresh the HTML file so that we can Monitor/Control our process in real time/bi-directional mode.

    Hi,
    It seems like your process is not updating. When you create a Web Client, it uses ActiveX which lets you control the Lookout process fully. Make sure that you run the process. You can do this by pressing CTRL+Spacebar which puts it in Run-mode. Perhaps then you may see your graphs, etc updating.
    Also, please refer to page 11-1 of the Users Manual linked below:
    http://www.ni.com/pdf/manuals/322390a.pdf
    What kind of Web Server are you using? Make sure all the settings in it are done properly. If you have LabVIEW, you can use the LabVIEW Web Server.
    Hope this information is helpful. Please let us know if you have any further questions.
    Regards,
    A Saha
    Applications Engineer
    National Instruments
    Anu Saha
    Academic Product Marketing Engineer
    National Instruments

  • How to embed the html file into form 6i?

    How to embed the html file into form. What control activeX should i use? please help!!!!!!

    You can use web.show_document function for this purpose. See
    form builder help topics for more details.
    Hope this helps.

  • Files created in DW with slices, how can I email the html files to someone

    Hello,
    I was wondering if someone could help me please? I created my first website in DW CS4. I used Illustrator to create it, added slices, then did the rest in DW. My site is not live yet - I have not yet uploaded the files to the web host. However, I need to email the .html file to someone so that they can see what I have created so far for the site. But when I attach the .html files, the person I send them to cannot view them - when they open the file it is just a bunch of placeholders where the slices are and you can't see the web page at all. I am a newbie to web design so this is probably quite an ignoramus question. I appreciate any help anyone can give me!!

    The best practice is to upload the site to a TEST folder on your  remote server for debugging purposes.  (yourdomain.com/TEST/index.html)
    Then send your client an email with the URL so they can see the site.  When you're done testing & debugging, remove the TEST folder from remote server.
    Nancy O.
    Alt-Web Design & Publishing
    Web | Graphics | Print | Media  Specialists
    www.alt-web.com/
    www.twitter.com/altweb
    www.alt-web.blogspot.com

  • Can AnyOne Please Tellme How to configure the HTML files

    This is very Urgent.
    1.I am using the WLS7.0 sp1 .I need to configure theHTML files which are in a
    different path how can I map them to the present DefaultWebAPP directory.
    2. How can I get rid of the port number when I am fully using in production mode.
    I have been posting this query since long but in vain. Please guide me

    1. I got rid of port number with link provided by the karthik.
    2.How can I create a link .The link appends to the defaultwebapp directory
    and checks from their .I need to know how to configure the
    HTML files which are not in the DefaultWebApp.But completely in directory.
    Any suggestions !!!!!!!
    Shehzad <[email protected]> wrote:
    1. You can create a link to that directory
    2. In order to get rid of port number, either boot weblogic at default
    port 80, or use Apache or Iplanet webserver, and use Weblogic plugin.
    That way all the traffic comming in from http will comein at port 80
    to the webserver, and would then be forwarded to Weblogic at whatever
    port it is booted.
    This is very Urgent.
    1.I am using the WLS7.0 sp1 .I need to configure theHTML files whichare in a
    different path how can I map them to the present DefaultWebAPP directory.
    2. How can I get rid of the port number when I am fully using in productionmode.
    I have been posting this query since long but in vain. Please guideme

  • How to display the HTML File Titles instead of File Names

    Hello All,
    I want to display the HTML file titles instead of File names in the Search Results. I've tried to give this command in the 'Visible Properties' in the 'SearchResourceRenderer' as:-
    Visible Properties: rnd:displayTitle
    However this is not working for me. If anyone has an idea of what to pass here or any other alternative to display the Titles.
    Regards
    Vaib

    Summary of steps:
    1) Standard Layout Set used: SearchResultLayoutSet
    2) Create a new layout set using ADVANCED COPY
    3) Change properties as you require
    4) Next modify the search OTH file to reflect this newly created Layout Set (under KM > root > etc > oth > search.oth edit xml file property rndLaoutSet from SearchResultLayoutSet to MyCustomSearchResultLayoutSet)
    5) Check in the document to complete the editing process if Edit Locally is used!
    6) Lastly, activate the OTH file by –
    •     Setting Debugging settings via Debugging Settings
    •     Performing a normal search
    •     Clicking Rendering information and then following link OTH Overview click on Reload
    7) Reload above reloads the OTH file and performing search again will yield the desired result
    8) To turn off the Rendering Information link remove the user id from Debugging Settings.
    Cheers
    Ankit

  • How to mail the html file using javamail????

    hi
    i have captured the output of a jsp page in a html file....
    now i wish to send it in the mail ( *** not as an attachment)
    ie
    i wish the output of the jsp ie the html file to be displayed in
    the message box (ie text area) ..... and then when recieved by the
    receipient it shoud be displayed in the message area....
    is there any way to do this ........

    well as said by my fellow poster googling could have given you quick results.
    Anyways,if you are unable to do so checkout the below code snippet.
    SendMail.java:
    ===========
    import java.io.File;
    import java.io.FileReader;
    import java.io.BufferedReader;
    import java.util.Properties;
    import javax.mail.Session;
    import javax.mail.Message;
    import javax.mail.Transport;
    import javax.mail.internet.InternetAddress;  
    import javax.mail.internet.MimeMessage;
    import javax.activation.*;
    * @Author RaHuL
    * uses SMTP to send Email.
    public class SendMail {
        /** Method used to read contents of html/text/XML file */
        public String readFile(String fileName){
           StringBuffer sb = new StringBuffer();
           BufferedReader input = null;
           try{
               input = new BufferedReader(new FileReader(fileName));
               String str = null;
               while ((str = input.readLine()) != null){    
                      sb.append(line);
           }catch(Exception exp){
               exp.printStackTrace();
           }finally{
                  try {
                        if (input!= null)  
                          input.close(); 
                   }catch (Exception ex) {
                         ex.printStackTrace();
           return sb.toString();
        /** Send an HTML Email with the specific subject to specfic toAddress based on specified fromAddress & Smtp Hostname
          * and returns true on success.
        public boolean sendMail(String toAddress,String fromAddress,String hostName,String subject,String htmlMessage,String contentType) {
           boolean flag = false;    
            try {
                 String to = toAddress;
                 String from = fromAddress;     
                 String host = hostName;
                 // Setting Mail properties
                 Properties props = new Properties();
                 props.put("mail.smtp.host",host);
                 props.put("mail.debug","true");
                 // Getting a New Instance Generated by the API
                 Session session = Session.getInstance(props);
                   NOTE: a Mail Session could be configured and could be got from the Container via JNDI
                         which could be a better practise.
                // Instantiate a message
                Message msg = new MimeMessage(session);
                //Set message attributes
                msg.setFrom(new InternetAddress(from));
                InternetAddress[] address = {new InternetAddress(to)};
                msg.setRecipients(Message.RecipientType.TO, address);
                // Setting Subject Type
                msg.setSubject(subject);
                msg.setSentDate(new Date());
                // Setting Content Type
                msg.setContent(contentType);
                // Set message content
                msg.setText(htmlMessage);
                //Send the message
                Transport.send(msg);
                flag = true;
            }catch (Exception mex) {
             // Prints all nested (chained) exceptions as well
                mex.printStackTrace();
         return flag;
        public static void main(String args[]){
            SendMail sm = new SendMail();
            String htmlMessage = sm.readFile("myHtmlFile.html");
            boolean flag = sm.sendMail("[email protected]","[email protected]","your.smtp.server","EMail SubJect",htmlMessage,"text/html");
            if(flag)
              System.out.println("MAIL SENT SUCCEFULLY");
             else
              System.out.println("MAIL SENDING FAILURE");                          
    }NOTE:
    =====
    Make sure you inculde javamail & java activation libraries.
    Hope that might help :)
    REGARDS,
    RaHuL

  • Want to open a new browser window and display the html file in locale disk.

    Hi,
    I want to open a new browser window and display the html file in local drive. The below html applet work in local system successfully. But i deploy the same in web server (Tomcat) and try the same in client machine it does not work. Please help.
    Note:
    The class below fileopen.FileOpen.class i make it as a jar and put it in jre\ext folder at the client machine.
    ------------------------------------FileOpen.html(Tomcat)-----------------------------------------------------
    <html>
    <body >
    <applet code="OpenFile.class" archive="loadfile.jar" width="100" height="100">
    <param name="path" value="file://c:/open.html" />
    </applet>
    </body>
    </html>
    -------------OpenFile.java in server(Tomcat)--------------------------------------------
    public class OpenFile extends Applet implements ActionListener{
    String path = "";
    fileopen.FileOpen open = null;
    Button b = null;
    public void init(){
    path = getParameter("path");
    b = new Button("Open");
    b.addActionListener(this);
    add(b);
    public void actionPerformed(ActionEvent ae){
    try
    open = new fileopen.FileOpen(this,path);
    catch (Exception e){
    e.printStackTrace();
    -------------------------------------------FileOpen.java /Client JRE/ext----------------------------------------------------
    package fileopen;
    public class FileOpen
    AppletContext context = null;
    URL url = null;
    public FileOpen(Applet applet,String path)
    try
    if(null != applet){
    context = applet.getAppletContext();
    if (null != path)
    url = new URL(path);
    context.showDocument(url, "_blank");
    }catch(Exception ex)
    ex.printStackTrace();
    Please help to solve this issue very urgent.
    Thanks in advance.
    By,
    Saravanan.K.

    zzsara wrote:
    I want to open a new browser window and display the html file in local drive. ...Did you ever pause to consider how ridiculous that is?
    The best audience for applets is people off the internet. 'People off the internet' might be using a computer that has no (what was it?) 'open.html' in the root of the C: drive. In fact (shock horror) they may not even be running Windows, and would therefore probably have no 'C:' drive at all.
    If you do not intend to distribute this to people off the web, an application makes a lot more sense, but even then, you cannot rely on the document being there unless you 'put it there' (during installation, for instance).
    As the other poster intimated, applets can load documents off the local disk as long as they are trusted. Here is an example*, but note that it is not so rash as to presume any particular path or file, and instead leaves it to the user to choose the document to display.
    * The short code can be seen at SDNShare on the [Defensive Loading of Trusted Applets|http://sdnshare.sun.com/view.jsp?id=2315] post.
    On the other hand, a sandboxed applet can load any document coming from its own server via URL, or get showDocument(URL) to work. In that case, the JRE must recognize that the URL is from its own server, so the best way to form URLs for applet use is via the URL constructor
    new URL(getDocumentBase(), "path/to/open.html");That is how I form the URL in this [ sandboxed example of formatting source|http://pscode.org/fmt/sbx.html?url=/jh%2FHelpSetter.java&col=2&fnt=2&tab=2&ln=0]. Of course, in this case the applet loads the document, then parses the text to draw the formatted version, but the point is that an URL produced this way will work with showDocument(URL).
    I am pretty sure showDocument() in an applet off the internet will work with an URL pointing to a foreign (not its own) server, but it will not be able to load documents off the end user's local disks.
    I suggest a couple of things.
    - Try to express this problem in terms of what feature it is that you want to offer the end user. Your question jumps directly to a bad strategy for achieving ..who knows what? An example of a feature is "Shows the applet 'help' files on pressing F1".
    - A good way to indicate interest in a solution is to offer [Duke stars|http://wikis.sun.com/display/SunForums/Duke+Stars+Program+Overview] to match that interest.
    Edit 1:
    ..and please figure out how to use the CODE tags.
    Edited by: AndrewThompson64 on Sep 12, 2008 11:14 PM

  • Problem launching Firefox from Windows with file path that contains space characters in the html file's file name

    We have a software application that programmatically launches the default web browser using the Windows shell execute function ("ShellExecuteA" in the "shell32.dll" library of the Windows API) along with a file path for a saved local html file that is to be displayed. In the case that FireFox is the default browser and the file path for the html file contains any space characters in the html file's file name, Firefox (in this case v7.01) will display an error message "File not Found..." and then will also proceed to open tabs for each of the individual words in the file name, launching as the URL path, each individual word appended to ".com".
    In the following example, the path "C:\KSSecOfState\Forms\Kansas Secretary of State - Filings and Forms.htm" when launched programmatically, resulted in the error message "File not Found...Firefox can't find the file at /C:/KSSecOfState/Forms/Kansas." and opened up browser windows for "http://www.secretary.com/", "http://www.of.com/", "http://www.state.com/", "http://www.and.com/", and attempted to launch "http://forms.htm". If the same file (renamed) is launched using the path string "C:\KSSecOfState\Forms\KansasSecretaryOfState-FilingsAndForms.htm" the file opens up correctly in Firefox. Clearly the presence of spaces in the file name is causing the problem.
    I should also note that either path (with or without space characters) works properly if pasted directly into the Firefox URL path menu bar for a live instance of Firefox. The test path strings I used were:
    C:\KSSecOfState\Forms\KansasSecretaryOfState-FilingsAndForms.htm
    C:\KSSecOfState\Forms\Kansas Secretary of State - Filings and Forms.htm
    Does anyone know anything about this problem or how to work around it (other than the obvious answer of taking the spaces out of the file name which is not possible for this application). It seems the problem is specific to Firefox. IE works properly if launched programmatically with spaces in the file name passed to it. I haven't tested other browsers yet.
    Thanks!

    If starting from ShellExecute works the same as starting from the command line then there are two options:<br>
    Put everything inside double quotes<br>
    '''C:\Program Files\Mozilla Firefox\>'''firefox.exe '''"c:\test\svg test.htm"'''<br>
    Convert to a valid url with file:// protocol and percentage-escaping the space<br>
    '''C:\Program Files\Mozilla Firefox\>'''firefox.exe '''file://c:\test\svg%20test.htm'''<br>

  • Cannot read the html files

    I cannot seem to make JavaHelp find my HTML files, although it has found my Map and XML files.
    The structure is as follows:
    - the XML files are in myclasspath/doc/onlinehelp
    - the HTML files are in myclasspath/doc/onlinehelp/html
    How should I reference them from my Map.jhm file?
    Have I forgottoen any enviroment variables?
    This is really urgent
    Thanks
    Bj?rn

    The entries in your map file should take the form
    <mapID target="target_string" url="html/filename.htm" />
    so that the url includes the relative path from the directory where the xml files are.

  • Does a PHP file need to be attached to the HTML file?

    I know that CSS files need to attach to the html files, but what about PHP? Because when I try to test it, it asks me to make it a test server, but it never works. I know I'm missing. Please help. Thank you!
    This is my html form:
    <form action="form_process" method="post" name="contact_form">
    <form class="form">
    <p class="name">
    <input type="text" name="name" id="name" placeholder="John Doe" />
    <label for="web">Name</label>
    </p>
    <p class="email">
    <input type="text" name="email" id="email" placeholder="[email protected]" />
    <label for="email">Email</label>
    </p>
    <p class="phone">
    <input type="text" name="phone" id="phone" placeholder="555-555-5555" />
    <label for="phone">Phone</label>
    </p>
    <p class="text">
    <textarea name="text" placeholder="Questions or Comments"></textarea>
    </p>
    <p class="submit">
    <input type="submit" value="Send" />
    </p>
    </form>
    This is my PHP:
    <?php
    $name = $_POST['name'];
    $email = $_POST['email'];
    $phone = $_POST['phone'];
    $message = $_POST['text'];
    $to = "[email protected]";
    $subject = "New Message";
    mail ($to, $subject, $message, "From: " . $name);
    echo "Your message has been sent."
    ?>

    No.  A Local Testing Server is software that you install on your local computer so you can parse PHP scripts to test them in your local browsers.  It's not very complicated.
    Get one of the following Apache servers for your OS and follow the installation instructions.
    WAMP for Windows
    http://www.wampserver.com/en/
    XAMPP for Windows
    http://www.apachefriends.org/en/xampp-windows.html
    XAMPP for Mac
    http://www.apachefriends.org/en/xampp-macosx.html
    MAMP for Mac
    http://www.mamp.info/en/downloads/index.html
    See Setting up a PHP environment in Dreamweaver
    http://www.adobe.com/devnet/dreamweaver/articles/setup_php.html
    Nancy O.

  • Firefox when saving a "complete html" file is downloading a folder and "2" copies of the html file not one. One of these has the same name but "0" kb content

    Hi. The only save options for a full html type file on Firefox is as "web page, complete" and as I say when saving with Firefox the program is saving the usual yellow folder with links and artwork files etc, but is saving 2 copies of the HTML file where on of these files is empty, won't open and gets locked to the destination it was saved to. This empty file can't be moved, and can't be deleted. When this is attempted it gives message "cannot delete (or "move" if this is the case) : Cannot read from the source file or disc."
    To overcome this I now use Internet Explorer, dut prefer not to. I have also deleted Firefox from my system and re-installed it, but this did not help. How can I stop this doubling of saved files? and how can I delete the ones that are now fixed to my desktop? can you lease help?

    You said, ''Would like to sort this one out...any clues?''
    Maybe something here will help:
    *http://en.wikipedia.org/wiki/MHTML
    *http://en.wikipedia.org/wiki/Mozilla_Archive_Format
    *http://maf.mozdev.org/
    *http://maf.mozdev.org/documentation.html

  • How to set default value for html:file in struts

    hi
                   i am working on an application using struts situation is i am using the
    <html:file property="" /> to allow the user to upload file. but i need that a default file should be set so that even if the user donot click browse ie                the user wish to upload that default file the default file get uploaded on page submition.     Is it possible to set any default value for html:file ...if yes plz provide any suggestion or links how to achieve this.     thanks in advance

    www.google.com?q=STRUTS+DOCUMENTATION

  • How can i include css in html file when exported

    I want the CSS should be included in the html file when exported, how is that posable?

    Muse follows its own structure and keeps HTML, CSS and JS code in separate files as and when possible. If you want all that code to be merged into the HTML file itself, then there is no option to force Muse to do that. You can however, add your own CSS code into the HTML page by adding the CSS using either the Insert HTML option or using the HTML for <head> option in Page Properties > Metadata.
    Cheers,
    Vikas

Maybe you are looking for

  • ITunes displays error message -69 when syncing iPhone

    hi, iTunes displays error message -69 when i sync my iPhone 3GS, this is just for syncing music to my iPhone. apps syncing is ok. can anyone help please? thanks

  • Powershell Script to manage document library

    Hi, I would like to write a powershell script that will be run as a job in the task scheduler on a daily basis. The  idea is to delete documents or folders from a particular folder in the document library that are created 30 days ago. Can anyone help

  • Flash site not showing in Internet Explorer

    Please can some one help, I have been asked to get a website up and running.  It is a Flash site, which works fine in Firefox and Safari, but its just a white screen in IE.  Does anyone know why? the website is www.vortex-cae.co.uk and the scrip is :

  • HT5312 how do you reset I security questions if I dont remember them?

    i dont know how to reset my apple id questions because i forgot the answers so i cant reset them without help

  • Locked PCI/AGP

    I have the K7N2-Delta L. Is the PCI/AGP bus speed locked automatically or do I have to change settings for these items in bios?  I oc'd fsb to 200Mhz w/333Mhz ram runs good but Ghost Recon has graphic noise bars and blips in sound when I run it.  I h