Localization error of App in ios - ios

I've followed all the desired steps to achieve localization of application.following are those steps:
create a Localizable.strings file.
add languages which we are looking to localized.
add these in localizable.strings using add localized button.
Now I'm getting following alert message :
fatal: index file smaller than expected"
along with this the Localizable.strings file is not appearing in the list which asks about the reference file and resource language.anybody please help me as soon as possible.
Thanks in Advance.

This seems to be like a git error which can be fixed by removing .git/index and then reset to HEAD.
You can find details here:
http://programertools.blogspot.com/2014/04/how-to-fix-fatal-index-file-smaller.html

You can follow this Localization link .
Hope this helps

The index file has become corrupted, but it is easily re-creatable. Just remove it, and re-add the files in your working directory:
rm .git/index
git add .

Related

Edit plist file in swift (not in bundle)

beginner in Swift here.. I've already tried to look it up, but couldn't find an answer that worked.
I'm trying to write a macOS app, and I would like to know how to edit a plist file programmatically that is on the system but not bundled in the app.
Let's say, for example, we have a "contents.plist" file which is located in a folder in the system, and I want to access this file, then add keys and dictionaries to it, and save the changes in that file.
Any idea on how can I do that programmatically with swift ?
Thank you !
EDIT : PropertyListSerialization worked ! Thank you vadian 🙏
what I did to modify my external plist was to define a path in a constant and access it using FileManager.default.contents(atPath: myPath) instead of Bundle.main.path ..
Then use .add methods and .write to edit the plist .

'libxml/xmlversion.h' file not found with <angled> include; use "quotes" instead

These kind of error are showing in the 16 files.
When i am going to change then its showing the pop-up
or click on unlock
My question is this -
How to unlock this file to editing ?
You get the code from git through Download Zip. Try git clone to download the code.
Like the message box says, find the files in Finder and right click them. Modify their permissions to be writable.

iOS Facebook SDK localization

I am trying to change text in FBLoginView button but I have no luck so far. I've tried to read README from FacebookSDK and look at internet. I added 2 languages in project Localizations sections it creates 2 files in Supporting files for each language but I tried to change strings in there with example content of README (with changed string values) but even if I changed english file I always get default login string.
Then I tried to add some Bundle settings and change some files in there but with no luck too. Can someone tell me how can I achieve change facebook strings step by step? Thanks
Update:
The method described here is no longer applicable for the latest Facebook SDKs. So please refer to the answers given by #Erik van der Neut or #Ted, and use the bundle FacebookSDKStrings.bundle that ships with the SDK for string overrides.
The only way I found so far to localize/change the Facebook strings is described in their FAQ: https://developers.facebook.com/docs/ios/troubleshooting/
What I did was to copy the file FacebookSDKOverrides.bundle from the Scrumptious sample project that ships with the Facebook SDK. This is basically just a package that contains (can contain) different localization folders. If you want to add German strings, create a folder de.lproj within the bundle. This folder should contain a file Localizable.strings.
You can find a list of all overrideable strings in the file FacebookSDKResources.bundle.README. You can find it in the FacebookSDK folder:
FacebookSDK.framework/Resources/
or here: https://github.com/facebook/facebook-ios-sdk/blob/master/src/FacebookSDKResources.bundle.README
To add a German translation of the text of the login button, for example, you have to add the following to the file Localizable.strings in de.lproj:
"FBLV:LogInButton" = "Einloggen";
As a last step, you have to make sure that Facebook knows about the bundle. Therefore, you can add the following to your Info.plist:
<key>FacebookBundleName</key>
<string>FacebookSDKOverrides</string>
Alternatively, you can also specify this in code if you want to:
[FBSettings setResourceBundleName:#"FacebookSDKOverrides"];
This worked for me, although I would like to use my main bundle for overrides and just specify them in my normal app translations. This would come in more handy for the connection to translation tools as you don't need to translate multiple files per language.
As of Facebook SDK 4.9
If you have downloaded the Facebook SDK, theres a bundle named "FacebookSDKStrings.bundle"
add FacebookSDKStrings.bundle to your project
make sure you enable Base Internalization as described in Apple's documentation.
As an update to the accepted answer here from Flo:
For the latest Facebook SDK, the set of Facebook messages (and their identifying keys) has completely changed. For example, the "FBLV:LogInButton" key is no longer valid in the latest Fb SDK.
Because of this my Facebook strings were no longer getting localized, until I realized this and replaced all my Facebook messages with the latest FacebookSDKStrings.bundle (v4.2) from https://github.com/facebook/facebook-ios-sdk -- I simply removed my original FacebookSDKOverrides.bundle and included this whole bundle FacebookSDKStrings.bundle as is in my project (including the Resources sub folder in there), updated my project .plist files to point to it, and with that all the Facebook strings got localized again.
For example, the message for the default Login button label now looks like this:
/* The long label for the FBSDKLoginButton when the user is currently logged out */
"LoginButton.LogInLong" = "Log in with Facebook";
Luckily, Facebook's GitHub page now includes translations for these messages for lots of languages already (which in my case meant I no longer needed to run these past my translators).
I just copied all string from "FacebookSDK.strings" from folder of langauge you want like fr.lproj to my poject Localizable.strings (French) ...This way worked for me...

Localize Wix Bundle Bootstrapper

I localized file hyperlinkthemt.wxl (pl-pl). But my bootstrapper just shows up and then disappears in a second and nothing more happens. I was trying to solve the problem and noticed that I can't use polish letters in hyperlinktheme.wxl.
Is there any way to change that. I was trying to do something with HyperLinkTheme.wxl:
<WixLocalization Culture="pl-pl" Language="1045" xmlns="http://schemas.microsoft.com/wix/2006/localization">
but it didnt help. As you may know for bundle projects one can't change localization.
There will be a log file in your %TEMP% folder that should show a little more detail what is wrong. Chances are the .wxl file is not saved in UTF8 and cannot be loaded.

Adding a button in django !

I wanted to add buttons or a url adjacent to "ADD CUSTOMER" button as shown in the image. Please guide me regarding the same.Where should i be making the necessary changes ?
please find the image here >> http://img138.imageshack.us/img138/170/query.png
Thank you
You add buttons/make changes in the html file, or your CSS file if you have one. If you're using Django make the changes in the /templates directory of your project, its the directory that contains the html files.
In this case what you are looking at is the admin site. The templates for this are located somewhere like "python-path/lib/site-packages/django/contrib/admin/...", but you can override these templates in your project. I'm not sure how easy it is to do what you're trying to do, but you can see this link for more information.

Resources