PassMark Logo
Home » Forum

Announcement

Collapse
No announcement yet.

Parse error - expecting T_OLD_FUNCTION

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

  • Parse error - expecting T_OLD_FUNCTION

    I'm getting this error when I try to search...

    Parse error: parse error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /home/content/u/n/f/unfungames2/html/search/search.php on line 3111

    my server is using PHP 4.x (that's what it says it is, at least). it's godaddy hosting. not sure what on earth this problem is

  • #2
    PHP 4 is now pretty old. PHP 4.0 was released in 1999 and even the more recent V4 releases contain security issues. V5 has been available since 2003/2004.

    Looks similar to this problem with quote characters.

    I'll check what our position on PHP V4 support is with V6 and add some details to this post later today.

    Comment


    • #3
      I just checked the GoDaddy web site. It seems they offer PHP4 and PHP5. So can you try PHP5 ?

      Here is the information from the GoDaddy site.

      By default, files with a .php extension run under PHP 4 and files with the .php5 extension run under PHP 5. The .htaccess file, located at the root of your site, can be used to change these default settings. The following entries in a directory's .htaccess file designate .php files to run under PHP 5 and .php4 files to run under PHP 4.

      AddHandler x-httpd-php5 .php
      AddHandler x-httpd-php .php4

      Changes made to an existing .htaccess file will be seen immediately. When a new .htaccess file is created or an existing .htaccess file is deleted, however, these changes will not be seen until the htaccess cache is cleared. This occurs every hour.

      Comment


      • #4
        I upgraded to PHP 5.0 and now the error is different.

        Zoom files missing error: Zoom is missing one or more of the required index data files.
        Please make sure the generated index files are uploaded to the same path as this search script.


        what files am I missing? here's what i've got in that folder:

        search.php
        search_template.html
        mysearchpage.htm (thats my page i put the search box in)
        settings.php
        zoom_dictionary.zdat
        zoom_pagedata.zdat
        zoom_pageinfo.zdat
        zoom_pagetext.zdat
        zoom_wordmap.zdat

        Comment


        • #5
          This error only appears if one of the following files are not in the same folder as search.php.
          zoom_dictionary.zdat
          zoom_wordmap.zdat

          settings.php

          What is the URL for the folder you are refering to?

          Comment


          • #6
            OK i got it working. changing my PHP version to 5 fixed the first problem, and i fixed the second problem by redoing the indexing online instead of offline.

            great program, by the way. i freaking love it. will definitely be buying it and recommending it on my site

            Comment


            • #7
              We made an attempt to get the Zoom V6 PHP script working on PHP4 today, but it is a big job and would involve a lot of re-testing if we did get it to work in the end.

              As the developers of PHP have discontinued support for PHP4, we have decided to do the same unless there is a massive outcry from our users in the next few weeks.

              So from today we will officially only support PHP5.0 and above for V6 of Zoom.

              V5 of Zoom will continue to support PHP4 and PHP5.

              Comment


              • #8
                This problem has now been fixed.

                As of V6.0 build 1008 (download latest build here),

                Zoom V6 now officially supports both PHP4 and PHP5

                We have rewritten parts of the PHP script so that it will be compatible with both PHP4 and PHP5, in response to popular demand.

                Please let us know if you have any problems with the new release.
                --Ray
                Wrensoft Web Software
                Sydney, Australia
                Zoom Search Engine

                Comment

                Working...
                X