-
Posts
45 -
Joined
-
Last visited
About Mikel
- Birthday 06/06/1971
Contact Methods
-
Website URL
http://frameless.design
Profile Information
-
Gender
Male
-
Location
Vienna
-
Interests
my family, design, ux, paragliding, rockclimbing, sailing, mountain biking, skiing, snowboarding
Mikel's Achievements
Jr. Member (3/6)
9
Reputation
-
Thanks, thats just what I implemented and testet this moment. Working flawless :-)
-
Ok, thanks, I was not sure, so, in my special use case it will be better not to unsubscribe the user, but to delete him. So if he likes to subscribe again in the future, he will get added again.
-
Hi, Daniels, thanks for sharing this! I have just ran into an issue while testing: After successful initial subscription of an user, I could unsubscribe him again, but after that no more subscription of the same user would work. Is this due to a limitation of Mailchimp?
-
I just had a look at the template files: What’s the point in the numerous „row“ and included „class=‚col-xs-12‘“-Containers in the template files? They can be skipped altogether. Also the duplicating of the navigation for displaying a mobile navigation is not really state-of-the-art... bootstrap provides a mobile nav solution right out of the box... Keep it simple! Cheers!
- 39 replies
-
- responsive
- bootstrap
-
(and 3 more)
Tagged with:
-
Just happens to be an issue in Safari. Last stable version (2.8.35) works though.
-
Just upgraded a client installaion (on the development server) to latest stable 2.x release. When testing I spotted a bug (?) adding specific new pages via the "Add new" button or the Pages-> "Add New" menu entry. The specific template used by this page is located a bit down the age tree, so after clicking the "Add new" button the "Where do you want to add ..." select shows. After selecting a parent for the new page nothing happens. Usually the (hidden) submit is triggered. Can anyone verify this? (My workaround is to simply show the submit button) Cheers, Mike
-
Hi, Soma, thanks for the quick reply. The hint (::added) was correct. It pointed me to other problems, so we could work everything out. Here is the working code for automating the modules config (placement in ready.php): $this->addHookAfter('Pages::added', function($event) { $page = $event->arguments[0]; if ($page->template == 'NAME_OF_TEMPLATE') { //check template of page added // get new domain from page name $new_domain = $page->name; // get config data and save it to var $config = wire('modules')->getModuleConfigData('Multisite'); // add new domain to config data and save it $config['subdomains'].= "\n".$new_domain; wire('modules')->saveModuleConfigData('Multisite', $config); } }); I will work on Hooks for Pages::trashed and Pages::renamed. As this is a client project, we will not upgrade unless we get paid for it, so we will stick with this solution for some time ;-) So here are the other two mentioned hooks. Both are working: $this->addHookBefore('Pages::renamed', function($event) { $page = $event->arguments[0]; if ($page->template == 'NAME_OF_TEMPLATE') { //check template of page added // get old domain from page name $old_domain = $page->namePrevious; // get new domain from page name $new_domain = $page->name; // get config data and save it to var $config = wire('modules')->getModuleConfigData('Multisite'); // replace changed domain in config data and save it $config['subdomains'] = str_replace($old_domain, $new_domain, $config['subdomains']); wire('modules')->saveModuleConfigData('Multisite', $config); } }); $this->addHookBefore('Pages::trashed', function($event) { $page = $event->arguments[0]; if ($page->template == 'NAME_OF_TEMPLATE') { //check template of page added // get domain from page name $domain = $page->name; // get config data and save it to var $config = wire('modules')->getModuleConfigData('Multisite'); // remove deleted domain from config data and save it $config['subdomains'] = str_replace("\n".$domain, '', $config['subdomains']); wire('modules')->saveModuleConfigData('Multisite', $config); } });
-
Hi, all, we are trying to automate the module config setting for admin users that only have access to the page tree. The idea is that these admin users should be able to create new pages with the specific multisite template and the page name is automatically added to the multisite config array on page creation. Sadly the hook does not work :-( It is placed in the ready.php: $this->addHookAfter('Pages::add', function($event) { $page = $event->arguments[0]; if ($page->template == 'project_home') { //check template of page added // get new domain from page name $new_domain = $page->name; // get config data and save it to var $config = wire('modules')->getModuleConfigData('Multisite'); $data = $config['subdomainsArray']; // add new domain to config data and save it array_push($data, $new_domain); wire('modules')->saveModuleConfigData('Multisite', $data); } }); Any clues?
-
OMG! Of course, I forgot about this possibility) Thank you, this works perfectly!
-
Hi, kixe, the backend is the only place where this is needed! But as I am actually a designer/part-time developer( with more or less growing knowledge of programming), could you please tell me where you placed the hook above? In a seperate module? Thanks!
-
Hi, kixe, thanks for reminding me of your module! It works the way you wrote, but I have one problem: The site we are working on is for a real estate company. The template in question must be reused for a lot of different projects. (=pages) So it does not work specifying the image field of only one page (filtering per id). The field created with your module should instead fetch all images of the page being edited.
-
Hi, Zeka, thanks for the reply. The goal is to upload about 30 to 50 images at once and then use them in individual sections of the page (template): In "normal" textareas and in "special purpose" fields which actually just would need to store the image reference. With image fields you can only upload images, not choose already uploaded ones. (Or can you?)
-
HI guys, I am wondering if I am to focused on the problem, so that I don´t see an obvious solution, or that there is no elegant solution... ;-) Ok, here is the usecase: I am building a template with only one image-field that collects all needed images for that page. Also there are several repeater matrix fields: One for each section of the page. In each repeater matrix there is the possibility to choose one of the pages images for displaying it as "fullwidth section image" on frontend. At the moment I am doing this with a textarea, which is prone to errors, due to wrong user input. Is there another possibility to store an image reference as a textarea?
-
Work in progress modules Subscribers / WireMailChimp
Mikel replied to benbyf's topic in Module/Plugin Development
Hi, Ben, I just looked ino the WireMailChimp module: It does require the Subscribers module, doesn´t it? For my needs I altered the part whre this module is loaded and the role "subscriber" is checked. (I just run a check against my own subscriptions field) I will then allways get the same error message, no matter if subscribing or unsubscribing: 400: [EMAILADRESS] is already a list member. Use PUT to insert or update list members. Did you already got it to work properly?- 18 replies
-
- 1
-
- users
- subscribers
-
(and 1 more)
Tagged with:
-
Sadly I get an error when downloading the module via PW. PW Version is 2.8 Just tried with latest PW 3.0.41: Same, same... :-(