Jump to content


  • Content Count

  • Joined

  • Last visited

Community Reputation

2 Neutral

About Matze

  • Rank
    Jr. Member

Recent Profile Visitors

685 profile views
  1. Okay, it's "Textareas" - found it, sorry … (how can i delete a post?)
  2. Hi there, i need around 20 simple text fields in a template, same properties for all, except the "label" (or title to use it in code). Something like this: painter: _____________ period: _____________ canvas material: _____________ painting technique: _____________ etc is there a way to avoid building 20 single fields? I use pro fields too, but cant see any solution e.g. with Multiplier or table. Thank you Matthias
  3. Hi there, maybe i just missed it, but - while I'm editing a page, is there … a way to quickly jump to the template of the page to edit it? … a way to quickly jump to a field (when superadmin there is a hover about which field is currently used, but no linking or options with this, so i have to go over the menu, looking for the right field.) Thanks.
  4. Thank you all for your inspiration! I'll try them all. Seems that Soma's solution will make it. Not sure what "Enter the names of any image fields (separated by a space) that you do not want to allow for selection with this module." exactly means, but a quick test hides them from the CKEditor selection. (hopefully not restricting any other functions of the field)
  5. Hi there, For example, if i have three image(s)-fields in a page template. And a ckeditor field. If i click on the "add image" button in the ckeditor a dialog opens (eventually with some images to choose from, if uploaded before) and a button to upload images. After clicking this button, a new dialog appears to choose from which image field to upload. In this case three fields. Is it possible to configure which fields appear at this place, or preselect one? Or only to display the image field which is meant for this purpose? I want to avoid that a customer uploads a content image to a different field, where maybe some layout images or others are stored. Thanks for any hints Matze
  6. Thank you Robin, this worked very fine. So I'm close: The password field isnt required anymore and it's hidden if the page is published. Only if the page is unpublished it's still visible. Any reason for this? Or any idea how to hide completely, independent of published or not? Thank you so much!
  7. The hook worked perfectly, thank you very much! Now i just need to find out how to hide the password field in Admin, too. There is no "visibility" option for the password field? Any reason for this? I tried to manage this over access control, but this was causing new problems. Unchecking the "view" checkbox for admin role ( and automatically guest, too) was disabling the possibility to check password in script via Password->matches().
  8. Well, thank you very much, but no, it’s a secondary password to set, for some reasons. But it's not set via Admin. But i need the field for the password. So the question is still: why is a password required if i uncheck "required" in the field definition?
  9. Hey there, is there a possibility to make a password field not required. Whatever i try (no check or check the required option in field definition) it is always set to "required" and gives an error () if i try to save or create a new page with this field in its template. Required password was not specified, Missing required value Is it possible? Thanks! Matze
  10. Well thanks a lot for your replies. I will have a look at all the CK template options!
  11. Hi there, ist it possible to predefine content like text or html snippet for ck editor? So if i start a new page with this template containing this ck-editor-field there is already pre-written some text/html in this field? thanks
  12. Well, yes indeed. But that was just for a quick result reporting. My main goal is not to use jQuery anymore and completely switch to good old JavaScript. Inspired by UIKit framework 😏
  13. Works perfect. Thanks a lot!
  14. Hi there, I'm trying to get to work some AJAX call with vanilla Javascript, not jQuery. Anything seems to work so far, but the !$config->ajax seems to be ignored. To find out whats the problem by comparing both, jquery and plain javascipt, i built this template. commenting out //loadJquery(''); or loadVanilla(''); switches the two variants. (empty url variable means that the same pages will be loaded.) The problem: the pure Javascript function ("loadVanilla") is loading the full page content into the dc-container, which is wrong. The jQuery function ("loadJquery") only loads the part outside of the if(!$config->ajax): - which is as it should be. So - any help with this, what am i doing wrong? Thanks a lot - Matze <?php namespace ProcessWire; if(!$config->ajax): ?> (some static content)<br> <a id="loadlink" href="#">load</a><br> <?php endif; // end if not ajax ?> <span id="dc-container">(dynamic content)</span> <?php if(!$config->ajax): ?> <script src="http://code.jquery.com/jquery-3.3.1.min.js"></script> <script> var loadlink = document.getElementById('loadlink'); loadlink.addEventListener('click', function(event) { //loadJquery(''); loadVanilla(''); event.preventDefault() }); function loadVanilla(url) { var xhttp = new XMLHttpRequest(); xhttp.onreadystatechange = function() { if (this.readyState == 4 && this.status == 200) { document.getElementById("dc-container").innerHTML = 'loaded: ' + this.responseText + (' (by vanilla javascript)'); } }; xhttp.open("POST", "", true); xhttp.send(); } function loadJquery(url){ // Load content $.ajax({ type: "POST", url: url, data: { ajax: true }, success: function(data,status){ pageData = data; } }).done(function(){ // when finished and successful document.getElementById("dc-container").innerHTML = 'loaded: ' + pageData + ' (by jquery ajax)'; }); } </script> <?php endif; // end if not ajax ?>
  • Create New...