Jump to content

bernhard

Members
  • Posts

    6,026
  • Joined

  • Last visited

  • Days Won

    292

Everything posted by bernhard

  1. thanks for the input tpr, do you create a template file for that? something like /templates/_sandbox.php or which url do you call?
  2. update: i still (or again) think that this feature would be very helpful! for example i need to create some fields via api for my new module. it would be great to test this via the console. one window to create the field, one to delete it. that way i could test things very quickly without losing track. what do you think, @adrian ? edit: i solved it by implementing 2 methods in my module and then calling them from 2 different browser instances (1 on default browser, 1 on incognito) like this: // default $m = $modules->get('mymodule'); $m->tmp_create(); // incognito $m = $modules->get('mymodule'); $m->tmp_delete(); the methods look like this: public function tmp_create() { $log = $this->wire->log; $field = new Field(); $field->type = $this->modules->get('FieldtypeTextarea'); $field->name = 'test'; $field->save(); $msg = "field {$field->name} successfully created"; $this->message($msg); $log->save('rocknotes', $msg); d('done tmp_create'); } public function tmp_remove() { $this->deleteField('test'); d('done tmp_remove'); } i like this approach even more because i can write the code in my IDE now sorry for my monologue
  3. just wanted to mention that the new version has support for common tags: https://processwire.com/blog/posts/processwire-3.0.38-core-updates/#added-support-for-common-multi-language-translations
  4. to make file uploads work i had to make those adjustments on my laragon + win10: // php.ini (right click on laragon tray > php > php.ini date.timezone = Europe/Vienna // uncomment and set always_populate_raw_post_data = -1 // uncomment don't forget to reload laragon awesome tool so far, thanks for sharing @LostKobrakai and @pwired
  5. hi adrian, would it be hard to get the possibility to have multiple console windows open at a time? it would be nice in some cases (for example one to create some stuff via api, eg fields or templates) and one to delete it - would be great here for testing install and uninstall method from a new module. that way you could test things really quickly. at the moment when you open the console in a new window, it loads in the "_blank" window and if you open the next console it reloads that window instead of opening a new one. or maybe there's already a better way of doing this? thanks update: in that case it is really easy to do that, so please don't put any effort in this if you think it could not be of use in other scenarios... $m = $modules->get('sample_module'); $m->uninstall(); $m->install(); $m->uninstall(); update2: i still think it would be nice to have such a possibility! or at least have the option to DISABLE the code remember feature, as this overwrites the code of the current browser tab when you open the panel again. if that would not be the case we would be able to have multiple browser tabs open with multiple tracy bars with multiple console-windows. or maybe an option that the console panel does NOT close automatically? i don't know when it closes and when not. sometimes it stays open. i have not found a regularity here...
  6. thanks for bringing that to my attention
  7. hi kuba2 and welcome hard to say what's wrong... just wanted to give you a tip: install tracy debugger and use the console! it's awesome and will help you to understand everything much better than putting some code into your template files and reloading the browser over and over again. you could do something like this in your case: $p = $pages->get( # your page id # ); d($p->product-img); d($p->product-img->url); if you set your product image to "automatic" it will be an array when you uploaded more than 1 image and a single item when you uploaded only 1 image. in tracy you could easily inspect such things (that's what adrian already said above)
  8. i have an idea and would be interested in your thoughts: sometimes you need simple calculations in special fields, like 15% of field value x. what about a small javascript, that can interpret and calculate such formulas? like in excel... =1500*0,15 would put "225" in the field. in excel it also works like this +1500*0,15 that's better if you have a numpad on your keyboard.
  9. i'm still voting for a solid and core solution of image cropping. using either an exact crop, or predefined ratios, or using a focus area and make it possible to get the right image for the right spot on your template/design and allowing different ratios! but i guess we 2 are in a minority... ?
  10. thank you @pwired do you have processwire running on laragon? what are the steps necessary to do? thank you
  11. same here. but i went the risky way and it was released just in time i still think that this should be a core feature... you could hide the button easily with some JS or CSS, for example using admin custom files or a little hook. do this once and you will be able to do many other little tweaks in the admin without asking for support
  12. sure, that's correct. but it would be interesting if there are some other things to keep an eye on when using it with processwire. unfortunately i'm so busy atm that i can't try it myself so i wanted to ask if anyone has some experience with it to save me time when i try it out the module could indicate if htaccess is writeable and show instructions how to chmod and alert to chmod back after making the changes.
  13. @jacmaes mentioned he's using https://perishablepress.com/6g/ and i wonder if he is the only one? @jacmaes, as i read in your link there are some wordpress plugins for that. would you think it would be hard (or useful) to create a pw module for that? are you using it in conjunction with other firewalls or standalone?
  14. thank you pete, i guess that does help and i will report back only if not
  15. looks awesome @tpr ! @gmclelland i support your request to improve that feature on mobile but i would not see it as a replacement of drag&drop. on mobile, yes! but on desktop the drag&drop is almost a killer-feature compared to other cms. and now on steroids it is finally getting even more userfriendly!! thank you tpr for picking the idea up, looking forward to the next steroids update
  16. yes but the question is when to trigger this function without messing the whole tree or the UI up but i bet you find a good solution
  17. i think it should be possible to trigger a tooltip while dragging the item over a parent with children that says "wait 1 second to open this item, then you can drag your item here". maybe it would also be helpful to create a first child via javascript, because if the subtree is not visible, you can only place your item below or above the parent. hmm. playing around with it i think there might be some problems (eg when having paginated lists...). i think the best solution would be a tooltip showing the help "if you want to place your item here you have to open this pagetree before moving your item". that would be the easiest and most bulletproof solution. edit: tried to add "PageListItemOpen" class to the items, but then hovering gets buggy... hm.. don't have a good idea how to solve that properly. but i still think there is room for improvement
  18. hi tpr, 2 things: 1) having open treeitems show up in bold is really helpful! 2) i see clients having problems with moving items around the tree very often. especially when they want to move a page into a subtree of another item. the explanation is always the same: "you have to open the oder pageitem before you can move your sub-item there." i think that could be improved and would perfectly fit into your steroids module, if it does not find it's way into the core. looking at your short screencast (https://processwire.com/talk/uploads/monthly_2016_09/aos-highlightrow.gif.7fa25570dd6f9c8c6db625ab329947a8.gif) it brought up the idea of improving this part as well. do you think it would be possible to trigger the click on the treeitem when a user holds the moved item over the new parent? or maybe bring up some helping tooltip like "if you want to place your item here you have to open the parent item first"? what do you guys think about that?
  19. sorry guys, i have to try if that is related to newly created posts... ok that was the point! editing a topic right after creation is not allowed within a certain timeframe... @tpr and @Pete that was what i was talking about in several other topics...
  20. thank you tpr, just tried it and did not get the warning. don't know where and why it's coming (from)... ok back to topic: any ideas? i had to switch to pageNames without UTF8 to get my import script working without problems! i did some encoding checks and it seems that some strings that i import are UTF8 and some are ASCII - but i guess that should not be a problem since ASCII is a subset of UTF8 as far as i read...
  21. welcome scaaty, i would also recommend to create your own slider with repeaters. they look great now in pw3, what you seem to be using. that's the nice thing with processwire: often you are faster to develop your own solution than looking for plugins, comparing their features, checking compatibility and so on. just throw together some fields, create the markup and you're done and have a 100% customizable solution have fun!
  22. same issue here! thanks @valan for the fix!
  23. Hi Pete im talking about the time for editing a Post. If you find a typo or forgot to Post a Link you Click edit and Save and then you are forced to wait xx seconds. That makes no sense other than annoying - at least - me and has nothing to do with multiple posts.
  24. works! thank you. i hope it does not affect any other parts of tracy
  25. hi everyone! i've created an excel-like copy&paste import-script using handsontable... so far so great, but when i create the pages, i get some weird results for some pagenames. the pagename is NOT set via the api, because then processwire should handle the creation of an unique pagename itself: leading to this error: but when i do a manual pagename sanitization it seems to work fine: i could implement this sanitization before saving the page, but then i would have to take care of non-duplicate pagenames myself. and also i'm not sure what the problem is and if that is a bug? any help very appreciated! @Pete any chance to turn off the more than annoying timelimit for page edits?
×
×
  • Create New...