This module (which would still be in Beta, obviously) allows users to translate book pages in any given language, withouth adding the translation to a new book outline.
When viewing the translated node, the module checks wether the original node is in a Book outline, reconstructs the Book navigation (Book navigation in block and in node footer). It then uses this navigation tree to construct a new one with links to the translated nodes, in identical order. It then shows this tree in the footer book navigation and inside a new Book navigation block.
Thus, we have a fully multilingual book, with just one outline to manage.
This module came to be because we wrote some custom code for a client who wanted to translate the entire site's content in 6 different languages by importing CSV files. Because the book module is heavily used, creating a new outline for each language was not really an option. It had to be done automatically, and the client only had to manage one outline. It is still in alpha though, as the site won't launch before a few months.
We hope this will help some other people.
Kind regards,
Wouter Admiraal
| Comment | File | Size | Author |
|---|---|---|---|
| #7 | i18n_book_navigation.zip | 5.37 KB | wadmiraal |
| #4 | i18n_book_navigation.zip | 4.8 KB | wadmiraal |
| #1 | i18n_book_navigation.zip | 4.12 KB | wadmiraal |
Comments
Comment #1
wadmiraal commentedHere it is.
Comment #2
avpadernoHello, and thanks for applying for a CVS account. I am adding the review tags, and some volunteers will review your code, pointing out what needs to be changed.
Comment #3
wadmiraal commentedUp !
No one interested in a module that handles book translations effectively ?
Comment #4
wadmiraal commentedNew version, with some better memory usage.
Hope someone will take the time to review this. I really think it can be very helpfull for many people with multilignual websites out there. Just one book outline to manage, for as many languages as you want !
Comment #5
svendecabooterIn short:
- change hook_menu:
- add i18n_book_navigation.admin.inc and move function _i18n_book_navigation_settings_form() there
- at the end of _i18n_book_navigation_settings_form(), use
return system_settings_form($form);instead ofreturn $form;- remove function _i18n_book_navigation_settings_form_submit() as it's obsolete now
Kind regards,
Sven
Comment #6
avpadernoI am changing status as per previous comment.
Comment #7
wadmiraal commentedHi Sven, and thanks for the review and tips.
Here's a new version with the changes you suggested.
Comment #8
wadmiraal commentedUp...
Comment #9
wadmiraal commentedUp...
Comment #10
wadmiraal commentedUp again...
Comment #11
drupalshrek commentedHi,
Yes, it's quite quiet here I know. I'm just doing a bit of basic module review whilst...waiting to have my module reviewed.
A couple of things I noticed:
a) module should include a README.txt. This for me is the most important file because 90% of users won't be able to read the code. I'd suggest to look at other README.txt files to see what they include. I would suggest: what the module does, how to install [assume yours is the first module anybody has ever installed], how to administer, how to use.
b) I see you use t() on #title strings:
I don't think this is needed. Can anybody else clarify?
Comment #12
avpadernoForm field titles need to be passed to
t(); it's the menu titles and descriptions that don't need to be passed to that function.The README.txt file is preferable, but it is not required (nor is it reported in http://drupal.org/node/539608).
Comment #13
wadmiraal commentedThanks to both for taking some time :-).
I hope to get back to reviewing some modules as well, but I'm really busy lately.
Comment #14
drupalshrek commentedHa, ha! Yes, that's the problem. We're all busy folk. Too many folk who want their module reviewed and not enough who want to give their time to reviewing :-(. Hooray at least for kiamlaluno!! If it weren't for him, I think this queue would pretty much stop.
Comment #15
WebNewCastle commentedDitto on the Kudos for Kiamlaluno. Awesome work and commitment. :-)
Comment #16
wadmiraal commentedI should mention that this does not work with node access modules (yet).
Meaning, links to nodes for which the user has no access rights will be visible (but obviously it will see an "Access denied" message when clicking). This will be in the to do list as soon as the CVS account get's approved. The thing is it rebuilds a menu tree from scratch, so node access modules are not aware of it (yet).
Cheers to all.
Comment #17
avpadernoWelcome on board!
Comment #18
jvieille commentedsubscribe
Comment #19
wadmiraal commentedProject created.
Go to the project page
Comment #22
avpaderno