horst

PW-Moderators
  • Content Count

    3,303
  • Joined

  • Last visited

  • Days Won

    59

horst last won the day on December 16 2018

horst had the most liked content!

Community Reputation

4,574 Excellent

About horst

  • Rank
    observer of the big picture
  • Birthday 11/05/1955

Contact Methods

  • Website URL
    https://nogajski.de/

Profile Information

  • Gender
    Male
  • Location
    Aachen, Germany
  • Interests
    Photography; PHP, HTML, CSS (SASS,LESS), JS;

Recent Profile Visitors

30,993 profile views
  1. Hi, I encountered a problem with my default .htacces rewrite conditions and rules when having multiple domains to rewrite them to one final domain. Usually I use something like this: <IfModule mod_rewrite.c> RewriteEngine On AddDefaultCharset UTF-8 RewriteCond %{HTTP_HOST} ^www\.example\.com$ [OR] RewriteCond %{HTTP_HOST} ^www\.example\.de$ [OR] RewriteCond %{HTTP_HOST} ^example\.de$ RewriteRule ^(.*)$ https://example.com/$1 [L,R=301] RewriteCond %{HTTPS} off RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] </IfModule> Now I'm faced with the situation that I have a subdomain.example.com and www.subdomain.example.com with a wildcard SSL certificate for example.com (*.example.com). With my below htaccess directives every input of subdomain.example.com www.subdomain.example.com http://subdomain.example.com http://www.subdomain.example.com get redirected correctly to https://subdomain.example.com But when I enter explicitly the www. url with a https:// (https://www.subdomain.example.com), my rewrite conditions are ignored, resulting in a warning about insecure SSL certificate. RewriteCond %{HTTP_HOST} ^www\.subdomain\.example\.com$ RewriteRule ^(.*)$ https://subdomain.example.com/$1 [L,R=301] Does someone know why it does not work? I also tried combined conditions like this: RewriteCond %{REQUEST_SCHEME} https RewriteCond %{HTTP_HOST} ^www\.subdomain\.example\.com$ RewriteRule ^(.*)$ https://subdomain.example.com/$1 [L,R=301] RewriteCond %{HTTPS} on RewriteCond %{HTTP_HOST} ^www\.subdomain\.example\.com$ RewriteRule ^(.*)$ https://subdomain.example.com/$1 [L,R=301] Any hint? UPDATE: In a call with the hosters support team, they told me that it is not possible to catch these explicitly entered https://www.subomain.example.com from within the .htaccess file. As a workaround we now have taken a standard SSL certificate for the explicit domain "www.subdomain.example.com". There was an inclusive cert without extra costs available.
  2. horst

    Very nice site! May I ask how you realized the calendar.ics part? I'm currently building the same. I created two templates, a parent container and the ics-calendar children. Every calendar event will be build as a childpage. The childpages will be embedded per pagereference field where needed. The URL is included, and when downloading the type is text/calendar. Have you experiences if the compact vcalendar format you uses is suffient with different MS-Outlook applications? I found some examples in the web with additional X-MS-OLK- and X_Microsoft-... Params.
  3. horst

    in Here you call it on a var that is not a pageimage but a boolean! First check if you REALLY have an image, before you call ->getCrop() on it. And which PW version and module version you are using?
  4. Please look into processlister.module public function set and the same function of it parents. (I'm on mobile)
  5. The properties are set as protected. You need public accessible setter method(s) like with every PHP class. Something like this: public function setMyName($val) { $this->myName = $this->sanitizer->text($val); } public function __set($var, $val) { if(isset($this->$var)) $this->$var = $this->sanitizer->text($val); } Theoretically also direct public accessible properties can be set directly from the outside, but this is bad code, a NoGo.
  6. horst

    Definetly a typo here, but is it a missing "t" or a missing "y"?
  7. horst

    I think the best explanation is directly above that method: So, as I understand this, it tries to rebuild variations. But limited variations, 0 = without suffixes, without crops, etc. (read on above). But to know which variations are belong to an image, the variations have to exist! (It gets all variations and then try to determine how they were build, what seems to be simple for mode = 0, but becomes more and more special and indefferent with higher modes). HTH ?
  8. horst

    @Jonathan Lahijani Hmm, there is no fast fix possible ATM. BUT you may use this code, passing the options array as second param to pim2Load, what works as expected: $image1->pim2Load('i1')->setOptions(['outputFormat'=>'jpg'])->pimSave(); // FAILES (with outputFormat, all other settings work as expected) $image2->pim2Load('i2', ['outputFormat'=>'jpg'])->pimSave(); // works!! Summary: all option settings work in both ways, BUT changing the outputFormat only works correctly when passed as options argument into pim2Load(). (I think it needs a massive rewrite to fix that properly, for that I have no time atm )
  9. horst

    Hi Jonathan, sorry, I completly missed that one. Will looking into it next week. And thanks for showing the issue by video, what makes it very clear to follow!
  10. horst

    Using or building?
  11. horst

    I personally never would redirect visitor-users to the backend. But I use user roles and access rights a lot. So, I thought there is already a FE login / logout module available? Otherwise I think it is not reinventing the wheel everytime, as you may build custom modules or reusable template / field systems.
  12. You may additionally try out the hook "setupNew" $this->addHookAfter('Pages::setupNew', $this, 'setDefaults'); $this->addHookAfter('Pages::added', $this, 'setDefaults'); or as @BitPoet already mentioned "Pages::added".
  13. Hi Moritz, big thanks for this one too! I use a similar setup, but with page references instead of option fields.