PassMark Logo
Home » Forum

Announcement

Collapse
No announcement yet.

Search Box but no Submit Button or Options

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Search Box but no Submit Button or Options

    I am in the process of trying out several client-side search options. So far your product looks superior as far as the interface is concerned as well as the options available.

    However, virtually every time I try to create a search page using the javascript option for offline mode on my local drive (ultimate purpose is for CD use), the product indexes the appropriate directory and files, writes out the javascript files and the search.html. When I open the search.html file all I get is the search box, no submit button or options.

    I get the same thing whether I output as javascript or CGI.

    Can someone please tell me why this is happening and what I can do to fix it.

    Using the standard search form with no modifications, I also get a javascript. IE says:

    Line: 223
    Char: 9
    Error: 'STR_FORM_SUBMIT_BUTTON' is undefined
    Code: 0
    URL: The directory I want the search files to reside

    If I open search.js and go down to the Main search function section and replace STR_FORM_SUBMIT_BUTTON with "Submit", I see a submit button on the search.html page. Same thing goes for STR_FORM_RESULTS_PER_PAGE, if I replace this with "Results per page:", it works....

    Shouldn't the software be doing this itself?

  • #2
    Yes, you should not be required to do this manually.

    The value for the string, 'STR_FORM_SUBMIT_BUTTON', and the others, come from the English.zlang file (assumuing you are using English). This file is installed during the install of Zoom and can normally be found here,

    C:\Program Files\Zoom Search Engine 4.0\lang\English.zlang
    (depending on where you did the install for Zoom)

    So if these strings are missing from the Javascript script, then the most likely reason is a problem in the English.zlang file.

    Are your using the English language option?
    Did you edit the English.zlang file?

    ------
    David

    Comment


    • #3
      The English.zlang file did install correctly, it seems that the English.zlang is for the Interface, none of the JS files reference that.

      I am using the English language option and did not edit the English.zlang file.

      When I received the error and saw that the JS error was with STR_FORM_SUBMIT_BUTTON, I just searched the directory to see which JS files that Zoom outputs to see where the STR_FORM_SUBMIT_BUTTON was referenced from and noticed that it's in the search.js and zoom_index.js. Then I just took the var from zoom_index.js to see if I could fix the submit page.

      After manually tweaking search.js, I can now see the search box, button, results and match any search words / all search words. All of which I changed the "STR_" to the actual words from the zoom_index.js.

      Still no working search page.

      Any suggestions?

      Comment


      • #4
        Another try...
        I deleted everything and started completely over.

        After manually adding the lines below into the Search.html, the Search Form started to work.

        Zoom writes out:
        <script language="JavaScript" src="settings.js"></script>
        <script language="JavaScript" src="search.js"></script>

        Manually added:
        <script language="JavaScript" src="zoom_index.js"></script>
        <script language="JavaScript" src="zoom_pages.js"></script>
        <script language="JavaScript" src="zoom_titles.js"></script>
        <script language="JavaScript" src="zoom_descriptions.js"></script>


        Why do these have to be manually added for the search to work?
        If these are needed, shouldn't the program be adding these?

        Thanks,
        Lisa

        Comment


        • #5
          None of the modifications you have made are normally required to get Zoom to work. This is most likely to be either a configuration issue, browser issue, or a broken script. Check the following:

          1.) Are all the search files created by Zoom (this includes all files beginning with "zoom_", settings.js, search.js, and search.html) located in the same folder?

          2.) What version of browser are you using? Javascript runs entirely in the browser and browser compatibility for the language varies alot. While we have made sure to test it on the most common versions of browsers such as IE 5.0-6.0, Mozilla 5.0, Firefox 1.0, and Opera - there are many others out there which may perform differently.

          3.) Is Javascript enabled for your browser? You may have security features enabled which block execution of some Javascript commands.

          For example, the script links you said you added in your last post - all of those should have been written out dynamically by "search.js" - if it executed correctly. One other possibility is if you've made changes to "search.js" which broke this, or you are using an older version of the search script with a new version of the Indexer. Speaking of which...

          4.) What version and build of Zoom are you using? Click on Help->About for information.

          5.) Do you have any anti-virus or security software running, which has "Script Blocking" capabilities?

          If you continue to have problems, zip up your search files and e-mail them to us (see our Contact Us page for info).
          --Ray
          Wrensoft Web Software
          Sydney, Australia
          Zoom Search Engine

          Comment


          • #6
            In response to your questions.

            1.) All files are in the same directory.

            2.) Tested with lIE v6.0.2800.1106, Mozilla Firefox v1 and Netscape v4.79 - all have Javascript enabled.

            3.) Javascript is enabled and I have no other Javascript related issues.

            For testing purposes, I just had Zoom build another Search in a completely different directory.

            4.) Zoom v4.0 Build 1016 (downloaded a few days ago)

            5.) AVG Anitvirus and all other Javascript works fine.


            I'll zip up and email you everthing in the directory.

            Comment


            • #7
              Any resolution to this problem yet?

              Comment


              • #8
                We had a look at your files and it appears that you have modified the "search.js" file.

                At the top of the file where it writes out the HTML to include zoom_index.js etc, you have changed it from (what it should be):

                document.write("<script language=\"JavaScript\" src=\"zoom_index.js\" charset=\"" + Charset + "\"><\/script>");
                document.write("<script language=\"JavaScript\" src=\"zoom_pages.js\" charset=\"" + Charset + "\"><\/script>");
                document.write("<script language=\"JavaScript\" src=\"zoom_titles.js\" charset=\"" + Charset + "\"><\/script>");
                document.write("<script language=\"JavaScript\" src=\"zoom_descriptions.js\" charset=\"" + Charset + "\"><\/script>");
                To the following (which is incorrect):

                document.write("<script language=\"JavaScript\" src=\"Search\zoom_index.js\" charset=\"" + Charset + "\"><\/script>");
                document.write("<script language=\"JavaScript\" src=\"Search\zoom_pages.js\" charset=\"" + Charset + "\"><\/script>");
                document.write("<script language=\"JavaScript\" src=\"Search\zoom_titles.js\" charset=\"" + Charset + "\"><\/script>");
                document.write("<script language=\"JavaScript\" src=\"Search\zoom_descriptions.js\" charset=\"" + Charset + "\"><\/script>");
                Note the addition of the "Search\" foldername before the filenames for each JS file.

                This breaks the scripts ability to locate the required index files, and this is why you are missing your submit button and search form. Your single slash after the word "Search" is also causing errors because the slash is an escape character in JS, and this is invalid usage.

                All search files should be located in the same folder, so there is no need to change this file path in the script. We would recommend re-installing Zoom, re-index your site, and making sure to NOT modify the "search.js" file from the original version installed and created by the indexer.
                --Ray
                Wrensoft Web Software
                Sydney, Australia
                Zoom Search Engine

                Comment


                • #9
                  Lang Folder Missing

                  I experienced the same problem as Lisa and found that the Lang folder was not installed in C:\Documents and Settings\Administrator\Application Data\Macromedia\Dreamweaver MX 2004\Configuration\Zoom Search Engine but was installed in C:\Documents and Settings\All Users\Application Data\Macromedia\Dreamweaver MX 2004\Configuration\Zoom Search Engine Has this been missed off your install paths? Normally, if I have a choice, I install to Admin only but Zoom seems to have installed in both Admin and All Users, save for the Lang folder.
                  I copied the Lang folder across and all worked as expected.
                  I'm running MX2004, Win2K V5, SP4 and Zoom 4.1
                  Hope that helps,
                  Kisska

                  Comment


                  • #10
                    First, I should point out that this is a different problem to LisaA's, because she wasn't using the Dreamweaver Extension. However, the symptoms are the same and both are caused by missing language files.

                    In this latter situation described by kisska, there should be an error message that says something like "Could not open language file: English.zlang" at the end of indexing (as a red line in the index log).

                    You are correct in that there is a scenario in which the Zoom DW Extension gets installed in two places. This is actually a workaround to a bug in Macromedia's Extension Manager and Dreamweaver MX 2004. It occurs only when you are logged in as "Administrator", but not when you are logged in with an user account with administrator privleges but not named "Administrator".

                    What happens in the former scenario is that Dreamweaver would install in the "All Users" folder, and correctly look there for menu items. This in itself is OK and correct behaviour. However, when it tries to start an external application, it looks in the "Administrator" folder instead - this is not OK and conflicts with the installation and menu behaviour.

                    So we added a workaround which allows Zoom to make a second copy of itself to where Dreamweaver looks for it. Unfortunately we've left out copying of the "lang" folder as kisska noted, and that is why he had that problem.

                    We've now patched the latest build available at:
                    http://www.wrensoft.com/zoom/support/dreamweaver.html

                    This should now successfully install the "lang" folder where it is required. Let us know if you continue to have any problems.
                    --Ray
                    Wrensoft Web Software
                    Sydney, Australia
                    Zoom Search Engine

                    Comment


                    • #11
                      ... But I forgot to mention ...

                      Thanks for the quick and detailed response!

                      I should add that, after trialling the Free Edition, I have since purchased the Pro version.

                      Great Product !

                      kisska

                      Comment

                      Working...
                      X