If the downloadcounter shows one or more downloads, i get this message:
* Notice: Use of undefined constant LANGUAGE_NEGOTIATION_NONE - assumed 'LANGUAGE_NEGOTIATION_NONE' in _pubdlcnt_language_prefix() (Zeile 1382 von /home/www/----/html/dev/sites/all/modules/pubdlcnt/pubdlcnt.module).
* Notice: Use of undefined constant LANGUAGE_NEGOTIATION_NONE - assumed 'LANGUAGE_NEGOTIATION_NONE' in _pubdlcnt_language_prefix() (Zeile 1382 von /home/www/----/html/dev/sites/all/modules/pubdlcnt/pubdlcnt.module).I think there is just a language string missing. I am using Drupal 7 with german language.
| Comment | File | Size | Author |
|---|---|---|---|
| #15 | pubdlcnt-language-negotiation-1021370-15.patch | 598 bytes | uhkis |
| #14 | pubdlcnt.patch | 636 bytes | AmbikaFR |
Comments
Comment #1
pixture commentedlanguage negotiation stuff seems to be changed with D7. Since I've been testing it with English only D7 environment, I did not notice it. I will be looking into it. Meantime, change the code below should temporary fix the issue.
Before
After
Thanks,
Comment #3
Dalabad commentedThanks, the fix works fine.
Comment #4
olamaekle commentedThanks. Worked for me too.
Comment #5
resist commentedThank you, works for me too.
Comment #6
emnzava commentedIt doesn't work on my side. I looked at the file and it seems to be updated with the patch but still problem persist.
Regards
Comment #7
white_pawn commentedLANGUAGE_NEGOTIATION_NONE is a D6 leftover. The same variable is called LANGUAGE_NONE in D7. Just rename it and it should work.
Comment #8
white_pawn commentedComment #9
hgneng commented@white_pawn
I think renaming LANGUAGE_NEGOTIATION_NONE to LANGUAGE_NEGOTIATION_DEFAULT may be a better way.
Reference:
http://api.drupal.org/api/drupal/includes%21language.inc/7
Comment #10
phthao commentedI Thank #pixture!
Comment #11
philyThanks, that works.
But then, on the report page: http://website.dev/admin/reports/pubdlcnt
the "Detail" link url displays the default language prefix: http://website.dev/fr/admin/reports/pubdlcnt/counter/xxx.pdf
when it shouldn't: http://website.dev/admin/reports/pubdlcnt/counter/xxx.pdf
And the same occurs for "Title", "Field Name" and "Reset" links.
Could that help fixing something?
Comment #12
nothinghere commentedPatch in #1 seem to fix the issue for me ! Thank you !
Comment #13
warmth commentedAny news on this issue?
Comment #14
AmbikaFR commentedI a attach a patch with my answer. It replaces LANGUAGE_NEGOTIATION_NONE to LANGUAGE_NEGOTIATION_DEFAULT.
Regards,
AmbikaFR.
Comment #15
uhkis commentedFixed patch. Same as #14 but applies from the module's directory as it should.
Comment #16
nicolas bouteille commentedErrors go away thanks to your patch !
Applied manually though. Might need to be tested with GIT before RTBC...
Comment #17
nicolas bouteille commentedsorry I selected active instead of needs review after changing my mind about marking RTBC