Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#991 2008-10-06 22:27:28

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: MLP - The Multi-Lingual Publishing Pack

Why is it that in the ‘Plugins’ tab l10n has 136 strings, and in Snippets > Search when I search for ‘l10n’ 147 strings are found? And in Export/Import, when I choose ‘Export MLP Pack Strings’, I get a php file with 145 strings…

Offline

#992 2008-10-07 00:49:17

net-carver
Archived Plugin Author
Registered: 2006-03-08
Posts: 1,648

Re: MLP - The Multi-Lingual Publishing Pack

Els

Is this a fresh install? Or has it had more than one version of the pack installed at any point — if so, that will probably account for the difference between the reported plugin strings and the actual number of strings. However, I’m curious about the 147 to 145 difference — wonder what that could be?


Steve

Offline

#993 2008-10-07 13:55:05

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: MLP - The Multi-Lingual Publishing Pack

net-carver wrote:

Is this a fresh install? Or has it had more than one version of the pack installed at any point — if so, that will probably account for the difference between the reported plugin strings and the actual number of strings.

No, I upgraded from 0.7.636 to 0.8.7 (and it has probably been an even earlier version before that, but I don’t remember exactly), then copied the site to local. On the live site I didn’t make any further changes, and there the plugins tab has 111 strings, and snippets > search for l10n has 129. The php file from the export/import tab also has 145 strings.
I finished the translation in the local install, did a cleanup and a re-install there, and ended up with 136/147 strings.
So when I will eventually export the plugin strings to the .inc file, will all strings be there or just 136 of them? I definitely translated 147 strings… ;)

However, I’m curious about the 147 to 145 difference — wonder what that could be?

I’ll try and find the two strings that are missing and post them here. (Edit: see here.)

What is the purpose of the php file by the way? If someone wants to install another language, does he need the .inc file or the php file?

Last edited by els (2008-10-07 19:33:50)

Offline

#994 2008-10-07 16:09:58

azw
Member
Registered: 2007-01-29
Posts: 279

Re: MLP - The Multi-Lingual Publishing Pack

I have a test site that I previously used with the MLP on another project. I don’t need MLP in the new project, so I’ve disabled the MLP plug-in, deleted and reuploaded all the textpattern files, and deleted all references to l10n in the templates (pages, forms, & style sheet).

But I still get this error:

Fatal error: Call to undefined function l10n_get_lang() in /home/SITE_DOMAIN/public_html/textpattern/lib/txplib_misc.php(574) : eval()'d code on line 18

Where is this coming from? Is there a fix?

Yep, I probably should have wiped out my database, but I wanted to reuse the templates.

Last edited by azw (2008-10-07 16:10:28)

Offline

#995 2008-10-07 19:31:24

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: MLP - The Multi-Lingual Publishing Pack

OK I don’t know if this is at all important, but here goes:

The 2 strings that are not in the php file are

l10n-explain_no_tags
l10n-matches

The 11 strings that are not displayed in the plugins tab are

l10n-add_missing_rend
l10n-cannot_delete_all
l10n-email_body_other
l10n-email_body_self
l10n-email_end
l10n-email_xfer_subject
l10n-localised
l10n-missing_rendition
l10n-no_rend_matching_id
l10n-send_notifications
l10n-setup_4_main

Steve, can you let me know if an .inc file with probably these strings missing will be good enough to post in the strings exchange thread?

Offline

#996 2008-10-08 00:38:54

net-carver
Archived Plugin Author
Registered: 2006-03-08
Posts: 1,648

Re: MLP - The Multi-Lingual Publishing Pack

azw wrote:

Where is this coming from? Is there a fix?

Did you remember to replace the file txplib_db.php with an original txp one?

Els

Thanks for the report on those strings. If you have access to phpMyAdmin, you can use that to look at those strings in the txp_lang table (just use a search like 10n-% on the name field to see them all.) Are they missing entries on the l10n_owner field?

You can always export the strings and then paste them into the import box (of another install if you are worried) and hit import — all the strings should be previewed before import so you could then look at what’s included in the actual file.


Steve

Offline

#997 2008-10-08 03:54:12

azw
Member
Registered: 2007-01-29
Posts: 279

Re: MLP - The Multi-Lingual Publishing Pack

net-carver wrote:

Did you remember to replace the file txplib_db.php with an original txp one?

Thanks for the reply, Steve. Yes, I renamed the old directory and uploaded a new copy of all the files in the textpattern folder (except for config.php).

I meant to say earlier that the error mostly occurs when I type in a URL that doesn’t exist on the site.

Any other ideas?

Last edited by azw (2008-10-08 04:04:15)

Offline

#998 2008-10-08 11:01:01

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: MLP - The Multi-Lingual Publishing Pack

net-carver wrote:

Are they missing entries on the l10n_owner field?

You are right of course :) the l10n_owner field was empty for those strings. I filled them in phpMyAdmin and now all 147 strings are there in the plugins tab.

Offline

#999 2008-10-08 11:29:47

kvnmcwebn
Member
From: Ireland
Registered: 2007-01-27
Posts: 724
Website

Re: MLP - The Multi-Lingual Publishing Pack

==========
Warning: Table ‘domain_com.l10n_txp_es_es’ doesn’t exist REPLACE INTO l10n_txp_es_es SELECT * FROM textpattern WHERE textpattern.ID=‘29’ LIMIT 1 in /nfs/c01/h03/mnt/34978/domains/cosanglas.com/html/textpattern/lib/txplib_db.php on line 117
========

this warning is at the bottom of my admin pages. Everything seems to be working fine though.

Last edited by kvnmcwebn (2008-10-08 11:30:11)


its a bad hen that wont scratch itself.
photogallery

Offline

#1000 2008-10-08 13:39:07

net-carver
Archived Plugin Author
Registered: 2006-03-08
Posts: 1,648

Re: MLP - The Multi-Lingual Publishing Pack

azw

It has to be coming from either the l10n plugin, one of the files it put in the /lib directory or from the txplib_db.php file. AFAIK, that function isn’t called by other plugins and certainly not by straight TXP. The only other option would be a straight call to it from within a <txp:php> block within a page or form.

Els

The big question is now how did those strings end up with blank owner fields? Hmm.

Kevin

Thanks for the notice. Looks like Spanish isn’t properly installed on that site. How did you add es-es to your installation?


Steve

Offline

#1001 2008-10-08 13:48:01

kvnmcwebn
Member
From: Ireland
Registered: 2007-01-27
Posts: 724
Website

Re: MLP - The Multi-Lingual Publishing Pack

Kevin

Thanks for the notice. Looks like Spanish isn’t properly installed on that site. How did you add es-es to your installation?

Hi,
Cant remember-just normal install i thought. I had a few plug-ins active during the installation.
The site has become very buggy, i think I will have do a clean install and build the site again. Unless theres something else i could try.

edited to say im just going to do a clean install. And rebuild the site.
Its the first site ive used it on so i might have done something wrong.

Last edited by kvnmcwebn (2008-10-08 13:53:03)


its a bad hen that wont scratch itself.
photogallery

Offline

#1002 2008-10-08 16:48:44

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: MLP - The Multi-Lingual Publishing Pack

net-carver wrote:

The big question is now how did those strings end up with blank owner fields? Hmm.

Would that be caused by something I did or something you did? ;)
Just in case it provides any clues, I looked at the live site’s table (where I only did the upgrade to 0.8.7 and made no other changes as far as I can remember), and there I find totally different strings with empty owner fields.

(Edit: totally OT, but as of today this plugin thread is the only one with over 1000 posts!)

Last edited by els (2008-10-08 18:08:28)

Offline

#1003 2008-10-08 19:54:56

azw
Member
Registered: 2007-01-29
Posts: 279

Re: MLP - The Multi-Lingual Publishing Pack

Alright! I found the problem, Steve. There may be others who have made the same mistake so I’ll detail it here for their reference.

I had installed the wan_error_email plug-in, which would have been fine, except that I had edited it to include this line:

 $mailtext .= "\nhu.l10n_get_lang: " . hu.l10n_get_lang();

That line should tell me which language was requested when the error occurred.

Now that this line is gone, the problem disappeared.

Thanks for your advice.

Offline

#1004 2008-10-08 21:09:23

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,912
Website

Re: MLP - The Multi-Lingual Publishing Pack

Els wrote:

(Edit: totally OT, but as of today this plugin thread is the only one with over 1000 posts!)

Holy crap! This is one thread I will not be reading from start to finish. Likely not many others do either which is probably why it’s so long. :)

Offline

#1005 2008-10-08 21:42:07

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: MLP - The Multi-Lingual Publishing Pack

net-carver wrote:

The big question is now how did those strings end up with blank owner fields? Hmm.

Steve, I found it! I did a fresh install of the MLP Pack (0.8.7dev) in a new Txp install (r2984). I added my l10n_nl-nl_strings.php to the /lib directory before running the install wizard. Exactly 145 strings were found in both the plugins tab and the snippet search tab. No owner fields were empty. Now here’s the strange thing: when I edit a string, save it, and then check the lang table in phpMyAdmin, the owner field has gone blank! Note: this only happens when I edit a string from the snippets search tab, not when I edit it from the plugins tab.
I certainly don’t understand it, but I hope it will give you a clue… If you need more specifications let me know.

Edit: Also this happens: I installed 3 languages on this site, nl-nl, en-gb and pt-pt. So all portuguese strings were missing. When I add a pt-pt translation, not only is the owner field blank but also the event field is ‘public’ instead of ‘admin’. Again, only when edited from the snippets search tab.

BTW: in the l10n_en-gb_strings.php file that is included in the 0.8.7 download, l10n-cleanup_steps occurs twice (line 146 and 160).

Last edited by els (2008-10-08 21:52:48)

Offline

Board footer

Powered by FluxBB