Jump to content

apeisa

Moderators
  • Posts

    4,632
  • Joined

  • Last visited

  • Days Won

    55

Everything posted by apeisa

  1. Max number of folders depends on file system used: http://superuser.com/questions/66331/what-is-the-maximum-number-of-folders-allowed-in-a-folder-in-linux So if you use ext2 then your max folder count inside a folder is 32,768. In ext4 it is 64k but there is possibility to raise it. Currently these are probably also max number of pages for your PW installation.
  2. That would be great. But I think this is still little problematic. I think image fields should always return arrays, even if you only want to keep single image. That is because I think that is probably only place where tiny change in field settings ends up with errors. Perfect solution would of course be this (not sure if this is possible): $page->imagefield // returns array of images $page->imagefield->size(200,200) // returns first image in 200x200 size So if you don't loop or specifically say that you want other than first image, methods will always take first image. This way images would just work.
  3. Great, thanks for testing guys. Realized now, that probably no need for "image-crop" permission. Would it be enough to just use page-edit and set cropping permission based on that? Or do you think there could be need to disallow cropping, but allow editing? (vice versa is not even possible, since you need page-edit permission to view that editing page)
  4. This will be actually a problem with huge sites since Linux has folder limit at some point.
  5. I fixed this on latest commit. Just make sure that your user has permission "image-crop". Permission is created on install or you can create it manually if you upgrade. Also made few margin/padding tweaks, fixed one minor bug and once again fixed the mouseenter / mouseover bug. Chrome does need mouseenter and fox and others do require mouseover, so I check for both now
  6. Thanks Ryan! I think you had few too many superlatives there I have been amazed the speed how fast processwire has developed in last few weeks. It is hard to keep up and I haven't even tested repeater yet, not to mention field width... I think we will have enough to do with these all new features for the six week easily. So thank you about the great progress with PW, can't wait for possibility to show those features to clients and start building new stuff using them. It will be great if we have more stores build on top of this. It will be few weeks when I start building our first one and I think I have all the needed features for that. Probably will add some simple reporting in.
  7. Be careful. Scope can get easily out of the hands on what comes to full-blown ecommerce. Multiple payment gateways, Integration to accounting software / stock management app / ERP, custom reports, different taxes, personalization for different customer groups, discounts etc... What we will be using this module at our company will be for very simple needs. We will stay out of the very customized eCommerce, since that is pretty much own world.
  8. Sorry spoetnik, I missed this last time around. If you want to, then send me a private message with a download, I will take a look.
  9. I like both ideas. Also using some default kind of markup on markup modules would be nice. Maybe kickstart compatible?
  10. What I meant with customer accounts are stuff like "my orders", "my addressbook" etc. Granted, most of these things will be something that will never be in Shop core. I already tie the order and current user. So that is in certain way done.
  11. Very cool stuff Ryan. We will be moving to the new house this weekend so I don't have very much time currently. I can't wait to start building sites with all these great features available.
  12. Hmm.. Hard to say why it is giving that error, because that redirect is happening in init() method of an autoload module, so no real output could have happened before that from templates at least. Sometimes those are because of whitespace after ending ?> tag. How is your other code? Any other modules installed? Have any others got this running on MAMP? I myself have windows 7 with apache, mysql and php running locally. Do you get any more detailed error messages with debug=true?
  13. I think it all depends about your needs. There are lots of stuff missing what you might need. Like discounts, taxes, reports, customer accounts, PayPal integration etc... Then of course I need to check that I don't have any security holes. But the functionality that there is seems to work nicely. I recommend installing and testing
  14. Thanks Ryan. What I will do is probably this: I will use cookie wire_shop that keeps value which is initially same than the session_id (wire cookie value). If you login, then it will save your user_id to my active carts table and use that to identify you and your cart. If you don't login, but close browser and come back with new session, (but still with wire_shop cookie), it will look for active carts table, find your old cart and use that instead.
  15. There ain't such a thing by default. You can do template "settings", with fields like "Site title", "Copyright text" etc... and create one page with that template which keeps your "site settings" if you need to. But usually it is just better to hard code stuff like that to your template file. Site title is thing that rarely changes and if you have build your templates well, you need to change it from one file only. So in default site profile you would edit head.inc file and add your site title to <title><?php echo $page->title;?> - Site title</title> And welcome to the forums Lance! EDIT: This forum sometimes let you know about other replies before you, sometimes it just posts it :/
  16. Ok, now I get it... PHP itself uses cookies to keep session_id on client. And if client has disallowed cookies then it fallbacks to url-based session (which is disabled by default on PW). I somehow had believed that there is some other method how PHP session works, but good that I don't believe so anymore Thanks Yoda & Ryan! (But I have heard that power is so much stronger on the dark side?) I did some testing and it seems that PW uses session key called wire. But after login there is two cookies, wire & wire_challenge. Is that wire_challenge some hash that is calculated against user agent data? Can you share more information about how PW handles session security?
  17. Thanks for the reply. This is first time I encountered this too, so no need to make changes because of this. You are probably right about using cookies in this situation. Default lifetime for session is pretty short. Although I would probably want to fallback to sessions in that case, since some people have cookies disabled. Not sure about percentages, but last time I checked it was pretty high. Couldn't find very recent data, but http://smorgasbork.com/component/content/article/84-a-study-of-internet-users-cookie-and-javascript-settings (US, 2009 and 3.4% had cookies disabled). If someone knows more recent studies on cookie usage, please do share
  18. Good questions. I don't know Maybe install() saves the module first before executing any other code?
  19. Yep, gotta agree with guys. Very nice looking theme coming, keep up the good work!
  20. Not sure if I understood correctly, but this is what I do at ShoppingOrdersManagement (which is a process module): public function install() { $orders = new Page(); $orders->template = $this->templates->get("admin"); $orders->parent = $this->pages->get($this->config->adminRootPageID); $orders->title = 'Manage orders'; $orders->name = 'manage-orders'; $orders->process = $this; $orders->save(); }
  21. I have settled down using $session variable instead of superglobal $_SESSION. There is one big difference though. If user logs in then PW $session is lost and new one is acquired. I don't know if that is intended behavior? I realized this on my shopping cart module since people lose their carts after logging in. Of course I could start using $_SESSION here, but wanted to ask first if $session works right and if it does, why it is so?
  22. I guess it is something on these lines: $elem = $event->object; $elem->attr('value', 1306); Not tested though.
  23. Created first real payment method: https://github.com/apeisa/PaymentSuomenVerkkomaksut (It is most popular payment processor here in Finland). It was quick one, since they have good docs, REST api and even nice PHP Class.
  24. You do this on template: $session->error("error error"); or this on class: $this->session->error("error error"); End then on next page load you can have this: foreach($notices as $notice) { if($notice instanceof NoticeError) { echo "<p>$notice->text</p>"; } } And that error notice is gone, no need to clear it yourself.
  25. Yep. Although mention about these on session docs and on cheatsheet would be nice.
×
×
  • Create New...