Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 11/13/2014 in Posts

  1. It's about time this was pulled together as a configurable module. So here it is on github and in the module DB. You can configure a set of roles and a target redirect page under the module config. I've done very limited testing here - hence it being marked as alpha in the module DB - so please let me know if it works for you. A word of thanks to both Wanze and kongondo are in order as they pulled most of the material together that I used for this!
    4 points
  2. Brilliant - http://www.explainxkcd.com/wiki/index.php/Main_Page
    4 points
  3. So they seem to have fixed it by changing the PHP version... I still don't get why it was working one second and then down the next though. Here's the message they've sent me: I was able to resolve the issue on your site by adjusting it to run under PHP5.4. It looks like the issue was due to the php version, indication from the segmentation fault which is by definition an unhandled error most likely related to PHP and the set environment on the account. I'm not sure what version of PHP they changed from but have asked them.
    3 points
  4. The length for the field "pass" is 128. You can change this, by going to Setup->Fields, then click on the Filters and activate "Show Built-In fields". Now you should see the field pass. The length of the field can be changed under "Input". I agree with you that this limit might be set higher because it makes no sense to limit the password.
    2 points
  5. I have answered the question on that thread in case you missed it
    2 points
  6. Ryan explained somewhere that he designed the PW interface to be completely idiot proof He prefers that it's more difficult to do some actions but that data doesn't get lost.
    2 points
  7. Glad you got it sorted out. Useful to document this here, in case anyone faces the same issue in future.
    2 points
  8. I believe segmentation errors are related to the server? Don't really know since I've barely scratched that surface. What command do they run to get these errors? What pages (on the front-end) give the Internal Server Error? Try disabling your .htaccess and see if the homepage works.
    2 points
  9. I don't think there are any 'ready to go' solutions for this, mainly because hiding non-editable pages in a tree based hierarchy can be problematic. I'm digging up a quite old -but still relevant i think- thread with also some contributions from Ryan. https://processwire.com/talk/topic/1176-hiding-uneditable-pages-from-users/ If this is really needed i'm wondering if it wouldn't make more sense to keep such users out of the pages tree all together, and instead build a custom page where they can view everything the are allowed to, and nothing more. https://processwire.com/talk/topic/6142-hide-page-tree-in-the-admin/ Maybe someone else has some new insights on this subject.
    2 points
  10. It's always fun tweaking these things! This one's mine:
    2 points
  11. Posting Guidelines In addition to the rules, it is recommended that you read the following guidelines to get the most out of your interactions with this community. Interpreting other members’ posts Our community is a global community and as such posts and intentions can be misunderstood. If you encounter a reply that seems “short” and contains links to other topics that may answer your question, this may be due to the large number of members who use the forums on their mobile devices and want to help but don’t have time for a more complete reply or for whom English is not their first language. Please try and give people the benefit of the doubt when posting. Please do not dismiss their views out of hand (constructive replies are welcome). The forum language is English. We really appreciate the effort everyone makes from countries around the world to post in English. After careful consideration and experience on other forums, it makes sense to have one common language for discussion here so that ideas can be shared and not missed in language-specific forums - the same applies for debates that might get out of hand as we do not want to miss those either. There are more and more country-specific ProcessWire websites cropping up however so if you find that a group of you are in agreement and wish to set up a language-specific forum of your own then please feel free. Suggesting new modules/features Many of the features of ProcessWire have been born out of suggestions by users or discussions within the community, but that does not mean that every suggestion can be taken on board or that it might even be in tune with the overall strategy for the project. If you have suggestions for new features or modules, please feel free to propose them in a simple, open way in the Wishlist & Roadmap forum, but don’t be upset if no one is interested. Developer’s needs vary greatly. Your suggestion might well be something that is better developed as a third party module; in fact that is often the case. You are free to develop that yourself or work with others on a project, or even post a job to get help in the jobs board. However, whatever your idea or wish for a new feature, please do not make your suggestion sound like a demand, or tell the developers they have “got it all wrong,” or that you know what is best for ProcessWire. That is simply unfair to those who have been working on the project for free for years. Answering topics If you can help your fellow members then that’s great! Giving something back to the community in a constructive manner is always welcome. If someone replies in a topic you started and you think it is the best answer then please click the “Mark Solved” button at the bottom-right of the relevant post. Staff may mark a post as the best answer for you or change the chosen answer at their discretion if there is a better/more comprehensive answer later on in that topic. Some of the most prolific posters in the community do not count themselves at experts, but are very good at pointing new members in the right direction - you don’t have to be an expert in order to help out. Please don’t tell someone off for asking a silly question - there is no such thing! Every question is being asked because the person genuinely does not know the answer and might not know where to look. Raising issues or disagreements Nobody frequenting this forum should feel threatened when voicing their opinion as long as they are doing so constructively. Please be mindful however that everyone is unique and may interpret situations differently which could lead to misunderstandings. If you find that you disagree with someone, they may simply have a different point of view - this does not automatically mean that their view is wrong or your view is right. If multiple people disagree with you, it could be that a point has been raised many times before and/or that your point is not clear. Please seek clarification and remain calm or go talk about something else. If someone appears to be being simply argumentative, repetitive or belligerent in their replies then please do contact a member of staff and refrain from being drawn into the discussion further. To repeat, we are not solving world issues here, nothing is really so important that you HAVE to say something. If in doubt, say nothing and read another topic.
    2 points
  12. By default, the "Forgot Password" module is not turned on in v2.1. My thought was that lack of such a function is technically more secure (on any site or CMS). Why? Because having such a function active means your password is only as secure as your email (*though see note at end of this message). So I thought we'd start things out as secure as possible and let people adjust it according to their own need. But I'm rethinking that decision, and may change it to be 'on' by default. If you don't already have that "Forgot Password" module installed, it is relatively easy to reset your password with the API. Lets say that you lost the password for your account named 'admin' and you wanted to reset it. Paste this code into any one of your templates (like /site/templates/home.php in the default profile, for example): <?php $admin = $users->get('admin'); $admin->setOutputFormatting(false); $admin->pass = 'yo12345'; // put in your new password $admin->save(); …or if it's easier for you to copy/paste everything on one line, here's the same thing as above on one line: <?php $users->get("admin")->setOutputFormatting(false)->set('pass', 'yo12345')->save(); Replace "yo12345" with the new password you want and save the template. Then view a page using that template (like the homepage, in our example). The password for that account has now been reset, and now you are ready to login. Don't forgot to now remove that snippet of code from the template! Otherwise your password will get reset every time the page is viewed. Once logged in, here's how to install the Forgot Password capability: 1. Click to the "Modules" tab. 2. Scroll down to the "Process" modules. 3. Click "Install" for the "Forgot Password" module. That's all there is to it. You will now see a "Forgot Password" link on your login page. *ProcessWire's "Forgot Password" function is actually a little more secure than what you see in most other CMSs. Not only do you have to have the confidential link in the email, but the link expires in a matter of minutes, and PW will only accept password changes from the browser session that initiated the request. So an attacker would have to initiate the password change request and have access to your email at the same time, making it a lot harder for a man-in-the-middle snooping on your email.
    1 point
  13. Thanks for the input guys - it didn't seem to work in the admin.php template and, yes, the actual frontend template would be too late. For now, I edited the MarkupHTMLPurifier module and changed the purify() function around line 108 to this: public function purify($html) { $this->set('Attr.AllowedRel', array('nofollow')); return $this->getPurifier()->purify($html); } That works a treat I think it would be a relatively trivial task to make it so we can have config options with this module, so I might have a look into that over the weekend unless someone beats me to it!
    1 point
  14. First I want to thank you for this module, it's so easy to use. I added sitemap_ignore als global page setting. Therefore I changed ___install and ___uninstall. And I added two hooks to handle this: $this->addHookAfter('ProcessPageEdit::buildFormSettings', $this, 'addIgnoreXML'); $this->addHookAfter('Pages::save', $this, 'saveIgnoreXML'); The main functionality stayed unchanged. And I added some content to the ReadMe file Feedback welcome
    1 point
  15. Looking at the sources you seem to be right. The value gets saved already purified. But it should work when you place the snippet in admin.php in your templates folder An alternative way would be to edit InputfieldCKEditor.module in site/modules. Around line 262 the purifier is used and configured.
    1 point
  16. Here's a simple autoload module example that is part of the Blog module suite. And here's some resources. Have fun!
    1 point
  17. @Mary, Yes, you need to create an autoload module...You would need the other bits required in a module, e.g. the install and uninstall methods...Shout if you need any help..
    1 point
  18. @ Mary, Some freaky coincidence with the segmentation error? Just to clarify, there's only two instances inside PageEditFieldPermissionCustom.module where you need to rename 'PageEditFieldPermission'. These are on lines Line 24: The module class name - class PageEditFieldPermission extends WireData implements Line 115: wire('config')->paths->PageEditFieldPermission PageEditFieldPermissionConfig does not need renaming. Please test on a development server first
    1 point
  19. @Mary: do you have uninstalled the core module before you installed the CostumModule? There may be chance that are settings in the modules cache that need to be refreshed after you have deleted it manually. Does the Frontend work? If so, you can simply add a line of code to force a refresh of the modules cache: wire()->modules->resetCache(); If you also cannot use the frontend, you may simply empty the DB table named "caches". (Do not delete the table, but delete all of its records). If this doesn't change the 500 Error, do it again and also check in the table named "modules" around the last entries, (when sorted upon field created), if there exists an entry for your manually deleted CostumModule. If yes, drop that record. Now try to go to the admin again. HTH & good luck. BUT, BEFORE you start with manipulating the DB, please make a backup!
    1 point
  20. Might be worth opening https://github.com/ryancramerdesign/ProcessWire and comparing your index.php to the original.
    1 point
  21. Really don't like the look of '14fk4pd5jgte0811d.php'. Arjen beat me to it, but the file calling those files listed is the place to start.
    1 point
  22. Can they tell which file is calling those stat() functions? Can you reproduce the error notices yourself?
    1 point
  23. It depends on the exact needs but most of the time i use like this: http://modules.processwire.com/modules/batch-child-editor/ http://modules.processwire.com/modules/process-batcher/ http://modules.processwire.com/modules/process-page-field-select-creator/ http://modules.processwire.com/modules/import-pages-csv/ Not seldom i use them all in a project. They really go quite far as 'bulk' actions are concerned. I quite like the fact that it's not all bundled into the core features.
    1 point
  24. The module docs say: To specify custom settings to HTML Purifier, perform set() calls before calling purify(). So I guess something like this should work, if placed on top of your templates before you output your fields. $purifier = wire('modules')->get('MarkupHTMLPurifier'); $purifier->set('Attr.AllowedRel', array('nofollow')); I did not try this myself. If this doesn't work when placed in your template files I would try placing it in the admin.php in your templates folder.
    1 point
  25. I can confirm same behaviour for CKEditor 4.4.3 I also tried it with the native CKEditor link plugin. But I couldn't get it to work, either, other than switching off HTMLPurifier :-(
    1 point
  26. Hi jordanlev, could You provide a complete demo code, please? I would like to now how it works exactly.
    1 point
  27. I guess the "holy grail" here would be a coded system that would take the end user to the "RickRoll" video of Rick Astley anytime they try to copy your photos...
    1 point
  28. ProcessWire Forum Rules Version 1.1. Last updated November 10, 2014 Purpose of the Forums The ProcessWire forums are a self-help support forum where users can also contribute towards the future of ProcessWire. It is comprised of individuals from across the globe who want to help each other and who are giving much of their free time to do so. Many members have commented that the ProcessWire forums are exceptional in how equally friendly and hospitable they are to those who are very knowledgeable and those who are only just beginning to learn. A word about the rules The rules are here for the benefit of everyone. It says something about a community that we have not required any for four years despite the occasional heated debate. However, as the community has grown it seems only fair to create rules for both members and staff alike. Rules are not the same as laws. They are applied to each individual situation as the need arises and can be interpreted by the staff after reaching a consensus, where appropriate, or they may be enforced quicker in the case of situations requiring immediate attention or that are in very clear violation of the rules. Please respect the outcome of any decisions made by the staff. Rules for posting No Flaming. Never threaten the project, developers or other forum members. Threatening behaviour will be dealt with swiftly by staff and may result in a ban.. No Spamming. Spamming violations may result in your post count being reset, revocation of posting privileges, or even permanent banning from the site. There are several types of spam: Off-Topic posts outside the off topic “Pub” forum. If you wish to make an off topic post, please do this in the “Pub” forum. Multiposting. Multiposting is repeating the same message several times in the same topic, or, making a post directly after another, when you could have edited the additional comments into your first post. Multithreading. Multithreading is posting the same message in several different threads. If you do not receive a reply to your post, it may be that people do not have an opinion or are simply not online. Be patient. Unauthorized Advertising. Any unauthorized advertisements will be deleted and the offending member may be banned. Please note that linking to your company website is permitted in your signature as a plain text link. No discussion of politics or religion anywhere on these forums including the Off Topic boards - there are many other websites where you may discuss these topics. Please avoid very bad language. This is not an adult only forum so treat it as being family friendly. Please respect others’ opinions. Do not state that they are wrong and dismiss them in a derogatory manner. Please try and offer constructive counter-arguments when joining a topic containing a debate. If in doubt, don’t post. Please don't tell other people to go and search if they ask a question that has been asked before. If you like, inform a member of staff or a moderator via the reporting feature and we will do our best to merge it into a relevant topic, or you could suggest in a polite manner so as not to offend that they Google the forums via this link - just remember to be friendly as a link on its own can be mistaken for frustration or impatience. Please do not make demands of the developers of this project or of those who manage the forums. It is disrespectful to the people who give so much of their free time to this community Please contact us if you have an issue with another member or even a staff member - the relevant points of contact are at the bottom of this post Please respect the privacy of others. If a member chooses to use a pseudonym rather than their real name, that is their privilege. Please respect their wishes and do not out them even if their real name is common knowledge. Keep to one identity. Do not create alternate avatars and just stick to the one. If there are technical reasons why you need a new one (can’t rescue the old one, perhaps) be open about it. If you are angry about something, step back, take a breather and try to post a reasonable reply. If you feel that someone is being wholly unreasonable or stubborn, please contact a member of staff. Please try and use Common Sense. No set of rules can cover everything. If you think about what you are posting before posting, you shouldn’t run into any trouble. Remember, this is a forum about a software project, not world peace. It is doubtful ANY argument is important enough to be angry about. Please note that these rules may be updated from time to time. If you continue to use these forums it is assumed that you agree to them. Rules for using the Personal Message system The boards have a simple and unrestricted personal messenger - please use this responsibly. In addition to the above rules regarding posting: Please do not use the personal messenger to threaten anyone, tell them off or send a message that is likely to upset or offend. Please respect every member’s privacy and only PM someone if you feel they will be happy to receive a message from you. If you receive any messages that you feel are inappropriate, please contact a member of staff rather than taking matters into your own hands. Please do not copy and paste private messages into the public forums without the consent of the sendee. Actions we might take At the sole discretion of the forum staff and/or administrators, you may be given a warning if you break the rules. If the infraction is deemed severe enough, you will be banned. If you repeatedly break the rules or are belligerent in your response to staff/admin messages about an infraction then you will also be banned. If we do contact you it will be via the personal messenger system on the forums or, in the event of a ban, we will contact you via your registration email. We will not conduct conversations in public nor will we reply to any public conversations about a particular case. Points of contact If you have an issue that requires staff attention, in the first instance you should report the content using the “Report” link at the bottom-right corner of the relevant post. If you wish to, please contact a particular member of staff directly about an issue. If your issue is about a particular member of staff, please contact Pete and/or ryan via Personal Message. Please don't be put off by these rules. They are in place to help make sure that the site keeps its nice and friendly atmosphere. We're not here to rule with an iron fist - we’re here to discuss ideas and help one another, but we will act when people disregard the rules or ruin the atmosphere.
    1 point
  29. .inc is sometimes (including in the "Essential PHP Security", unless my memory fails me) considered bad practice, mainly because it has to be separately handled by .htaccess rules. If .htaccess fails for whatever reason, your .inc files are suddenly world-readable. Though a lot has to go wrong before this can happen (and even then it's usually far from critical), so far I haven't heard any compelling reasons to use .inc instead of fail-safe alternatives, such as .php (or .inc.php, if that .inc is somehow really important).
    1 point
  30. i would be very interested in that
    1 point
  31. Not sure if anybody else could have said that better in this objective way. <3
    1 point
  32. Just wanted to throw in my two cents. If you come at it as a front-end developer that's a complete beginner to CMSs, then PW should be very easy to get going. It's built around working the same way that existing web technologies work… Pages map in the same way that URLs do… Template files are just plain HTML/PHP files… the API is largely the same as a front-end API (jQuery)… and so on. So if you know your basic web technologies outside of CMSs, then you won't find a simpler system than ProcessWire. The problem is most other CMSs don't work that way. So the line gets more blurry when you've become used to the terminology and approach of another CMS, because PW can be quite different. Sometimes you have to unlearn what you know from elsewhere in order to appreciate the simplicity of PW. People are always trying to find complexity that isn't there, especially those that grew up on other platforms. PW is a system that rewards you by being curious. We aim to show you how to fish so that you can catch the big fish. We're not here to catch the fish for you. You don't have to know anything about fishing, but you should know how to yell for help if you fall in the water. And you should be willing to learn by example. I learn best by example, so this is the way I tend to teach too (and I recognize not everyone learns the same way). PW is a CMS and CMF, not a website builder. If you are curious and willing to explore, you'll find it is very simple indeed. Certainly far simpler than even WordPress in creating a custom website. You do have to come from the point of view of "I want to create and have the system adapt to me" rather than "I will create something based on what the system provides." If you already know what you want to create and it's something unique, you won't find a simpler path to get there than PW. WordPress is a different beast, in that it's basically saying "YOU WILL CREATE A BLOG or modify this blog and call it something else." Some people like that underlying structure… "okay, we're starting with a blog, what can we do with it?" Others do not like that underlying structure. Our audience consists of those that want to have a system support their original creation rather than mash up an existing creation. There was a PDF posted earlier that I think hit upon some good points, and I appreciate the effort that went into putting it together. The fictional character being scripted in the dialog is not our target. I can go into specifics if anyone wants me to, but I was definitely left feeling at the end of it that we have to be careful about hand-feeding too much or else we'll start attracting people beyond our support resources. Folks that want the fish cooked and filleted rather than folks learning to fish. Perhaps in time we will want to attract more of the consumer-type audience, but currently I don't know how to support users looking to find all the answers in a sitemap file. Keep in mind that unbridled growth is not necessarily desirable. Most of us don't get paid for most of the work we do here and we do best if we grow in a more healthy manner, attracting more thoughtful designer/developers that are here to learn and also contribute. Obviously the author of the PDF is one of the thoughtful ones (and the PDF is a great contribution), even if his fictional character isn't necessarily, but we'll welcome him anyway. But we will definitely be going through the PDF in more detail to learn and improve from it where appropriate, while keeping our audience in mind. I think we're doing something right, because our audience is growing rapidly. I'm nearly full time on ProcessWire now, and it's still difficult to keep up with everyone. At present, I like that our audience is largely open-minded, curious and thoughtful designers and developers. Somehow we've attracted an incredible quality of people and that's what makes this place great. We could not ask for a better group of people here. I'm reluctant to lead PW towards a website builder direction because I think that's when the quality of the community could go down, as people come looking to eat fish rather than learn, catch some fish, and throw some back. The reality is that part of our long term goals include converting the rather large audience that has outgrown WordPress into ProcessWire users. I'm convinced that we do that by giving them more ProcessWire, and not more WordPress. But at the same time, we always have to keep an eye on WordPress and learn. They've been lucky no doubt, but they are also doing many things right. So we have been and always will be working to make the WP-side of users more comfortable in ProcessWire, while also trying to help them grow by distancing them from the limited WP mindset.
    1 point
  33. It strikes me that a more accurate topic of this thread could be "how to make PW more beginner friendly." Not to make light of the OPs issue and invaluable insight but Ryan (and co) have already done an incredible job of making PW user-friendly. Maybe thats just semantics (user-friendly Vs beginner friendly) but I wouldn't say PW isn't user-friendly.
    1 point
  34. Sorry to interrupt but I finished another version of "GetStarted". I like it a lot more then he version before and got rid of the tooltips. Texts are copied from wikipedia and not final. What do you think? GetStarted2.zip Edit: fixed a minor install error.
    1 point
  35. woop, your pdf is great. It reflects the first thoughts a webmaster could have when he/she gets his/her hands dirty at pw for the first time! imho the critics at the installation part where a bit too much (I found the installation process pretty easy when I saw pw for the first time). What now would be great is if there was a second part of your document where you (or someone else) enlightens the reader how to take the next step (or at least where exactly to find the answers to your questions at the end of the first part). I know it was not your intention to take newbies by their hands with your doc. But when I read the pdf I can think of a lot of beginners who feel exactly the same way as you did. So they could indentify themselfs with you and (maybe) would follow the next steps in the second part.
    1 point
  36. @woop: Thanks for taking the time to do this - it's amazing and I think you're right in each of your points!!
    1 point
  37. Interesting discussion! I definitely think Processwire could improve its usability but I don't think plugins is the way to do it. I just did a clean install of PW 2.5 and documented each step in the process. Here's a .pdf with 44 slides that covers the scenario of a new user's first contact with PW: http://cl.ly/0e3V2M3w1z1B ​comments appreciated
    1 point
  38. It seems some devs are afraid that improving usability is quivalent to decreasing power and flexibility. In my opinion these things should and could go hand in hand, and are intrinsically not contradictory.
    1 point
  39. Nope its a CMF , a content management framework that allows you to make an easy CMS for your HTML Not being precise causes lots of frustration Wikipedia again: here we go , and btw. we are listed there. Quite a while ago drupal stated "we stay OOP free", then they added OOP step by step caused by pressure from outside. At last they are now based on Symphony framework. So Drupal once was special now its like any other crap around. So yess, i can understand that fear.
    1 point
  40. CMSs make hand coding by editors obsolete (as it was usual in the ancient times), thus allowing content to be published quickly and easy. That's what I understand from this sentence. I don't understand, that CMSs allow to build web applications (sites, apps) without coding skills. Even WP requires coding skills if you want to take it one step further (in fact, it requires much more coding skills than PW does ...) .
    1 point
  41. Guys, thanks for all the comments, hints, tips and encouragement to keep on trying. I appreciate that. Reading back I also notice I was rather grumpy last night. Sorry about that, I should not engage in these kind of forum discussions in the middle of the night. Being very tired I have a tendency to be much blunter than I normally am. Some people made the remark that modern website creation often involves some form of coding, more than 5 to 10 years ago. That's true, and indeed at the heart of my frustration. While my general site building skills have improved with the demands of the market, my coding skills lag behind. So the discrepance between what I CAN and what I WANT is becoming bigger. What I want is the more or less ready to use functionality of a CMS like WebsiteBaker, Joomla or Wordpress, combined with the flexibility and power of PW. My first impression was that I would be able to create custom stuff pretty easily, but after trying for a week orso I was disappointed. Partly in myself and my lacking skills, partly in my expectations that turned out to be too high (in relation to my skills), and partly in PW because a number of things are really not user friendly (enough) in my opinion. I do feel that PW could benefit from having ready to use functions/modules/profiles/whatever-you-call-them that can be regarded as absolute core functions of any website: regular pages, blog/news, form, gallery. I'm not talking about time management, full blown ecommerce, forum, or anything fancy like that. No one expects that in a core CMS setup. Just the basic stuff to build any regular informational website, like a typical small business website. It's not important if that would be part of the core, or separate addons, they just need to be readily avaliable without having to heavily edit underlying code. I don't see why that would harm PW as a developers framework. That aside, I do feel I need to PW another go, if I have the time. All comments have given me a new impulse to try again to overcome my own current limitations.
    1 point
  42. As i already stated its perfectly ok to say , nope no standards. As PW is a system that attaches to almost any thinkable HTML/JS Template in a perfect way its a great thing as it is. But if you think that way you have to make sure not to attract people from conventional CMS with false promises. First sentence on PW homepage. As it is its a CMF that allows you to build the custom CMS for your Template in an instance. Maybe we should even invent a new paradigm for this one, like PW is a new PFT CMF (Page Field Template) The PFT concept allows for extremely easy generation of content that integrates easily into your existing HTML/JS Template. That way designers can concentrate on designing and a developer can easily convert this design into a fully functional webapplication. The powefull selection engine completely removes the need for complex data models... ... The problem is that pepole(non developers form WP, Joomla..) expect a CMS and got really frustrated. As science found out , if you got angry about something you tell that to an average of 10 people thats a hell lot of bad publicity. So we better should advertise PW as a CMF and make people happy about finding how simple this can be instead of making people unhappy if they expect something like a normal CMS ...
    1 point
  43. Yep, so a newcomer can see at a glance the basic commands with output examples as well as a lot of working snippets in one place. Ideally everything with only basic styling and with the pw version number, when it was written / updated. If one needs more reading material one can look in the forum, if one needs less one can look at the stylesheet. Something for every level
    1 point
  44. Quick hint: already saved snippets.pw and trying to create a blog/snippet collection so you get easier into pw. But it's only a concept at the moment.
    1 point
  45. I just wanted to remind that this discussion originated in the question how to get PW more widespread. Its a decision to say No this is a framework this stays a framework but this will completely stop availability for mass users, then it must be advertised a as a framework and not as a CMS. That would be perfectly ok. Its a decision that is up to Ryan. Having no options for commercial templates that can link into it is a big minus and no way to build modules that rely on a few standards and can be easyly installed inside the basic installation will stop quite a lot of professionals. The most wired thing is that with a few minor standards all this problems are solved. I hope you read my previous post about templates and modules ? The is no change in PW core necessary at all, just a better default Profile, and a few minor modifications on some modules to make lots of pepole happy whith PW. And i really would like to see PW becomming as popular as WP, Drupal or Typo as its the far better solution.
    1 point
  46. Dear Processwire folks. For me as a non coder, this is a very important discussion, therefore I would like to add my 2cts for your evaluation. What I would really love to see in PW is a one page code documentation, just like the twitter bootstrap docs. A page with just some basic styles so that any newbie, or non coder can see at a glance which code does what! Something like this: INCLUDE HEAD (OR OTHER EXTERNAL PHP FILES): ************************************************** php include ("./head.inc.php"); _________________________________ NAVIGATION WITH DROPDOWN: Home | Page 1 | Page two Dropdown 1 Dropdown 2 ************************************************** php $ function bla bla _________________________________ DISPLAY IMAGES: image-1.jpg Image-2.jpg ************************************************** php $ foreach bla bla _________________________________ DISPLAY FIELD(S): Example Field title Eample field body ************************************************** php $ echo bla bla _________________________________ And then of course more advanced stuff. In fact, if there would be a simple styleguide, many developers could contribute to this document over time. If one has made something fancy and wants to share it, he or she can submit the documentation code to a moderator who adds it to the document. Please, what do you think about this?? Thomas108
    1 point
  47. The funny thing about standarisation is that, if done well, you don't need much of it. Lookt at the templates: Just have a default instalation that uses Ryans main.php in your templates and you are done. Now modules can create template files that bring their default formating into the main page. Now for the modules: For the modules the only standard must be, if you create template files you have to put the name of the module in front of the file name like: blog_display_categories.php. If those template files already exist then don't overwrite as the template designer already made some files for this module. Does someone really thing this would kill PW ? Using main.php ist the better way anyway. What it does is, it opens a whole new world of exchangeable templates. If you do this little standarisation you can create modules that work like new pepole would expect . Another few things that should be done:(At least in my opinion). Have a simple stripped down version of the commercial Form module(Form generation is an impossible nightmare for users and not being able to make a contact form is a killer criteria) Have a default install whith a nice looking full featured basic template If we modify a few modules to comply to the Standard above we don't even need many additional modules in the default install . Just a nice made basic page whith some features. And again it would be extremely helpfull if Ryan would extend his Profile module so it can save a full installation as profile. That would make creating a ful featured CMS out of PW extremely easy. That way it could even be a community project. Right now creating fully featured Profiles looks like a lot of work(users, language support...), correct me if i am wrong.
    1 point
  48. Continuing from my previous post in this thread about some selector enhancements available on the dev branch, we've got a couple more advanced options for use in selectors in case anyone is interested: OR-groups These let you specify multiple expressions and only one of them has to match in order for the selector to match. It's a way of saying "either this has to match OR that has to match". This is useful because selectors always assumed AND – meaning everything has to match. While you have always been able to use the pipe "|" to specify ORs for fields or values or both, the scope of it was just that field=value statement only. Now we have something new called OR-groups. These let you create multiple selector groups and only one of them has to match. You can specify OR-groups by surrounding selectors in parenthesis. An example demonstrates it best. Lets say that we wanted to find all "product" pages that were in stock, and either in a featured date range, or had a highlighted checkbox checked. Previously we would do like this with two separate find operations: $items = $pages->find("template=product, stock>0, featured_from<=today, featured_to>=today"); $items->add($pages->find("template=product, stock>0, highlighted=1")); Now we can do it in one find operation: $items = $pages->find("template=product, stock>0, (featured_from<=today, featured_to>=today), (highlighted=1)"); Above are two selectors surrounded in parenthesis. Only one of them has to match. You can specify as many of them as you want. This type of OR expression is something you couldn't previously do with selectors. Think of the parenthesis as a way of saying "this is optional". But of course, at least one of your parenthesized selectors has to match in order for the full selector to match. I'm guessing the above usage probably covers 99% of the situations where you might need it. But lets say that you want to have different combinations of OR expressions. You can create named groups that OR with each-other by specifying: foo=(selector1), bar=(selector2), foo=(selector3), bar=(selector4) In the above you'd replace "foo" and "bar" with names of your choice. And you'd replace the "selector" with any selector strings. Those foo/bar names aren't referring to fields, instead they are just named groups that you can name however you want. In that selector, at least one of the "foo" named selectors would have to match, and at least one of the "bar" named selectors would have to match. If you didn't use the foo/bar named groups here (but still used the parenthesis), then only one of the 4 selectors would be required to match. Sub-selectors Some of you are already familiar with these because it was committed to the dev branch a couple weeks ago (and I think may have been outlined elsewhere in the forums). Sub-selectors let you put a selector within a selector, enabling you to perform more complex matches that used to require you to use separate API calls. These can be used on the 'id' property of any field that maps to a page. The 'id' property is assumed when referring to a page reference or a parent, so it's not necessary to specify it unless you want to, i.e. "field" and "field.id" mean the same thing in this case. Sub-selectors are specified between [square brackets]. For example, lets say we are matching products and our product template has a "company" page field. Each company also has it's own page field where all the company locations are identified. Lets say we want to find all products that are made by a company that has more than 5 locations and at least one of those locations has "Finland" in the title. Previously we would have had to do it like this: $companies = $pages->find("template=company, locations>5, locations.title%=Finland"); $items = $pages->find("template=product, company=$companies"); That's easy enough. But now it's even simpler, as you can do it in one operation: $items = $pages->find("template=product, company=[locations>5, locations.title%=Finland]"); When you've got a "field=[value]" selector, any properties you refer to in "[value]" assume the "field", so "locations" above is referring to a property of the "company" field.
    1 point
  49. Wanze. Thanks for sharing this (and to Reno for asking the question!)! Everyday I continue to be awestruck by the simplicity, cleverness and power of ProcessWire. With about 11 easy-to-follow lines of code, without touching the core, without bashing the system into submission by throwing all sorts of plugins at it and without compromising security and future updates, this opens up a whole new world of possibilities all at the drop of a hat.....Fantastic!
    1 point
×
×
  • Create New...