Parse error: syntax error, unexpected T_STRING in /sites/all/modules/i18n/i18n.module on line 940

Comments

bkosborne’s picture

Anyone else experience this? I'm wondering if I should wait to upgrade.

druplicate’s picture

Haven't gotten that far, but after upgrading, my Acquia-Marina Block admin page switched to my admin theme, Root Candy, and I lost control over my site's blocks.

ROLLBACK!

jose reyero’s picture

Status: Needs review » Postponed (maintainer needs more info)

There are some problems with the upgrade, #905428: Multiple issues with i18n variables: wrong multilingual variables, cache rebuild, etc..

This parse error seems a new one though, actually that line is a comment. Please, check you've got the full i18n.file.

dthd’s picture

I also got problem with i18n after upgrading this module to the version 6.x-1.6
Here is the problem

warning: include_once(sites/all/modules/i18n/i18ntaxonomy/taxonomy.pages.inc) [function.include-once]: failed to open stream: No such file or directory in /home/davcomv1/public_html/includes/theme.inc on line 283.

warning: include_once() [function.include]: Failed opening 'sites/all/modules/i18n/i18ntaxonomy/taxonomy.pages.inc' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/davcomv1/public_html/includes/theme.inc on line 283.

I could not see the gallery slideshow anymore.

I appreciate any help.

Thanks.

david lesieur’s picture

Status: Postponed (maintainer needs more info) » Needs review
StatusFileSize
new1.24 KB

This patch makes sure that i18ntaxonomy-related menu and theme registry entries are set with the right include file path. That solves the issue for me.

david lesieur’s picture

Oops, had not read the whole thread carefully enough... The patch solves the "Failed opening 'sites/all/modules/i18n/i18ntaxonomy/taxonomy.pages.inc'" problem, but probably not the problem originally posted.

jose reyero’s picture

Title: After upgrading getting page with following » After upgrading getting "Failed opening 'sites/all/modules/i18n/i18ntaxonomy/taxonomy.pages.inc"

Let's switch the issue. About the original one, it seems one person with a broken file.

About this taxonomy issue, the patch looks good. I don't understand why it stopped working though. (Core update?, ctools?)

If anyone could post what the system has cached for that menu item, that would help us understand which module has taken over that menu item (?)

david lesieur’s picture

Looking back at the patch, I'm not sure that the changes to the 'file path' properties are absolutely required. Those could be useful only if some other module had also tried to override the taxonomy term pages.

However, the include file for theme_i18ntaxonomy_term_page() was clearly wrong (should refer to i18ntaxonomy.pages.inc instead of taxonomy.pages.inc) and the cause for the error.

jwilson3’s picture

I updated from a pretty old version of i18n using drush. Apparently drush doesn't remove old files before replacing them with latest version... so, once i deleted the contents of the i18n folder by hand, and expanded the downloaded tarball from d.o, I refreshed the page, and no longer get this error.

cd /path/to/modules/i18n/
rm *.*  */*.*  */*/*.*
cd ..
curl -O http://ftp.drupal.org/files/projects/i18n-6.x-1.7.tar.gz
drush cc all
svn stat i18n
!       i18n/translations/uk.po
!       i18n/translations/uk-ua.po
!       i18n/i18nstrings/translations/uk-ua.po
!       i18n/i18nstrings/translations/uk.po
!       i18n/i18nviews/translations/i18nviews.de.po
!       i18n/i18nviews/translations/i18nviews.pot
!       i18n/i18nviews/i18nviews.module
!       i18n/i18nviews/includes/i18nviews.views.inc
!       i18n/i18nviews/includes/content_negotiation_filter_handler.inc
!       i18n/i18nviews/i18nviews.info
!       i18n/i18nmenu/translations/uk-ua.po
!       i18n/i18nmenu/translations/uk.po
!       i18n/i18ncontent/translations/uk-ua.po
!       i18n/i18ncontent/translations/uk.po
!       i18n/CREDITS.txt
!       i18n/i18nsync/translations/uk-ua.po
!       i18n/i18nsync/translations/uk.po
!       i18n/i18nblocks/translations/uk-ua.po
!       i18n/i18nblocks/translations/uk.po
!       i18n/i18ntaxonomy/translations/uk-ua.po
!       i18n/i18ntaxonomy/translations/uk.po

lots of file and sub-module changes! :P

david lesieur’s picture

Regardless of jrguitar21's observation, there is clearly an error in i18ntaxonomy_theme(), which wrongly refers to file taxonomy.pages.inc instead of i18ntaxonomy.pages.inc.

If some people do not get any error, that is because i18ntaxonomy.pages.inc often happens to have been loaded by other code in the i18n module before the theme function gets called.

This is a trivial error. Is there anything I should change to the patch to get this committed?

steff2009’s picture

@David Lesieur

"Regardless of jrguitar21's observation, there is clearly an error in i18ntaxonomy_theme(), which wrongly refers to file taxonomy.pages.inc instead of i18ntaxonomy.pages.inc"

I guess you mean i18ntaxonomy_module which refers wrongly to file taxonomy.pages.inc - instead of i18ntaxonomy.pages.inc (as there's no _theme file in the directory).

The correct .module file should be included in the latest i18n release to avoid that users download and install the wrong one.

Cheers.

david lesieur’s picture

@steff2009: I meant "there is clearly an error in the i18ntaxonomy_theme() function".

steff2009’s picture

Ok, thanks David. Do you have any opportunity to include the correct .module file in the download package for future users?

Cheers

YK85’s picture

subscribing

Naiya’s picture

I have downloaded i18n today and still have this error. is there a chance that you correct and commit the inclusion path? it would be very nice :)

Greetings and thanks for Your time!

star-szr’s picture

Version: 6.x-1.6 » 6.x-1.x-dev
StatusFileSize
new463 bytes

New patch attached and bumped to dev.

phryk’s picture

Version: 6.x-1.x-dev » 6.x-1.9

This bug is also in the i18n-1.9 distribution for D6 which is the current "stable" release that came out in March.

I don't see why this isn't getting fixed as it's just 3 measly chars missing in one line…

mathieu’s picture

Component: Code » Blocks

Subscribe.

mathieu’s picture

Component: Blocks » Taxonomy
Status: Needs review » Reviewed & tested by the community
jose reyero’s picture

Status: Reviewed & tested by the community » Fixed

Committed. Thanks.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

tim.plunkett’s picture

Status: Closed (fixed) » Needs review
StatusFileSize
new1.58 KB

Same issue with the menu_alters.

joseph.olstad’s picture

Issue summary: View changes
Status: Needs review » Closed (outdated)