How to develope multi language OpenERP module in OpenERP 7? - openerp-7

I want to develop a module that should support two languages
How to make OpenERP multi language
1-English
2-Dari
with links to change the language from one to another
I am new to OpenERP development please help me with practical sample codes and explanation.

First of all if the second language you want to support in your module isn't already loaded to OpenERP you have to load it.
To do so, you have to go to "translations" -> "load a translation" in the settings menu, and load your second language.
Then in your module code, do the following import in your py files:
from openerp.tools.translate import _
Then continue developing you're module... When you're done developing you can start translate it!
First, export the po file.
To export the po file, go to "translations" -> "Import/Export" -> "Export translation" under the "Settings" menu. Choose the language you want to translate to, the format of the file to translate (you should select "PO") and the name(s) of the module(s) you want to translate.
Click the "download po file" and save it to your computer. Keep all the "msgid" strings as they are (better, don't touch anything but the "msgstr" entries!) and translate all "msgstr" to your language.
You're almost done!
In your module, create a folder named "i18n" and put there the po file you just edited. Upload the folder with the PO file in it to your server, and update your module. You're module should now be translated and displayed in the new language to users who have that language selected in their profile.
Hope this helped!

Related

How can i change text and links in the header part?

Please how can i change text and links in the highlited zones in the picture below :
Click to see
Thanx a lot
Prestashop comes with a translation mechanism. Usually from your Prestashop backend, navigate to Localization > Translation, then identify "Modify Translations ". Select the type of translation, the theme and the language and hit on the button "Modify" on the right hand side. Look for any module in the front office translations group that contains "search".
Your situation may be a little be different because you are not using the default theme. You theme developer has probably created a new quick search module. You would need to identify the actual module and it should be easy to identify it from the list of translatable module. If the module is not well developed, it will not be possible to modify them. In that case, you should ask your theme developer.
I hope it help. Good luck with your business.

Issue on using "scrolling text" module in Joomla

I have downloaded and installed various module for scrolling text horizontally using these websites.
After I created new module and point out the position of that module, I can view that module in my web page. The text didn't appear because I didn't mention it in my module.
In Both of those modules, I couldn't find out that where have to I place the text to be scrolled in that particular modules?
I have searched a lot. But I couldn't get anything.
Any help will be appreciated!
Thank you in advanced!
These extensions display text from articles. So all you have to do is simpley:
Create a category in the Content Manager
Create some articles and assign them to your newly created category
In the Module settings, there will be an option to choose which category you wish to display the articles from, simply select your category
Hope this helps
There is no need of using any other modules for scrolling the text.
I used Custom HTML as menu type and write the code on editor.
The steps I have done as below:
Go to site -> Global configuration -> set Editor-None in default editor
Go to Extension-> module Manager -> New -> select the module type as Custom HTML
Copy the html code for scrolling text and Paste it in the text part and save the module.
Check your site. Now, your site is having the scrolling text. Then, You can change the Editor as before.

How to automate or programmatically make changes to System Preference settings on Mac OS X

I am trying to figure out how to programmatically change System Preference settings on the Mac OS X. If that is not possible, create some post-installation automation script (using Apple Script or other means) and run it as part of the installer. I am particularly interested in making changes to the "Language & Text" settings which are part of the "personal" settings in System Preferences.
Here is more description of my problem:
I am trying to create an installer for a custom keyboard layout I wrote for Mac OS X. The keyboard layout basically allows people to transliterate ASCII keboard input to foreign letters. The foreign language does not exist on Mac OSX*. I was able to use Apple's PackageMaker to create a basic installer that dumps all the necessary files (.keylayout file, icons and the custom fonts) in their respective directories in the target computer. But there are a couple of personal settings that need to be configured in System Preferences before the keyboard layout can be selected and used. I would like to auto-configure these "one-time" settings for the user during the installation process. Is it possible to make changes to the settings using Cocoa/Objective-C. If not, I would like your help on how I can use Apple Script to automate the configuration. Please include some sample code or pointers to examples if possible. Thank you.
Here are the settings that need to be configured on System Preferences
Select System Preferences --> Language & Text -- Input Sources
Select "The Language Name" from the list
Click on "Keyboard Shortcuts" and enable "Select the previous input source" and "Select next source in Input Menu".
Double click on the shortcut combinations "⌘ space" and change them to "⌘ L" for the "Select the previous input source" and "ctrl⌘L" for "Select next source in Input Menu"
Exit systems preference. Done
NB: *The system language need not be changed. Only the input source (keyboard layout).
See NSUserDefaults. The values you want to set are probably in NSGlobalDomain.

IntelliJ IDEA - New Template

I'm trying to create a set of custom file templates for IntelliJ.
I basically want to go right-click, "New > My File Template" similar to the "New > Java Class" bundled with IntelliJ.
I've added my own custom file template via "Settings > File Templates", but they don't appear in my "New" context menu.
This is a Java project, and my templates extension is java. Am I missing something?
All help greatly appreciated.
No My Template >>>
If you select Java Class you can then choose the template for your new class. This is a new feature, it used to be available when selecting New.
Actually you can, sort of.
I don't know know how to do it for Java files. but
if you set the extension to txt you it will show up in the right click menu.
and here it is in the menu:
the only issue is if you're creating a java class you'll have to rename the file after creation to ${name}.java

WIX adding shortcut to a website or url location using wix and choose custom icon for that shortcut

I want to add a shortcut to the start menu group with following specifications:
It should point to a website, say www.xyz.com
It should have some custom icon
I need to pass some parameters to it, like www.xyz.com?lang=XXXX.
Where XXXX is language code e.g. 1033, 1036, etc. and it's dependent on the language chosen by the user for my application.
Please help.
if the website is always the same you could try including one shortcut.url inside your package for each language that you support and install only the one for that specific language on the disk.
this way you could also control the shortcut that gets used for the .url file.
I found a work-around for this problem.
I made an executable which parses stored language and then calls ShellExecute to start the default browser with required url and language option. I added a shortcut to this executable in the start menu, icon was included in the executable itself.