Jump to content

Search the Community

Showing results for tags 'multilanguage tags'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to ProcessWire
    • News & Announcements
    • Showcase
    • Wishlist & Roadmap
  • Community Support
    • Getting Started
    • Tutorials
    • FAQs
    • General Support
    • API & Templates
    • Modules/Plugins
    • Themes and Profiles
    • Multi-Language Support
    • Security
    • Jobs
  • Off Topic
    • Pub
    • Dev Talk

Product Groups

  • Form Builder
  • ProFields
  • ProCache
  • ProMailer
  • Login Register Pro
  • ProDrafts
  • ListerPro
  • ProDevTools
  • Likes
  • Custom Development

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests

Found 1 result

  1. Hello for all, I can't find solution how to manipulate with image tags field (as object) inside admin/edit using hooks. My problem that I need to use multilanguage predefined tags (I like to store pages ID from some another page tree). Also I know that there are other solutions (eg. repeatable field with image field and some page field for tags, or using page table), but in my case I like to use hook inside custom module for that job. I try with InputfieldImage::render, and InputfieldFile::render... but with that I can't get/"touch" values from image tags field. Only working solution what I have right now is using ProcessPageEdit::execute but with that can manipulate only with tags value - is there any other better elegant solution to manipulate with image tags field (as object, as example set class, add readonly attribute, append some html...)? $this->addHookBefore('ProcessPageEdit::execute', function(HookEvent $event) { $page = $event->object->getPage(); foreach ( $page->fields as $field ) { if ($field->type instanceof FieldtypeImage && $field->useTags) { $imageField = $page->get((string)$field->name); // there are multiple images foreach($imageField as $f){ $f->tags = '...'; // tags value only } } } }); Regards and thanks. EDIT: Now it's clear to me what can be done. With this ("simple" variant) is possible to add class to wrapper, manipulate with value, but for more than that need to override core InputfieldFile module (inside site/modules). Also there is always option to use javascript for some manipulation.
×
×
  • Create New...