All Activity

This stream auto-updates     

  1. Today
  2. BitPoet

    Nearly ten months later, FormBuilder is happily at work here and I am testing a home-brewed module that implements repeating fieldsets for FB forms [TM]. I have named it FormBuilderMultiplier and put it on GitHub in case anybody is interested.
  3. Hi there Basically I want to call code within a ProcessWire page that isn't used as a template. Example: I have a working PW Website with a couple of pages like /artists, /releases, /videos etc. Now I need a page /download without any editable fields in the backend, just calling some PHP code (that was coded by another guy) containing a form that checks unique download-codes in a second database and starts the download of the desired file. The script is working fine right now as part of a static website, but since I built PW behind the site, this independent «Download Section» of the page doesn't work anymore. Right now I have the main file download.php as a page template on a newly created empty page called /download, so until now the form is working (wow). After sending the form containing the download-code, the file check_code.php in a subfolder /site/templates/download is called and that's where I get an error. Any help?
  4. daniels

    No worries I suggest testing the subscribe function in a normal doc with test data. If this works (which should :)) try to dump your real data wherever you want to implement the subscription. If you can var_dump the right data there, you should be able to perform the subscription there Let me know if you have questions regarding the module itself or run into errors there.
  5. MarcoPLY

    Hi @daniels, thank you for your reapply! eheh, yes you have right. I explain better what I have to do In addition to the loginRegister module I also use the registration via Facebook. This registration bypasses the registration form and don't send the data to mailchimp. I thought about making a hook for all the users that are registered, regardless of the method. Then use Pages::saved (I'm not sure it's right) and pass data to mailchimp when the user's page is created. But the attempts I tried don't work, I'm probably wrong the way I access the data. Do you know how can I create this action, to send the data to mailchimp when the users page it's created? (Sorry, I have thought just now that maybe this was a question to put in general)
  6. flydev

    Whats the PHP version on XAMP and server? (Cant reproduce the error, working fine here)
  7. daniels

    Ok @MarcoPLY , I think I got your question completely wrong I leave my reply anyway if someone needs it one day... Have you tried to var_dump the subscriber? What do you get there? Is the $ before country_title intentional?
  8. daniels

    Hey @MarcoPLY , not sure if I get it right, but do you want to add user to specific categories? In the API naming, groups are called 'interests'. You can add them as additional parameters as in the example below. To get the interest IDs is a little pain-in-the-ass but I'll try to guide you: 1. Go to and enter your API key. 2. Click on 'Lists' and choose 'interest-categories' from the 'Subcategories' of your related list. 3. Choose 'interest' from 'Subcategories' of your related interest category 4. Now you can click on each interest and you'll get the id which should be the ID that you have to use in the 'interests' part of the example below. Please let me know if this works for you! When I find some time, I'll add a way to get these ids in the module Settings in PW admin. Example from the docs: // Work with additional parameters (not merge_field values!) $mc->subscribe('', NULL, NULL, [ 'language' => 'en', // find language list here: 'vip' => true, // boolean vip status 'location' => [ // geo location based on lat/log coordinates 'latitude' => '48.8722344', 'longitude', => '2.7736192' ], 'interests' => [ // subscribe user to interest categories / groups based on group id '32fec3561e' => true, '63mel4395m' => false ] ]);
  9. simonsays

    Same result, both with and without
  10. Macrura

    sounds familiar; I switched some sites over to a KnownHost VPS and so far it has been good. I can definitely say that their support is great, any support ticket is answered very rapidly, and this applies to both VPS and for their shared hosting plans.
  11. Macrura

    i just use a function to output the code from realfavicongenerator function favicons($options = []) { $defaults = array( 'appleColor' => '#4d9db4', 'msColor' => '#da532c', 'themeColor' => '#ffffff', 'path' => null ); $options = array_merge($defaults, $options); $folder = 'site/templates/favicons/'; if($options['path']) $folder = $options['path']; $folderUrl = wire('config')->urls->root . $folder; $filePath = wire('config')->paths->root . $folder; if(!is_dir($filePath)) return; $out = <<<OUT <link rel="apple-touch-icon" sizes="180x180" href="{$folderUrl}apple-touch-icon.png"> <link rel="icon" type="image/png" href="{$folderUrl}favicon-32x32.png" sizes="32x32"> <link rel="icon" type="image/png" href="{$folderUrl}favicon-16x16.png" sizes="16x16"> <link rel="mask-icon" href="{$folderUrl}safari-pinned-tab.svg" color="{$options['appleColor']}"> <link rel="shortcut icon" href="{$folderUrl}favicon.ico"> <link rel="manifest" href="{$folderUrl}site.webmanifest"> <meta name="msapplication-config" content="{$folderUrl}browserconfig.xml"> <meta name="theme-color" content="{$options['themeColor']}"> OUT; return $out; }
  12. MarcoPLY

    How can I use this moule for all users who are saved with a specific category? I'm not sure which Class and method need to use and also maybe I not get the correct fields. wire()->addHookAfter('Pages::saved', function($event) { $page = $event->arguments(0); if($page->template == "user"){ if ($user->hasRole('login-facebook')) { $mc = $modules->get("SubscribeToMailchimp"); $email = $page->email; $subscriber = [ 'FNAME' => $page->pad_firstname, 'MMERGE4' => $page->$country_title, ]; $mc->subscribe($email, $subscriber); } } });
  13. I think this is a question for @ryan (?)
  14. flydev

    By default, SOAP trigger error with his custom php error handler. To catch exceptions, add array('exceptions'=> true) as an argument : try { $client = new \SoapClient('faulty url goes here', array('exceptions'=> true)); } catch (\SoapFault $e) { echo 'wrong'; }
  15. simonsays

    I tried both ways and there is no real difference. I tried both } catch (SoapFault $e) { print 111;exit; return $this->client = false; } } catch (\SoapFault $e) { print 111;exit; return $this->client = false; } It reaches the "111" part but even with exit; the error is still thrown
  16. Hi there, a customer of mine is living in the U.S.. About 7 years ago I started to create a website for her. She parked her domains at GoDaddy. After some frustrating attempts to install a cms, finally I convinced her to go to Arvixe. At this time everything worked fine, they had a real support. Meanwhile the situation changed, everything sucks, the support disappeared. I've got the feeling, that the management changed and they reduced all to a minimum of support. So my question is – what U.S.-hosting company would you advice? thanks
  17. bernhard

    You are right, so I guess the docs are misleading in this case.
  18. MoritzLost

    Hi horst, thanks for the reply! I'll use that check to make sure no pages are linked that shouldn't be visible. However, I would still like to filter out pages with statuses that will never be viewable. I'm querying the database directly to get a list of pages for performance reasons. Since I'm performing one costly regex per title, I would like to only get the pages that are actually published & viewable, so I still need to understand all status IDs to determine whether they're relevant for the bitmask ... I looked into what checks $page->viewable perfoms, but haven't been able to find a reference to the IDs for "draft" and "versions", so maybe they are not relevant after all?
  19. Hi, i changed one line in the JS code of the InputfieldRepeater.js in /wire/modules/Fieldtype/FiletypeRepeater to have this field behave like i want: instead of appending the new items to the container it should prepend them, so every new item is on top instead of at the bottom. $inputfields.prepend($addItem); // $inputfields.append($addItem); how would i make this change update proof? can i just copy the file to /site/modules/(...)? or is there any smooth way to hook into this javascript function? best, ocr_b
  20. Hi Moritz, not totally sure, but I think for your textformatter, you only need to know the equivalent of $page->viewable(). Im on mobile, so no further links here.
  21. gebeer

    Hello @apeisa, thank you for this module. I use it on many sites. Now I have a client site where the homepage in the default language has a url segment 'de'. In the LanguageSupportPageNames module I have the setting active to redirect the default language pages to that url segment. So the homepage URL in the default language reads ''. In my opinion this setup does not make a lot of sense but the client insisted, so what can I do.... Now when I add a redirect like '/wer-wir-sind' (which is an old URL from the pre-PW site), the module does not kick in because the LanguageSupportPageNames module adds the 'de' to the URL. Now I end up with a URL like '''. The redirects module cannot find that URL and won't redirect. As a workaround, the administrator could enter redirects for the default language in the format '/de/wer-wir-sind'. Now redirects work but from a logical point of view this doesn't make sense. Because we want to redirect from'' to a chosen URL and not from ''. To make a long story short: I added some code to the checkRedirects method of the module right after line 247, which caters for this special use case: // if homepage in default language has a language segment and the root URL is redirecting to that language segment, // remove the segment from the url so it can be found in the DB if( $this->wire('modules')->isInstalled('LanguageSupportPageNames') && $this->wire('modules')->getModule('LanguageSupportPageNames')->useHomeSegment && $this->wire('user')->get('language')->isDefault() ) { $homeSegment = '/' . $this->wire('pages')->get(1)->name; if (substr($url, 0, strlen($homeSegment)) == $homeSegment) { // remove the language segment from $url so it can be found in the DB $url = substr($url, strlen($homeSegment)); } } If you think it should be implemented into your module, let me know and I'll make a PR on github. Cheers
  22. Yesterday
  23. Hello all First I would like to say PW is a wonderful CMS and a very helpful and friendly community, which is rare these days. I was doing web dev as a hobby while I cared for elderly parents but now it's time to move forward and get serious ( it's getting cold here so I'll be trapped indoors lol ). A while back I created a full featured built in forum system for Evolution CMS which I could rewrite for PW if there is enough interest, although it would have to be a paid module. At the moment I only have a working version on my local wamp, I can put it online next week and send anyone interested a link via PM. What do ya'll think? A few screenshots:
  24. public function matches($selector) { // This method implements the WireMatchable interface return $this->comparison()->matches($this, $selector); } @bernhard I think $this->comparison()->matches($this, $selector) is PageComparison->matches(Page $page, $s) which doesn't accept an array, it only checks for a string or int and a selector, else returns false.
  25. adrian

    Done - let me know how it goes for you. I also fixed some other PHP7 issues with the Option 2 approach.
  1. Load more activity