Could it be possible to remove "Title" from the label display?
Let me give you a brief example why I need this:
I am using the link field to provide the a client's name and website inside a project content type. In the node form, the label for the link field shows "Client title:", which some users would understand as "Mr, Sir, whatever...". It would make much more sense if we could use a custom string, and then show something like "Client name:" or simply "Client"
This is aggravated when we use other languages. In Spanish, for instance, both words are in the wrong order, and generate meaningless information. (I have tried using the String overrides module to get around this, but to no avail)
This issue is may be related to #1178064: Change "title" label and "url" label on field settings
Comment | File | Size | Author |
---|---|---|---|
#11 | 1266474-d7-2.patch | 2.29 KB | redndahead |
#9 | link-translatable_sublabels.patch | 802 bytes | franz |
Comments
Comment #1
jcfiala CreditAttribution: jcfiala commentedYeah, this issue is directly related to #1178064: Change "title" label and "url" label on field settings, so I'm going to close it as a duplicate. I suggest you use the code snippet from that ticket as a guide for changing how that's displayed.
Comment #2
castawaybcn CreditAttribution: castawaybcn commentedThanks for pointing me to the solution, will check it out asap.
Comment #3
markabur CreditAttribution: markabur commentedHow would this work for Drupal 6? #1178064: Change "title" label and "url" label on field settings uses hook_element_info_alter() which is D7 only.
Comment #4
dqdDue to the mass of repeating feature requests regarding the additional title field, the title field teeters on the brink. I would like to provide some info here about how you can reach your goal:And e viola, here is your link field with a title which supports all the features, which are combinable with text fields like, tokens, html markup, translation and many more. You can even have 20 titles if you want. Or one title for 5 links?It seems that we decided to leave the title field in (other issue discussion). So this comment here is confusing, that's why I -del- it.
Comment #5
dqdtagging
Comment #6
castawaybcn CreditAttribution: castawaybcn commentedSorry if I am not getting this right, but field collection is for D7 only, and although I have not used it I think it affects the output of the field, not the form, which was the original reason for opening this issue.
Comment #7
dqdcastawaybcn, Yes thats right. field_collection d7 only. I had to -del- the above comment to prevent confusion, but from reading trhu' it and yours and this here, the meaning gets clear.
I still have one other question, is there a d6 solution out there to style your forms like in d7 with DisplaySuite ?
Comment #8
castawaybcn CreditAttribution: castawaybcn commentedIn D6 the only styling I use is the one provided by vertical tabs, which as I understand made it into core in D7. A quick search returned the Arrange Fields module, but I haven't tried it myself.
Comment #9
franzRegardless of what is said, it is a terrible practice for i18n to just "glue" strings like if all languages would use them in that order ([label] Title). As I'm translating a D6 site and spent a long time trying to find where I had to go in and change this. Unfortunately, translating the terms separatedely just won't be enough. This patch makes the string translatable as "@label URL" and "@label Title".
Comment #10
redndahead CreditAttribution: redndahead commentedI'm going to throw my hat into the ring with a completely different approach. I can see that these type of requests have been batted down for one reason or another, but I think this approach may work.
This patch adds a checkbox that makes the field label become the label for the Title field. It will then hide the field label. This allows the string to still be translatable and if one needs a larger wrapper they can use fieldsets to accomplish that.
Comment #11
redndahead CreditAttribution: redndahead commentedThe previous patch had issues showing error messages and the default value was set incorrectly. Since there is a nice option to set the label to invisible this patch utilizes it.
Comment #12
RobLoachComment #13
dqdAfter seeing RobLoachs reply, I've also tested it and it works here without any issues as well ... I'll push it against latest link-7.x-dev. Will be up next days. Feel free to re-open the issue if I missed any flaw by testing ...
Thanks to all.
INFO: I removed the random issue tags "link module title text field", since these tags are random and not needed. Before adding tags read the issue tag guidelines. Do NOT use tags for adding random keywords or duplicating any other fields. Separate terms with a comma, not a space.
Comment #15
dqd