Missing author initials in citation views

Help
adrianbj
2008-12-17
2013-05-28
  • adrianbj

    adrianbj - 2008-12-17

    Hey Matthias,

    I have just noticed a really weird problem. All of a sudden all author initials are missing from all citation views, including the homepage "Most recently added publications:", RTF exports, RSS feeds etc, and it doesn't matter which journal format is chosen, it is still the same problem. Everything looks fine in List View and Details mode though.

    http://ian.umces.edu/literature/show.php?records=all

    Looking through my RSS feed reader which downloads the messages, everything was working fine, then I received one pub with no author initials, then one with and then all since that have not had them. AFAIK I didn't make any code changes around the time that the RSS feed starts showing the problem. A colleague was adding several records at the time when the problem occurred.

    I am battling to figure out where the error is coming from - I have looked around the reArrangeAuthorContents function and various others that I thought might have been corrupted somehow, but can't figure it out. I have replaced my modified cite_html.php and search.php files with the originals and that didn't help either.

    I am not sure if you can think of what the problem might be, but I'd appreciate any thoughts.

    Thanks,
    Adrian

     
    • Matthias Steffens

      Hi Adrian, just quickly (am in a hurry)...

      sorry to hear you're facing trouble.

      I've noticed similar problems during the beta phase where non-ASCII initials got corrupted or vanished when latin1 data were treated as utf8/Unicode or the like. However, this did always occur to individual records only. Other records (which had no non-ASCII chars in author initials) were not affected.

      AFAIK, the problem was solved during the beta phase. Were there any PHP or MySQL updates on the server, or any charset/encoding-related changes?

      You might want to check all charset/encoding-related settings for your refbase database and server.

      http://www.refbase.net/index.php/Installation-Troubleshooting#Problems_with_special_characters

      I'd guess that if you disable the calls to function 'reArrangeAuthorContents()' in the citation style files (and maybe replace with raw author data), the problem will go away. But obviously, this isn't a solution, just a debugging measure.

      Let me know if you've got more info.

      Matthias

       
      • adrianbj

        adrianbj - 2008-12-17

        Hey Matthias,

        Thanks for your thoughts - helpful as always.

        The RSS feed indicator of when things changed was misleading as it updates and downloads the 15 most recent records every time it updates. Turns out the problem started with a php upgrade.

        I just downgraded from php 5.2.8 to 5.2.6 and everything works fine again.

        I just went back to 5.2.8 with and without the Suhosin patch and the problem returns. Went back again to 5.2.6 with the Suhosin patch and eveything is working fine. Could you possibly update one of your servers to 5.2.8 (if you haven't already) and see if it is a universal problem?

        I just looked at my error log and I get the following entries with 5.2.8 (10 sets of these - one for each record being displayed), but nothing with 5.2.6

        [17-Dec-2008 12:25:30] PHP Warning:  preg_replace() [<a href='function.preg-replace'>function.preg-replace</a>]: Compilation failed: unknown property name after \P or \p at offset 7 in /xxx/literature/includes/include.inc.php on line 2780
        [17-Dec-2008 12:25:30] PHP Warning:  preg_replace() [<a href='function.preg-replace'>function.preg-replace</a>]: Compilation failed: unknown property name after \P or \p at offset 7 in /xxx/literature/includes/include.inc.php on line 2784
        [17-Dec-2008 12:25:30] PHP Warning:  preg_replace() [<a href='function.preg-replace'>function.preg-replace</a>]: Compilation failed: unknown property name after \P or \p at offset 11 in /xxx/literature/includes/include.inc.php on line 2787
        [17-Dec-2008 12:25:30] PHP Warning:  preg_replace() [<a href='function.preg-replace'>function.preg-replace</a>]: Compilation failed: unknown property name after \P or \p at offset 10 in /xxx/literature/includes/include.inc.php on line 2791
        [17-Dec-2008 12:25:30] PHP Warning:  preg_replace() [<a href='function.preg-replace'>function.preg-replace</a>]: Compilation failed: unknown property name after \P or \p at offset 7 in /xxx/literature/includes/include.inc.php on line 2794
        [17-Dec-2008 12:25:30] PHP Warning:  preg_replace() [<a href='function.preg-replace'>function.preg-replace</a>]: Compilation failed: unknown property name after \P or \p at offset 7 in /xxx/literature/includes/include.inc.php on line 2780
        [17-Dec-2008 12:25:30] PHP Warning:  preg_replace() [<a href='function.preg-replace'>function.preg-replace</a>]: Compilation failed: unknown property name after \P or \p at offset 7 in /xxx/literature/includes/include.inc.php on line 2784
        [17-Dec-2008 12:25:30] PHP Warning:  preg_replace() [<a href='function.preg-replace'>function.preg-replace</a>]: Compilation failed: unknown property name after \P or \p at offset 11 in /xxx/literature/includes/include.inc.php on line 2787
        [17-Dec-2008 12:25:30] PHP Warning:  preg_replace() [<a href='function.preg-replace'>function.preg-replace</a>]: Compilation failed: unknown property name after \P or \p at offset 10 in /xxx/literature/includes/include.inc.php on line 2791
        [17-Dec-2008 12:25:30] PHP Warning:  preg_replace() [<a href='function.preg-replace'>function.preg-replace</a>]: Compilation failed: unknown property name after \P or \p at offset 7 in /xxx/literature/includes/include.inc.php on line 2794
        [17-Dec-2008 12:25:30] PHP Warning:  preg_match() [<a href='function.preg-match'>function.preg-match</a>]: Compilation failed: unknown property name after \P or \p at offset 17 in /xxx/literature/includes/cite.inc.php on line 176

        Interestingly there are errors for both preg_replace (include.inc.php) and preg_match (cite.inc.php)

        Perhaps we need to file a bug report with php?

        Thanks,
        Adrian

         
    • Matthias Steffens

      Hi Adrian,

      thanks for the detailed follow-up.

      From your error messages I gather that the Unicode properties which get used (for a refbase UTF-8 system) in variables '$dash' and '$upper' (in file 'includes/transtab_unicode_charset.inc.php') cause problems.

      In PHP 5.2.7, the PCRE engine got upgraded to version 7.8 which in turn had soem changes to the handling of Unicode character properties.

      http://www.php.net/releases/5_2_7.php
      https://sourceforge.net/project/shownotes.php?group_id=10194&release_id=624398
      http://pcre.org/changelog.txt

      As your testing (thanks!) suggests, this seems to be an issue with either PCRE 7.8 and/or PHP >5.2.6/Apache.

      Also, it seems as if others are seeing this issue as well

      http://www.google.com/search?as_q=PHP&btnG=Google-Suche&as_epq=Compilation+failed+unknown+property+name+after+P+or+p+at+offset

      and some have already filed bug reports:

      http://bugs.php.net/bug.php?id=46779
      http://bugs.php.net/bug.php?id=46800
      http://bugs.gentoo.org/238127

      Unfortunately, I have no sysadmin control over the refbase demo servers or my institute's refbase server. So I'm not able to install PHP 5.2.8 there. I can try to install it locally but (due to some other dependencies) this may take some time, sorry.

      According to the notes at the end of PHP bug #46800, the issue has been resolved in PHP 5.3. Let's hope that this is the case.

      Matthias

       
      • adrianbj

        adrianbj - 2008-12-17

        Hey Matthias,

        Looks like this one is on the money:
        http://bugs.php.net/bug.php?id=46800

        I replaced my 'main/php_compat.h' file with the latest version from the cvs (http://cvs.php.net/viewvc.cgi/php-src/main/php_compat.h?view=log), then recompiled php 5.2.8 and everything is working fine again.

        Hopefully this might be of help to others waiting for 5.2.9 to solve the problem.

        Cheers,
        Adrian

         
    • Matthias Steffens

      Hi Adrian,

      thanks for the info. I'm glad to hear that you could solve this issue, and I'm sure this will be helpful for others.

      Best, Matthias

       

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks