Jump to content

teppo

PW-Moderators
  • Posts

    3,227
  • Joined

  • Last visited

  • Days Won

    109

Everything posted by teppo

  1. “Failed asserting that true is false.” That sounds about right.

  2. RT @GonzoHacker: Human Resources will now be known as Meat Based Machine Maintenance. Please let your supervisor know if you require servic…

  3. RT @dinet: Help get @processwire packaged by Bitnami. You can vote at http://t.co/jtElRFiiWi

  4. Two days to go and #ProcessWire is leading Bitnami contest. There's still time to vote, though: http://t.co/K3EJf8NaEm

  5. RT @smashingmag: A JavaScript library to make absolutely positioned elements attach to elements in the page, efficiently. http://t.co/Z3Wq1…

    1. MatthewSchenker

      MatthewSchenker

      I'd like to see it! Can you fix the link?

  6. RT @codinghorror: I love phone apps for websites because it is just so much fun to learn two totally different and incompatible UIs for doi…

  7. Once again on a tight schedule here, but first of all, I'd start with making sure what character sets are actually in use. If not UTF-8, you can convert data to it with relative ease, though it needs to be done once for database, then on table-by-table basis for existing tables. This is important to keep in mind, though: (Source of quote: http://dev.mysql.com/doc/refman/5.6/en/alter-table.html.) Hope this helps a bit. I'd be happy to take closer look at this at some point too, now I'll have to run
  8. Slightly unrelated, but is there an actual warning or what? Just checking, 'cause in that case we'd be seeing *a lot* of these
  9. RT @jeansnow: Fun 3-part history of consoles from TIME: http://t.co/sPpILgtIw5

  10. Glad to hear that you found a solution, but in a case like this I'd really suggest taking a look at bootstrap method. It's perfect for tasks like these, where you don't really want or need actual page, just code that can access data and/or features of ProcessWire.
  11. This is one of those situations where it would be awfully helpful to really see what's the full context, pages and fields you've got etc. but based on what you've posted here: That error seems to suggest that your second foreach loop (assuming it's actually on line 5) gets invalid argument, i.e. $bora->user_select_asset isn't something you can iterate with foreach. The main problem here might be the way you're trying to find users; try one of these instead: // this one: $borago = $pages->find("template=user, user_select_asset.count!=0, include=all")->remove($page); // or this one: $borago = $users->find("user_select_asset.count!=0")->remove($page); If that doesn't help, I'd suggest that you add a check before second foreach line, where you output something like var_dump($bora), var_dump($bora->user_select_asset) and/or get_class($bora->user_select_asset) just to check what you're actually dealing with. If echo doesn't work there, try wrapping the command with die() (or writing output to log file, here's one example for implementing that.) Also: make sure that all your variable and template names are properly written; for an example in your first post you mentioned template name "addAsset", while in your code you're trying to find pages with template "addase". Has the name changed or is it misspelled here?
  12. teppo

    Book Recommendations

    PRINT "I LOVE MY COMMODORE" You key in this and press RETURN I LOVE MY COMMODORE The computer prints this READY ▋ Admittedly this is a border case for a book-related thread, but I simply couldn't resist after todays comments in the admin theme thread: anyone remember that user manual C64 shipped with? The one that was part how-to guide for using C64.. but mostly an introductory book for Basic programming? Well, for those who do remember (or don't but would like to) it's available as an HTML version from lemon64.com.. and commodore.ca has even more of that same stuff in PDF format. They really don't make manuals like that anymore (probably for a good reason -- just imagine a modern PC or Mac shipping with C/C++/Objective C manual) but that's also one of the few manuals I remember reading from cover to cover more than once.. and actually enjoying it "Before you can use sprites it's important that you understand a few general things about how computers work.."
  13. I've just pushed to GitHub new version of this module. This update includes some minor improvements, such as storing version data for pages starting from the moment they're added, and as a bigger addition $page->snapshot() feature exactly as described by @SteveB earlier: echo "Page title now: {$page->title}<br />"; $page->snapshot("-1 week"); echo "Page title last week: {$page->title}<br />"; I've been working on and off this for a while now and actually had to write a bunch of PHPUnit tests just to make sure that everything works as expected (too many moving parts to keep track of manually.) There's still some work to do here and especially performance-wise more tests to be made, but at least this shouldn't disrupt how other parts of the module work
  14. That error is caused by the fact that you run this file without involving ProcessWire at all. You can't just run template file "standalone" and expect it to automatically load ProcessWire, you know Solution @horst provided above is most likely what you need here (or external / real cron job instead of this awfully limited scheduler thing you're using now). Then again, if this is the only reason you need that template, i.e. it doesn't need to be web-accessible, you could forget whole template and page thing and simply place a PHP file somewhere your scheduler can access (such as your PW root directory) and in that file bootstrap PW and write any program logic you need. Point your scheduler to that file and you're all set.
  15. +1 for "modern" for the reasons Adrian mentioned.. and because the "warm" color scheme gives me this nostalgic feeling I can't quite explain. It feels comfortable (kind of like 80's product design and advertising), but doesn't really match my image of ProcessWire as a present-day top-of-the-line software product
  16. minimize.pw (@minimizepw) is an image compression service for #ProcessWire. Commercial, but free for small-scale use.

  17. Some time ago, while debugging a misbehaving site, I found out that one user had a habit of hitting shift + enter at the end of each line in the editor. That made sense as an attempt to gain more control over the typography, but it also explained the situation.. especially since the site in question was responsive. Making each <br /> visible could've prevented that whole mess -- or at least made it easier to understand why it was happening
  18. PuPHPet seems very interesting; setting up web development environments via simple GUI: https://t.co/Rmkyk5JNRo

  19. RT @spinlock: Teaching my kid the ins and outs of iOS development. Lesson one: forming strong opinions and arguing on the internet.

  20. Agreed -- and I'd like to add that in some cases even the page names and/or titles themselves could be considered confidential data. I'm thinking about things like closed intranet for managers, working group discussions etc.
  21. @ryan: I'm not 100% sure that we're talking about same issue here, though I thought they would be related as symptoms are practically identical. Previous case where this happened was when page A had field that referenced page B.. which had a field that referenced page A. With page fields (strictly speaking fields where the value is instance of Wire) change tracking does something I can't quite grasp -- instead of answering the question "has field value changed", it seems to check if object that field references has changes. Different kind of circular reference issue, perhaps? Just to be very clear: apart from what this module was doing earlier, I've never had/seen any reason why page should be able to reference itself.
  22. Just for the record, similar issues have caused me a lot of headache over last month or so; the more I work with page references, more obvious it becomes that something is broken. Even though there's a way around it here (and usually in other cases too), I really hope that module authors wouldn't have to jump through hoops to achieve something that should be a no-brainer. Sorry if I sound a bit agitated, but having spent literally hours in my last module to hunt an issue down -- only to find out that it requires what I'd consider an ugly hack to get over -- has that kind of effect on me
  23. Soma: edited my previous post. Didn't see couple of latest posts until after writing that (and also misread some points), so you can simply forget most of that now.. By the way, Modules Manager Notification looks awesome!
  24. Edit: this message was written before reading posts above and makes no sense anymore.. weird things going on with cache, I think. Anyway, thanks Soma, problem solved!
  25. "The most unknown parts of PHPUnit". Just learned couple of neat new tricks. http://t.co/bVbphlIbjG

×
×
  • Create New...