Jump to content

dragan

Members
  • Content Count

    1,524
  • Joined

  • Last visited

  • Days Won

    17

Posts posted by dragan


  1. 2 hours ago, rjgamer said:
    • The link href values are properly being output with the current page url with ?page=1, ?page=2, etc.
    •  

    Perhaps not much help, but I find it strange that it adds query strings. The page numbers should actually be rendered like this:

    http://demo.processwire.com/cities/new-york-city/page2

    Do you find any hints in any of these places?

    • browser JS console
    • Tracy Debugger
    • PW error logs

    Perhaps also check the browser network panel, to see if the page(s) return HTTP 200 or a redirect.


  2. Quote

    The free plan is limited to 30 minutes daily. When the free session ends, Blisk disables devices, auto-refresh, screenshots and screen recorder, scroll-sync, error notifier, page inspector, device DevTools.

    Well, I'm not impressed.

    @OrganizedFellow Why was the reloading "always buggy"? Maybe you set it up wrong? I never encountered problems with Browsersync (with linting tools however, or when pulling from Git again, it's a different story - I have to restart Gulp several times a day - but never because of browser live reloading).


  3. Well, I had it for ages, but only today made a Github repo and thought I could just as well share it.

    And yes, it's similar because we apparently use the same core class ifsnop :-)

    It's especially useful if you have to work on a site where you can't quickly create a files-backup as ZIP, nor un-zip easily via control panel (which is standard in Plesk et al). Or if you can't run system commands, because the hosting company doesn't allow it. 

    On some sites, I have it running with a hook and/or PW lazycron. And before any major changes (dev/prod), I just trigger it manually.

    • Like 2

  4. I still don't get what you want to achieve in the end, but try this

    $(document).ready(function() {
    	$(".InputfieldButtonLink").removeAttr("href");
    	$(".InputfieldButtonLink").on("click", function (e) {
    		e.preventDefault();
    		console.log("so now what?");
    		return false;
    	});
    });

    For some reason, this will do a console.log() twice, because there's also a click handler defined in wire/modules/LanguageSupport/LanguageTabs.js

    i.e. if you want to make sure that your custom action only fires once, you'd have to somehow de-activate that click handler too.


  5. 19 hours ago, MateThemes said:

    but how can I access this images on a page? 

    Do you mean access them from an images-field on that page? In that case you'd change the image path to site/assets/files/page-id/ instead.

    But you'd still have to add the images to the field programmatically so that PW "sees" the new pics (via hook or Cron).


  6. I wonder how all these years I never heard of John Frusciante's solo records... until a recent trip to Croatia, where the best cook in the village played some of his stuff... one of the most laid-back places I've ever been to at the Adriatic coast...

     

    And then there's this gem I discovered just 2 days ago:

     

     

    • Like 1

  7. @bernhard Perhaps go back to page 1 of this thread, i.e. this post.

    a) I have inserted in all JS files "use strict" at the very top

    b) I have replaced != with !== everywhere the IDE was warning me

    tldr; "use strict" in JS is something like PW's debug mode enabled: it gives you many more errors, hints + warnings that otherwise would slip through (even if you end up with unexpected results). The Mozilla link I posted is a good read.


  8. @ryan No, not yet. I have only enabled a few functions. What I found strange though (perhaps just coincidence):

    The bottom left link "disable AoS" also stopped working as it should, i.e. I had to save module settings twice, before it was disabled.

    That link to disable the module has a query string parameter toggle, which is set to 1. And afaik the first toogle field-value (e.g. Yes) also has value 1. That's maybe one toggle too many :-)

    • Like 1

  9. No JS errors. Google Chrome, Windows.

    Also: When I previously selected No, then re-edit the page and select Yes, it sticks with No.

    It's the same with Firefox and IE11, btw.

    $config->debug = true;
    $config->advanced = true;
    Apache/2.4.39 (Win64) OpenSSL/1.0.2s PHP/7.2.11

    Nothing supicious in Tracy.


  10. On 11/26/2016 at 11:31 AM, iNoize said:

    I dont know what is it but i had to restore the DB

     

    3 hours ago, wbmnfktr said:

    Anyone any idea how to fix this or where to look first?

    Difficult to say with so little infos. But in any case, a DB almost half a GB big is rather... big.

    There are various ways how to create a DB-dump. Did you use PW's DB-backup or did you create your own?

    Try to delete all cache DB entries in your dump.sql first. They can become huge, and are rather useless on a new install.

    Then maybe delete everything inside site/assets/cache/.

    Do you have DB-session handler installed or default? (file-based)

    What was the last time the site (core) was updated?

    Log files (PW + server)?

    Did you check site/config.php?

    $config->debug = true;
    $config->protectCSRF=false;

    Finally... is the clone running on the exact same setup (PHP version etc.) as the original one?

     


  11. Yep, I was also underwhelmed, with both services.

    An upscaled image (4x) showed really ugly artefacts on the face and hands parts of an image.

    With background-removal... well, an entire (huge) part between two body-parts was not removed (similar skin-tone and background-color).

    It seems that even with AI in 2019, the old adage still holds true: SISO. The better / bigger your original image is, the better output you'll get.

    • Like 1

  12. @ryan There seem to be issues with the new toggle field-type.

    I just upgraded to the latest PW dev, and installed toggle and placed in basic-page tpl.

    The setup is like this:

    toggle.thumb.PNG.3a4fed5051858157d2e683e4dc823e17.PNG

    On pages with No or Undecided the output of $page->toggle is what I would expect.

    However, on the page where I selected Yes:

    • I get only an empty string with Tracy in the frontend.
    • In the backend, when I select Yes and save the page, nothing is selected after page-reload.

    (there is neither Yes, No or Undecided with blue background)


  13. Putting "use strict" should really be the default... It simply shows more hints and errors and this can be very useful while debugging. Using this in every JS file now revealed some data type mismatch too, when using !=== instead of !==. (see screenshots below)

    In trash.js I changed basically these lines:

      var gridInstance = $('.RockTabulator.tabulator');
      var grid = RockTabulator.getGrid(gridInstance);

    and further below:

            // success
                    if(result.success) {
                        UIkit.notification(check + result.success, {timeout: 3000});
                        if( RockTabulator.getGrid(gridInstance).reload() ) {
                            console.log('grid has reloaded!');
                        } else {
                            console.log('grid has not reloaded!');
                        }
                        // grid.reload();
                    }
          },

    But as I said, since RT is not known inside that JS script, it can't call an unknown method getGrid...

    lastonefortoday.PNG

    • Thanks 1

  14. Yep: you should get used to use "use strict" in every JS file, then you would have found this error earlier: 

    https://developer.mozilla.org/de/docs/Web/JavaScript/Reference/Strict_mode

    Now I see this is my console:

    jsconsole.thumb.PNG.7c2255b09f257988068d527eb63fbf91.PNG

    Also, I see quite a few IDE warnings like these:

    panel.js: if(name != 'panel') return;

    Quote

    Comparison name != 'panel' may cause unexpected type coercion
    This inspection reports usages of JavaScript equality operators which may cause unexpected type coercions. It is considered a good practice to use the type-safe equality operators === and !== instead of their regular counterparts == and !=.


     

×
×
  • Create New...