Jump to content

Soma

Moderators
  • Posts

    6,808
  • Joined

  • Last visited

  • Days Won

    159

Everything posted by Soma

  1. That's what I got already. I add parent pages/branch they can edit to the user. It then is like a workspace. Other branches/pages then just don't show the edit/new actions, only view. Again it's like workspaces for language trees and other branches/sections, so I'm not defining it per page, but it can do it. So this is not an issue much. I'm not willing to release it as an official module. It's too simple and something I still think should be possible with PW out of the box. It's too specific, depends on setups like the roles etc.. so it would require much more to make it work well as a plug in and ready to go module. And since I'm not sure what PW brings in the future, I tend to not go so far and leave it as a simple "modifiy to my needs" hook module. But I posted the code example in the forum two times already. Here for example http://processwire.com/talk/index.php/topic,524.0.html
  2. I have a setup where I use a simple module to define editable page(s) for users via a page reference in the user template. The module has hooks after into Page::editable and Page::addable to then check for pages that are editable. This works fine so far. But how would it be possible to just show the editable pages in the tree? So other branches are not visible? I tried with a hook after Page::listable , then if it's the root node "/", it returns true. But the branches are still all listed. When I clik on one he has no access, it throw the exception. So is there a way I don't see, am I missing something?
  3. Hey, congrats on the module. This can be very useful I guess, will check it out soon.
  4. Hold on ... , usually he's much faster! ;D
  5. Hmm.. it just a normal process module extends process. On install I create a custom admin page using the standard admin template and add it to the admin folder. Nothing special here. I create a JS file with the same name as the module and it get's loaded automatic, just on top of the js scripts as the first. Don't know what could be different from others or special about it.
  6. Hey tsd, welcome to the forum! PW is designed to work flexible in many areas. Pages are, data objects, models what ever you call them. "Page" is more seen as an abstract term for what is a container for whatever data you want. I ust built a big webpage, 3 domains, 3 websites each in 2 languages trees all in one PW. And there's all kind of reusable stuff, central download elements for all languages zentral and also local, many different types of accordion elements (done with subpages) so you can felxibly create them and sort them the way you want. And it scales and works very well, all things are used the same way and once you get on how to set up various things, and know all the tricks, you can't beat it. It's not a workaround, it's how PW is designed to work. It just feels wrong but you have to get rid of thinking it's a workaround mainly. So it's right to use page reference to have elements on "homepage" for example. I see the way you want to go with the separate tree only for defining a navigation, will probably work very well, but why not use the structure to build the navigation. Though I think it's possible to use it like this, I think it could have some side effects on complexer sites. Though, I agree there's room for improvement as with all, also as it's still a young project. There will be many improvements here and there I guess, we soon will have things like flexible content elements on a page and many more to come. After a while you will realise it's not as a little software as you might thought. It's a Weightlifter in the body of a ballerina. So I like to discuss such things, and share thoughts an experience between users how different things can be archived.
  7. Yeah I used it in some projects too. It has many great features that can be used and the API is great. Since I knew already how it works, It took me only a few hours to get it fully working, combined with PW's selector API it's as easy as pie, though has some pitfalls, someone not so experienced will have hard time. Tell if you want my current version as a starting point. But it's very rough code still.
  8. yes, and in modules you can also use $this->pages->find(); $wire->pages->find();
  9. Yeah, it's fully ajax. Pagination, filtering, sorting... and it saves state, so if you come back it's on the same spot. It's very cool and fast. I see this as a great alternative to the page tree, when dealing with large lists of products.
  10. ProcessWire DataTable 1.0.0 (https://github.com/somatonic/DataTable) This module enables you to find and edit (fancybox modal iframe) pages at a small and very large scale. So far it has: ajax suuport masked pagination state saving (datatable using cookie, template filter using session) template filter (only showing templates user has edit access) search text filter (using title|body field) multilanguage support (PW's language translator) Superuser will see all pages and system templates. Users only those with view|edit access and pages in trash. This Module is still very simple and only in "lazy" developement and testing and this is the first official release mainly to get it out for others to see and use. It also could provide as an example/kickstart for someone. Everyone is encouraged to help and contribute to further improve or add features. The module is hosted on my github account: https://github.com/somatonic/DataTable The plugin used in this module is the excellent jQuery Plugin DataTable 1.8.2 - http://datatables.net/ I've chosen it, because I used in in some other web projects and was really happy about it's power and ease to setup. It supports jQuery UI styling, which makes the deal perfect for a ProcessWire module. Thanks and have fun trying it out. ------ (original post, kept for nostalgic moments) Ok, I started trying to implement the great jQuery dataTables plugin into ProcessWire. So far it works very well and is very powerful and fun. Best of it it support jquery themeroller. Not sure how far this all can go with configuration and how to define which pages should be displayed, what collumns etc... Many many things to consider. But if it could provide as an example on how to implement it, it would be great tool for site builders. Here you can see a short video of how it looks and works.
  11. Thanks, yes I know that already. But not quite what I was looking for. Problem is, modules that have a .js with the same name, as the module, will get added automaticly. So no need for -$config->scripts->add() and the like; .How I solve the problem (as I get to this point every time), is to add it manually using in the init or execute function, or using str_replace in hooks to get the desired location. I just thought it's strange it gets added before jquery core. I'm doing it now with renaming the .js file and using $this->config->scripts->add() in the execute function, which does add it after jquery core.
  12. How? I'm facing the same problem everytime I want to create a process module with a js. It will automaticly get added which is great, but unfortunately before jquery core. Is there a way say where it should get added? How is the order of them defined anyway?
  13. Great I'm sure I will have a run soon. Thanks Ryan for the great work. Now we have two "Languages" setup ... Olivers multilanguage module. Now, you'll have a look at the cheatsheet?
  14. I can't speak for Ryan, and I'm not sure. I guess it's to simplify things on not have endless dimensional for sake of the change tracking? Anyhow, can't you just use $_POST $_GET? Or are you really needing processInput? On a side note: Why doing quadruple posts? Please use the edit button to add things. Thanks
  15. Are you looking for this? $config->paths->root . $page->image->url;
  16. Good idea, thanks for sharing Nico. Not sure what the nofollow would do to your sites rank... I would also consider doing this as a simple hook on all/notall pages render. Have just looked a moment into code. Not sure, but wouldn't it remove existing classe ar attributes?
  17. Just will comment on this. I don't get what you mean. It actually IS in a folder. THe download is like "ryancramerdesign-FieldtypeMapMarker-09847d5" just rename it to "FieldtypeMapMarker", drop it in modules folder and your set.
  18. Thanks Ryan for including them, glad I could help and fix them finally. Whohooo my code is in the core! Feels a little proud.
  19. Thanks Ryan for adding it! Great, now after working on it the last couple days, I haven't really come to see how useful and great this is already... Good idea having a "simple/advanced" option would be great. Just not sure what would go where. I think I would need some help here deciding. As for undocumented functions and such. I didn't even started to look at what else there is to be found in the codebase, I just added all from the API pages. But there's already a couple things added that are not in the docs yet. Now looking at the code and seeing more and more that I discover I'm a little confused to what's intended to be used and what not, which are left out on purpose or by accident... or not have made it in yet. Also since I'm not very experienced in OO PHP and still not have the complete understanding how everything works together in PW core yet, I would be very happy to have you Ryan help me out there as much as you can. Though the nice thing is I experienced a boost in my understanding while doing this cheatsheet, as I'm now trying stuff out and looking at core more and again. BTW I discovered a method in Template: hasField(name|id|Field) . Which I didn't know but found could be useful to know. Just as an example. I added it to the cheatsheet in the next update.
  20. I'm a little confused. Further down you have the root tree "Home" and it has a "view" button which does the same. Though I see there could be a more prominent button somewhere visible, but this comes down to personal preference. Creating you own custom theme is so easy anyway in PW. There's a lot of thing that can be helpful. Anyway I yet have to find a CMS that makes it so easy and straight forward changing the whole admin theme and even layout and add widgets. This also is enabled only by the way it's build. Simple straight HTML/PHP CSS. Gotta love it everytime I think about it! This is something PW shines over all CMS' I know of.
  21. I couldn't have said it better Ryan. I was thinking the very same. It just makes me wonder, and wish to know to what reason is they're doing it. Is it may personal or just scared off of a newcomer sensing that many switch from Textpattern, Typo3, Wordpress, Joomla, MODX ... ;D
  22. I just checked on opensourcecms.com and PW is now on first place of worst-to-best list! With 1442 votings.... Bastards. :-\ --- Every few minutes a couple ratings more... Well how comes this doesn't surprise me much.
  23. Can you explain a little more about this and Wire/PageArrays in general? What exactly is the difference between PageArray and WireArray? I learned to use new PageArray(), to fill it with pages using import or add and do further manipulation.
  24. Thanks Ryan! Glad you like it. What do you mean put on API page? A link? No problem go for it. I rather see this as a official reference page wen the team will manage. I'm looking through your comments and implements those as soon as possible. As you can guess all what's there (except a only a few) are copied from the API pages. So if somethings not there it's most likely not on the API pages. If you don't mind adding them and note them to a text file, so I could easily look through them and add them. My plans: Make this as useful as it can get; complete, comprehensive list of all most basic and useful API stuff. So my idea is, this is a working prototype. I see this pretty soon to be a PW app! ( Fun! ;D) So from there PW team could add and manage themself. Make color codes for example to distinct get/set methods/properties is something I was thinking about and would like to do it but I'm not very save in that area when it comes to descide what is what. I would love if you could lend some time and may at some point implement it. If this would be a PW app, it would be easy. Change layout to floated cols and may have media queries to adapt layout to screensize (nice to have) My questions/comments: WireArray Here I wasn't sure, it looks like PageArray is the same? So I thought I'll just put WireArray for now. Selectors Here I'm really happy if you can help out getting them right. I wasn't sure how and what to put there. I'll have a go with you input. $templates $template Those are very confusing to me and may others too. While there is now: $page $pages $fields $field $templates $template ... You mean to separate them? Confusing may be that there's no "$field" variable, and also not a "$template" variable... those are meant to be in real like $page->template and $page->field_name. Or when one uses: $field = $fields->get(name); echo $field->name; I would like to have this more clear to new users, as this was what also confused me a little. General API It's great to see an overview of the "whole" API and I'm also surprized that there are still some I didn't know or know well, and some are still not there it seems. Also one may start to question why isn't there an $users $roles $permissons var? Thanks
  25. Thanks diogo I've just commited major update. Cleaned up some and added new features. - Added index collumn on left side - You can now toggle sections using the index - Also toggle show/hide all description of a category when clicking on blue titles. - It resets if you click on the table somehwere (white space) Hope you guys like the changes. -- I noticed that in mozilla, the live search filtering wasn't working after the changes i've done to it. I figured mozilla has no innerText, which is very practical to get content of a node but not subnodes. I had to use textContent, which returns all text including subnodes, so the search filter doesn't work as good as in other Browsers. May I find a way to work around it.
×
×
  • Create New...