Thank you Klas!
That was excellent input and I managed after few trial&errors to find a recipe that works for me:
- Create language overrides
- Add definitions in template index.php, just above the HEAD
<?php
JText::script('PH_ARTICLE_TITLE');
JText::script('PH_ARTICLE_LABEL1');
JText::script('PH_ARTICLE_LABEL2');
...
?>
</head>
- Add a simple code snippet in Script (JS) of the field
$("#art_title_backend").attr("placeholder", Joomla.JText._('PH_ARTICLE_TITLE'));
Similar code can be placed in other text fields, inserting/substituting just the field name and the override string.
P.S. Of course, since there is no need to duplicate override strings, it is perfectly ok to use COM_CCK_strings. However, as placeholders our labels can contain additional explanations, examples and so on.