How to localize pimcore? - pimcore

I need to localize pimcore .I have read the help on that, from the pimcore wiki:
http://www.pimcore.org/wiki/display/PIMCORE/Website+Translations
But i don't get it(since i am a newbie to development or what ever it is i'm doing!!).
It says something about registering locale in php file named action.
it seems so complicated .
Can anybody help?

It is pretty easy to localize your website actually.
First add all languages you want to support, this is done in the admin panel by going to Settings -> System, expand "Localization & Internationalization" and there you will have textbox for adding languages. Enter all languages and the press "Save" at the bottom right.
Next step is to add the translations, this is done by opening the Extras -> Translations -> Shared Translations in the admin panel. Press the + at top to add a word or sentence used for translation, give it a name and then enter the translation for all chosen languages:
Time to code, in your view or layout files (for example: /website/views/scripts/default/default.php), where you want a translation add the following code:
<?php echo $this->translate("hello"); ?>
Set the language of the documents, this is done by opening a document in Pimcore admin, go to the tab "Properties", and on the right side there will be a language setting, select the language for this document and press "Save & Publish":
Now when you navigate to this document (or look at the preview tab) you will see your translated word where you placed the translate code.
Translate the Admin UI
To translate the Admin UI, go to Extras > Download System Languages in Pimcore, and there press the "+" on the language you want to download. To add to those translations you go to: http://www.pimcore.org/en/community/translations. (Read more here: http://www.pimcore.org/wiki/display/PIMCORE/Translations)
You then choose which language to use in the admin UI by going to Settings -> System and then expanding the "General" section, and there you will find "Default Language in Admin-Interface:".

Related

How to exclude some directories from "Analyze -> Inspect Code" in Android Studio?

One code directory is from a long working library, but the code inspector complains about many issues in it. How do I exclude it from analysis?
I've tried looking at the settings, and also tried right clicking on various things through the analysis.
I'd like the code inspection to work for most of my project, but not from parts of it that work and analysis is unneeded. In this case, it is a complex open source C language library where I do not want to touch the code.
Okay - I feel a bit dumb, but so others don't have to go through this, here are details. Also, it is very easy to screw this up - the Android Studio GUI will let you do stuff that looks good in the dialog, but doesn't work. It took me several tries to find the magic that works.
Here is the procedure:
From the main menu, select "Analyze" then "Inspect Code"
Click the button next to "Custom Scope"
Click the three dots button - to the right on the same line. A new dialog will pop up.
Click the plus ( + ) - upper left, to start a new Custom scope
Give it a name
Select "Local" or "Remote"
In the drop-down of the new dialog, select Project view
Of the four icons, click them until only the one for file display is emphasized
Find the top directory of what you want to analyze, and click "Include"
Find each directory you want to exclude, and click "Exclude" for each
Click OK - the custom scope dialog will close
Click OK - the analysis will run
In the future, that scope is available by name, but remember that it does not honor the implied scope if you right-click a directory in the hierarchy.

Roku SceneGraph with Search Functionality

I'm creating a Roku app in SceneGraph and trying to near duplicate the search functionality I had using the old SDK. I'm stuck at only being able to display the mini keyboard. I'm trying to add buttons via buttongroup (i.e., Search, Cancel) but having two issues:
Not sure how to get the text string that's typed into the mini keyboard and store that in a variable or field so I can perform the search on it.
How to create a Search button and give it focus when user is ready to search for the string they entered.
Any help would be appreciated. Thanks.
SGDEX (Scenegraph Developer Extensions) is what you need. They have a view called "SearchView". Look it up.
Also...
RALE (Roku Advanced Layout Editor) has good search options. - I have been unable to find a decent Search sample. It would be cool if we could export the source code from RALE.
However if you haven't tried RALE. You could upload your script, then add search to it.

How can I add Wolfram Alpha to search bar in Chrome?

I want to send queries to Wolfram Alpha real fast. I've been using wiki query from search bar for ages, how can I search on WA?
Ultimately I found the solution myself, but it took me some time and I had to devise the solution myself, since all Google searches returned the extension which I wanted to avoid. Here it is.
Right click the address bar and click Edit search engines...
(or open Settings -> Search -> Manage search engines...)
Usually, you can find all recognized search engines you used already listed there, but if not, add this: (*use any keyword of your choice)
The query url: http://www.wolframalpha.com/input/?i=%s
Now it is possible to use wa query from search bar to search on Wolfram Alpha. Note, this method allows you to use any search engine.
This is really handy! I wonder if adding it in Chrome as a search engine is better than using the Wolfram Alpha chrome extension though. That is much easier to search using just combination of "=" followed by space and you can directly type in your search query to the Math engine :)
Wolfram|Alpha (Official)
Instantly query Wolfram|Alpha from any page or tab.
There is more to it, you can type formula and equations directly in your navigation bar using this on any page or tab. Pretty neat!
[Source]: From Wolfram Alpha Official Chrome Extension page
===FEATURES===
✓ Wolfram|Alpha Button – Access the Wolfram|Alpha query box with just one click. You can also right-click the Wolfram|Alpha icon to change extension options.
✓ Omnibox Shortcut – Transform Chrome's omnibox into a Wolfram|Alpha query field by typing an = sign followed by a space.
✓ Context Menu Shortcut – Highlight text to create queries through a context menu (right-click) entry.
Shouting out to StackOverflow community:
I am still learning and appreciating the power of this engine. If you guys have some resources or content apart from Wolfram's official site, please do share!
This will really help me as a beginner in the field and I can use to improve.
What better way to search than the famous Euler's Identity. In Chrome Nav bar
"=" ==> (space) ==> e^(i*pie) ==> (enter)
Or something like:
"=" ==> (space) ==> sqrt(1779)*cube(pi) ==> (enter)
And see the result instantly in Wolfram. Awesome isn't it?

Contextual menu Mac OS X - Pasting a text string

I would like to know if it is possible to set up a contextual menu option that allows me to select a string, e.g. from BBEdit or TextEdit etc., and after selecting it > right click > call Contextual menu item > Paste/Replace with string of text.
For example, if I had a text file open and wanted to select the word "blue" I would like the contextual menu item to be able to replace that with "red."
Yes, this is like copy and pasting, but there's a reason I am asking for this specifically and it would save me tons of time at my job.
I am not an experienced programmer, so consider me to be a complete newbie.
I want to do this in Automator. I know all the steps to get to the building part, just don't know which Utilities item to use for something like this.
I did figure out how to do it with a keyboard shortcut, though I'd also like to have a universal right-click contextual menu option. I used to use some app to do this for me in the old days.
Here's what I did. Go to Automator, select "no input" and "any application" above the actions window.
On the left, click on Utilities, drag "Run AppleScript" into the window on the right.
Insert, into the middle:
tell application "System Events"
keystroke "Text You Want To Input"
end tell
Save it, then go to System Preferences » Keyboard » Keyboard Shortcuts > Services, and find your saved title. Create a keyboard shortcut.

How to place todo reminders in Dreamweaver code

I am coding in Dreamweaver for a change. Is there a way to place reminders in your code, for example in the form of a "todo list"?
I know Eclipse has this option. You can place //TODO before the line of code and the marker is placed in a list. You can view this list at will and conveniently go back to the exact spot later.
After weeks of coding I sometimes forget to take care of certain things. A todo list in the code itself would really help out, anyone know of a method for this in Dreamweaver?
Dreamweaver doesn't have a dedicated interface for viewing TODO items. However, it does have what it calls Design Notes. These notes are stored in *.mno files that are within _notes folders within the folder of the file that has a design note attached to it. These files and folders are only viewable within Dreamweaver if you have Show Hidden files enabled, which you can do by accessing the Files panel options menu on the upper right by clicking on it, then selecting View -> Show hidden files.
You have to turn them on in the site definition, although by default, a Dreamweaver site will have them turned on. The following steps are for Dreamweaver CS4:
Site -> Manage Sites..., Select the site, click Edit, select the Design notes category, check maintain design notes. Next go to the File View Columns category and make sure that the Notes column is displayed. Click OK then Done.
You can also opt to share these design notes, which means the they will be uploaded when you FTP the files to the remote site, so that others that you work with when they download the file (and assuming they also have Design notes enabled and shared), then they will be able to see that a file has a design note associated with it. Note: These *.mno files are plain text and if you your server may be accessible by others, so be sure not to put anything confidential in them.
In the Files panel, right-click on a file that you want to add a TODO item to, select "Design Notes...". In the interface that opens, you can enter in a free form note for the document. Check the Show when file is opened to cause this interface to open when you open up the file you're applying the design note to.
If you switch to the All Info tab, you can add "keyed" notes, that is a note with a name, and an associated value. This open may be good for TODO items.
When you add a design note to a file and you have the Notes column displayed, you should see an icon in the Notes column for any files that have associated notes for. Double clicking this icon will open up the Design Notes UI. This will be a quick way to determine if you have any TODOs in the files that you can see. Note: you won't see this icon for files within folders that are closed.
If you would like to do some searches or listing of files with design notes associated with them, then you can take a look at the Site Reports Design Notes report. Go to Window -> Results -> Site Reports. In the upper right of this panel, click the green arrow. This brings up the Reports interface. Select the appropriate option under Report on, and then check "Design Notes" under Workflow. Don't bother with the report settings....it's supposed to allow for some search/filtering, but I can't get it not to display all files with notes associated with them, perhaps you'll have better luck. Click the Run button and the Site Reports panel should contain a list of files that have design notes associated with them, as well as the design note info for the file. If you double click the entry, then the file will open.
Well, i use to put a simply comment like this below, directly in the php code:
//TODO: something to do here.
When i need to check my todo list, just search in the site by "//TODO:", and voilá, this is my todo list! It works, it's free and well according with KISS requirements.
Try using doxygen to document your code.
anything marks with a #todo, will be put in a special page when you generate documentaion.
Not ideal but the best i can think of.
(I haven't had much experience with dream weaver - it might have the feature you are looking for IDK)

Resources