Jump to content

formmailer

Members
  • Posts

    319
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by formmailer

  1. Hi! It sometimes happens that I need to include Javascript in the body field (using the source code editor). But after switching to CKEditor the Javascript gets removed when saving the page. A work around for this is unchecking ACF and the HTML purifier, saving the page and activate these options again. But I rather would have a more user friendly solution. I assume I can do with Extra Allowed Content, but that didn't work. Does anyone know how to allow javascript, without disabling HTML purifier (and ACF)? Thanks! //Jasper
  2. Hi! Thank you for this great module. Easy to implement and exactly what I was looking for. //Jasper
  3. Hi! I have/had the same issue, but this time with an IFRAME. This page resulted in the "SQLSTATE[42000]: Syntax error or access violation" error when saving the page. <iframe src="//www.someurl.com/" title="Title of the page" frameborder="0" width="745" height="1485"></iframe> But the following code worked fine: <iframe src="https://www.someurl.com/" title="Title of the page" frameborder="0" width="745" height="1485"></iframe> So it seems that the protocol-relative URL is causing the error. //Jasper
  4. @Soma, I believe that you are right about the lazycron and cache. But if this is an issue (eg. with a very long cache time and (nearly) all pages cached, it should be quite easy to edit the module so that it can run using a regular cron job on your server. @Ceberlin That's good to hear. //Jasper
  5. Hi, Since the previous logs showed that the unpublished pages have a publish_until date set to 1970-01-01 01:00:00 which actually is a Unix timestamp 0. Could you please try something for me? Please change line 180 from: if($p->publish_until <= $currenttime) { into if($p->publish_until <= $currenttime AND $p->publish_until > 1) { This would prevent the module from unpublishing pages with the 0 (1970-01-01 01:00:00) value set in the publish until field and should resolve the issue (although it isn't a pretty solution. ) Let me know if it works. If it does, I'll push a new version to Github. /Jasper
  6. Hi! You are right about the translation errors, I thought I got all of them now, but might have missed one. The reason why I used <" . Page::statusUnpublished is because the status can be something else as well. This includes: Page::statusOn (1) Page::statusLocked (4) Page::statusSystemID (8) Page::statusSystem (16) Page::statusHidden (1024) But not Page::statusUnpublished (2048) Page::statusTrash (8192) In my test setup all the searches seems to work fine. SetOutputFormatting(false) is needed to get the date in unix timestamp format, so it can be easily compared with the other values. It would be interesting what the logs say if it happens again. //Jasper
  7. I believe this issue is specifically for Debian servers. I found an old article that explains why this behavior occurs on Debian machines: http://oscarm.org/2006/09/debian-php5-and-session-garbage-collection/ The above article still seems to be relevant, even though it seems to be marked as solved in the Debian bug system (http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=388808) I moved my sites from a Centos machine to a Debian in April and under that time the number of session files has been growing. I post this as a heads up for others running ProcessWire on Debian. //Jasper
  8. Hi! I made a mistake when making the module translatable. Sorry about that. I just pushed a new version to Github that should work. /Jasper
  9. Thanks. Don't know how I missed that post. Sorry about that!
  10. I am running with the following: PW: 2.3.0 PHP: 5.4.4-14 /Jasper
  11. Hi, Today I experienced a problem on my server, I could no longer create new files. The cause of this was the amount of files in the assets/sessions folder. The filesystem ran out of Inodes. My question is, shouldn't files in this folder be deleted automatically after some time? /Jasper
  12. I think you can do something like this: For messages (warnings/informational) $this->message($noticemessage, Notice::logOnly);' For errors $this->error($errormessage, Notice::logOnly); Change logOnly to log if you want to have show the error/message on screen as well. /Jasper
  13. Yes, commenting out the 2 save lines will work. I'll take an extra look at the empty fields. Time zone settings are quite important for this module, but would only cause to publish/unpublish pages at the wrong time, but not more than 27 hours off (GMT-12 all the way to GMT+14 + possibly DST) As for the $time variable, that could be an issue. I'll change the variable name to something more unique in the next update. Update: uploaded a new version where: 1. $time has been replaced with $currenttime 2. Added language support for the whole module. /Jasper
  14. I just uploaded a new version with logging and a fix for the issue Ryan described. @ceberlin and Pete I hope you can install this version this version with logging enabled (logging can be enabled in the module configuration). Every automatic (un)publication will be logged in the /assets/logs/messages.txt file, with timestamps for the publish_from and publish_until fields and the timestamp of the event itself. If the problem still exists, we can take a look at the logfile. /Jasper
  15. Thanks! Was just looking into that module.
  16. I don't see how the Cloudflare could be a part in this. I use them myself and they are just serving cached information, so that should not be a problem. The only thing I can think of right now in order to pin point the exact time and is to add some logging to the module. Just to log the exact time when pages get (un)published and hopefully why. I'll try to fix this later today or tomorrow and let you know when you can try it.
  17. Hi Ryan, If you say that there hasn't ever been a "status=published", it hasn't. I'll take a look at that part of the code and fix it. A screwed up server time could definitively cause the issue. Together with the TZ thing that's the only explanation that I can think of right now. But like I said, I'll keep the site running at my server and will see what happens. /Jasper
  18. I noticed that, but I am pretty sure status=published used to work in 2.2. A question to Pete and Ceberlin: did the pages that got unpublished have a short publishing time left (less than 24 hours) before they got unpublished or was it more than a few days off? An important thing for this module is the time zone setting in the config.php file. If this time zone is wrong, pages can be published/unpublished with a few hours difference, depending on the time zone you are in. Except for the bove I haven't been able to reproduce this issue yet, I installed a clean PW site and added the module.and everything seems fine. But I'll wait somewhat longer and will see if something happens. /Jasper
  19. Hi Ryan, I looked into this "status= thing" and found the following on: http://processwire.com/api/selectors/ Is this something that has been changed in the dev branch? /Jasper
  20. Hi all! I am going to look into this and see if I can fix it. I'll also take a look at the issue Ryan noticed earlier. I actually think that this can be the cause of the problem since the line he mentioned is in the section that checks if a page need to be published or unpublished. But if this is the root cause, I don't get why it worked without problems with version 2.2. Anyway, I'll get back to you as soon as I know more. /Jasper
  21. Hi Ceberlin! I am sorry to hear that you are having troubles with the module. I haven't been able to test it with the development branch myself, but will definately look into this and let you know when it's fixed. //Jasper
  22. Hi, I am not sure if this is causing the issue, but I don't see your API key when you call the Googla Maps API. Read more about optaining the API key here: https://developers.google.com/maps/documentation/javascript/tutorial?#api_key /Jasper
  23. Hi Teppo! It's great to hear that this module is useful. I haven't had time to develop new sites or projects during the past few months, so I haven't been able to test the module in the development branch myself. I am happy that it works there as well. Thank you for letting me know. And thanks for the suggestion you submitted via Github, it has been merged now. /Jasper
  24. Thank you, Ryan. Your tip regarding the console.log made clear that the vars weren't lost. They were still there. After a lot of Google searches I found that the reason was a change in the Google Maps API (it worked in 3.9, but stopped working in 3.10). I also found a bug report with a solution, so now everything is working again. The bug report: https://code.google.com/p/gmaps-api-issues/issues/detail?id=4594 /Jasper
  25. Hi! I just came across a strange problem and I hope you can help me. It's something that worked before, but suddenly stopped working. As far as I know I did not change the code in any way, Ok, here we go: I use an older version of this module and the module itself works perfectly fine. I use it together with Ryan's RCDMap class (for Google Maps) and the source code generated using the module is: <script type='text/javascript'> RCDMap.options.zoom = 4; RCDMap.options.mapTypeId = google.maps.MapTypeId.HYBRID; RCDMap.init('map', 60.128162,18.643501); RCDMap.addMarker('Fotografiska Museet', '/bezienswaardigheden-en-attracties/fotografiska-museet/', 59.319450, 18.077618, 'FFFF00','A'); RCDMap.addMarker('Koninklijk paleis', '/bezienswaardigheden-en-attracties/koninklijk-paleis/', 59.326756, 18.071651, 'FFFF00','B'); RCDMap.addMarker('Skälby', '/bezienswaardigheden-en-attracties/skalby/', 56.682201, 16.336901, 'FF0000','C'); RCDMap.addMarker('Finspångs Slott', '/bezienswaardigheden-en-attracties/finsp-ngs-slott/', 58.709824, 15.770853, 'FF0000','D'); RCDMap.addMarker('Brudfjällsvägen', '/bezienswaardigheden-en-attracties/brudfjallsvagen/', 58.860771, 12.401965, 'FF0000','E'); RCDMap.fitToMarkers();</script> So far no problems... The RCDMap.addMarker function is: addMarker: function(title, url, lat, lng, poicolor, poi_id) { var latLng = new google.maps.LatLng(lat, lng); var marker = new StyledMarker({ styleIcon:new StyledIcon(StyledIconTypes.MARKER,{color:poicolor,text:poi_id}), position: latLng, map: RCDMap.map, }); RCDMap.markers[RCDMap.numMarkers] = marker; RCDMap.numMarkers++; google.maps.event.addListener(marker, 'mouseover', function(e) { RCDMap.currentUrl = url; RCDMap.mapNote.html("<span>" + title + "</span>").show() .css('top', '0px') .css('left', '0px') .css('display', 'block') .css('width', 'auto') .css('color', '#ffffff') .css('background', '#000000') .css('padding', '2px 5px 2px 5px'); $(document).mousemove(function(e) { $("#map_note").css({ 'top': e.pageY-10, 'left': e.pageX+15 }); }); }); google.maps.event.addListener(marker, 'mouseout', function(e) { RCDMap.mapNote.hide(); $(document).unbind("mousemove"); }); google.maps.event.addListener(marker, 'click', function(e) { window.location.href = RCDMap.currentUrl; }); }, The goal is that every marker has its own letter (poi_id) and color (poicolor). This used to work fine, but suddenly something happened and now is every marker getting the same letter and color as the last marker. The titles, links etc. working fine and are unique for every marker. Any suggestions about what I am missing? You can see the problem live at: http://www.zwedenweb.com/bezienswaardigheden-en-attracties/ Thanks in advance! /Jasper
×
×
  • Create New...