Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 08/07/2014 in all areas

  1. hi guys, i'm happy to show you my first project realised with processwire and to say hi the first time here in the forum, although i have been reading, following, learning and liking around here for some weeks now the reason why i did not post any questions is quite simple: all answers for my questions have already been posted (and answered) in the forum/wiki/docs - really great! let me also say thanks to gebeer, who forced me to take a second look to processwire (coming from joomla/seblod and thinking processwire is not worth the effort of changing from a well known system - i was so wrong ^^) So what is "GeoWire"? (http://www.geowire.org) GeoWire is a web mapping tool for creating and sharing web-maps. It's a bit similar to google maps, but you can put your own maps (also all the google layers) and overlays into it and create your own functionality with javascript. First it was a "static" HTML/JS project but within the weeks of development gebeer told me about processwire. So in the end i had my HTML/JS web map viewer ready and thought how great it would be to manage all the code snippets directly on the server with processwire as GUI - you could easily copy your map collocations, drag and drop layers in the layer tree, drag&drop buttons in the toolbar and so on... 2 days later i had the first working prototype ready!!! PW is just wonderful, thank you Ryan+Team! Today i - finally - finished the video tutorials for GeoWire which i published as an open source web mapping tool. Oh man, that sounds so arrogant for me - i'm not a professional developer and i know it is far from perfect, but at least i wanted to give it a try . I would have also put it to GitHub, but i have no experience with it till now and so it was too complicated for me. I hope I am not violating PW by providing GeoWire for download on my website geowire.org? I don't even know if anybody is interested in geowire at all, but maybe it can at least serve as starting point for any other similar projects... any feedback is appreciated. Here is the demo: http://www.geowire.org/demo Maybe you're interested in the videos: The Backend: http://www.youtube.com/watch?v=8sgq8GPYDYo How it works: http://www.youtube.com/watch?v=vxMtAQsKESY How it works in short by an example: The mapPanelToolbar makes this out of that using that code snippet, /* ######################################## ######## mapPanelToolbar.js ######################################## */ Ext.onReady(function() { mapPanelToolbar = Ext.create('Ext.toolbar.Toolbar', { dock: 'top', items: [<?php foreach($page->children as $child) { if($child->include_file) { include('GeoWire/include/'.$child->include_file); echo ','; } echo $child->include_direct.','; } ?>] }); }); that is recursively loaded by the processwire template // create javascript app file from all included code snippets ob_start("makefile"); // include all children of current page foreach ($page->children as $child) { include_file($child); } ob_end_flush(); function makefile($buffer) { if(!wire('config')->dev) { include('GeoWire/JSMin.php'); $buffer = JSMin::minify($buffer); } // take first map if it is homepage $pageid = (wire('page')->id == 1) ? wire('page')->child->id : wire('page')->id; file_put_contents("GeoWire/app".$pageid.".js", $buffer); } happy processwiring and good night Edit: Do you think something like this would be possible or even better put into a module? I know my first version of geowire will soon be outdated as it uses PW2.4 as core, but for the time it was the best way to go and to be honest, i don't know when/if i have the time/motivation to develop this project in future...
    10 points
  2. Wayne, thanks I think you've done a good job of outlining the issue. Before we attempt to fix it by requiring a re-translation of existing terms, I thought we might try to solve it by making the order of terms translatable. Could you (or anyone else that wants to try) try replacing this line in /wire/core/Functions.php: return sprintf('%s%d%s%s %s', $prepend, (int) $difference, $space, $period, $tense); // i.e. 2 days ago (d=qty, 2=period, 3=tense) With these lines: $quantity = $prepend . $difference . $space; $format = __('Q P T', __FILE__); // Relative time order: Q=Quantity, P=Period, T=Tense (i.e. 2 Days Ago) $out = str_replace(array('Q', 'P', 'T'), array(" $quantity", " $period", " $tense"), $format); if($abbreviate === 1) $out = str_replace("$quantity $period", "$quantity$period", $out); return trim($out); Then translate the /wire/core/Functions.php using the Setup > Languages > Translation tool, and adjust the order of Q, P, and T in the translation engine according to what makes sense with the locality. For instance, it German it sounds like it should be: T Q P. I'm curious if this solution resolves the issue or if further changes might be necessary. Thanks.
    7 points
  3. Don't Show API Form Labels (If I may add this here for the sake of completeness.) I have been looking for a way to leave the label out of the markup that does not involve recreating a module (a silly thing to do). The solution we have been using up until this point was a blank label. (Resulting in unnecessary markup and a negative margin.) However curiosity took me to the Inputfield module. Hey great job on these fields BTW. Reading the file I came across these options. const skipLabelNo = false; // don't skip the label at all (default) const skipLabelFor = true; // don't use a 'for' attribute with the <label> const skipLabelHeader = 2; // don't use a ui-widget-header label at all const skipLabelBlank = 4; // skip the label only when blank // wire/core/Inputfield.php Found in: in Inputfield.php The best solution I found to use this in a form builder. (I would like to credit this to somma's comment on checkbox-other-text-in-header-than-label-text) //controller.php $submit = $modules->get("InputfieldSubmit"); $submit->skipLabel = Inputfield::skipLabelBlank; //HERE IS THE SOLUTION! $submit->attr("value","SUBMIT"); $submit->attr("id+name","submit"); $submit->attr("class","button"); $form->append($form_submit); Thank you Somma! Thank you Ryan!
    6 points
  4. I'm not sure but i think your out of luck with a Datetime field. As far as i know this will always require some form of date input, not just a year (which of course isn't a date). Maybe someone who has done more with Datetime fields can verify or prove me wrong. What i would do however is simply make a field of Type = Text. When you have saved the field you can go to the Input tab and use a pattern of your liking. For example if you wanted to only allow years in the range 1900-2100 you could use a pattern like this: ^(19[0-9]{2}|20[0-9]{2}|2100)$ When a customer tries to enter anything that falls out of this range and hits save there even is a nice client side inline error message (in capable browsers) or else there will be server-side validation. Of course, you should make a regex that suits your needs. You will be able to sort pages according to year via such a setup, in the page tree as well as on the front-end using PW selectors. EDIT You can also use the Integer type, where you can optionally set (on the Input tab) the Numeric Input Type to Number (HTML5) and set a Minimum and Maximum Value. This gives a nice input to the customer and with the same nice html5 validations. The Integer type might be preferable, because of the nice input but also database efficiency.
    6 points
  5. If you all read and review carefully, you'll notice that Ryan has not posted but has "Liked" many comments and replies here. He is very well aware of your opinions and wishes - as he always has!!! He's the one that adds all the valuable core necessities. I think it is awesome beyond awesome that we have such a leading developer that tailors HIS project to OUR wishes. The idea of templates and site profiles is a good one. They already exist! Not as simple as "One Click". But if you are a developer, designer, web oriented tech savvy person, it's just as simple to download a site profile and extract into the appropriate folder. This "One Click Theming" idea was made insanely popular by the folks that made WordPress, and frankly it is something that ProcessWire should probably avoid! Personally: I don't need it. I don't want it. So far, every ProcessWire site I have created has been 100% totally custom. The ONLY thing that I have reused or duplicated is my beloved Foundation CSS framework. Other than that, the sites are completely different, different jQuery plugins, different ProcessWire modules, different everything. When I think of templates, I think of these: http://foundation.zurb.com/templates.html If Ryan and the rest of the ProcessWire team should lean towards the way of offering templates and themes, then they should offer a small variety of layouts with different content. A generic Blog template could have title, author, publish date, summary, images fields, etc. with comments or without?! A generic Orbit template could have title, image url, image description, etc. for various images. A more advanced Realty template could have address, phone numbers, map coordinates, various images, etc. A search feature. A simple drag and drop prior to installation. And then when installed, all the fields and templates would be prefixed with an easy to distinguish name to connect them all together, so noobies can see how it all works. There are so many ways to do things in ProcessWire (it's a beautiful thing - ain't it?). Templates and themes shouldn't be any different. Keep it out of the core. Contributing users can offer their own site profiles (as they already do on girhub/elsewhere). Provide a nice interactive click through demo on their own site, or demo.processwire.com/template=?XYZ
    4 points
  6. Thanks! I don't have the time to finish this right now (going on vacation). I did manage to put together a basic parser in case anyone else is interested. Feel free to continue from here. I'll put together a full migration script when I find more time $disquscomments = simplexml_load_file('disquscomments.xml'); # All threads foreach ($disquscomments->thread as $t){ echo $t->attributes("http://disqus.com/disqus-internals")['id']; echo $t->forum; echo $t->category->attributes("http://disqus.com/disqus-internals")['id']; echo $t->link; echo $t->title; echo $t->message; echo $t->createdAt; echo $t->author->email; echo $t->author->name; echo $t->author->isAnonymous; echo $t->author->username; echo $t->ipAdress; echo $t->isClosed; echo $t->isDeleted; echo "<hr>"; } # All comments foreach ($disquscomments->post as $c){ echo $c->attributes("http://disqus.com/disqus-internals")['id']; echo $c->id; echo $c->message; echo $c->createdAt; echo $c->isDeleted; echo $c->isSpam; echo $c->author->email; echo $c->author->name; echo $c->author->isAnonymous; echo $c->author->username; echo $c->ipAdress; echo $c->thread->attributes("http://disqus.com/disqus-internals")["id"]; echo $c->parent->attributes("http://disqus.com/disqus-internals")["id"]; echo "<hr>"; }
    4 points
  7. Hi I am just testing the Blog Module as an add-on to an existing PW site. So far so good. It seems robust, why wouldn't it be - it's Processwire Installation is easy. When you install the module it chucks the required templates into the /template/ folder and adds the templates and fields to the admin. There is a separate admin area with a dashboard for the blog. I'm messing about with the styling which is easy - just change what you want in the blog.css. Comments, categories, tags etc are simple to maintain. This is currently on localhost and I haven't finished testing yet but this is what I have found so far. I hope it helps?
    4 points
  8. Yes this should be possible. Have a look at this thread - Is It Possible To Add A 'comment' Programmatically? The only thing you need to do is write some code to parse your XML and use the API functions to get pages, but certainly doable
    4 points
  9. Maybe this could be a new third party plugin for the Migrator module (https://github.com/adrianbj/ProcessMigrator) If you haven't seen it already, the first plugin for it is Nico's MigratorWordpress (https://github.com/NicoKnoll/MigratorWordpress) which also converts XML to JSON for use with Migrator. I'd be happy to help if you have any questions on how to implement.
    3 points
  10. So which option did you take? Text as well as Integer both are fine, but Integer might make more sense. If you chose the Text solution and use the regex of blad i would still add assertions for start and end of string to that, because if you literally copy/pasted that, customers would be able to enter something like '09201409' into the field. Of course this might be obvious to you. ^(19|20)\d\d$
    3 points
  11. Love it Read the site, looked interesting. Clicked on the join the CAcert Community link, and.... The site's security certificate is not trusted! You attempted to reach www.cacert.org, but the server presented a certificate issued by an entity that is not trusted by your computer's operating system. This may mean that the server has generated its own security credentials, which Chrome cannot rely on for identity information, or an attacker may be trying to intercept your communications.
    2 points
  12. I've done something like that in building a menu based on search results. In your case you could generate the sitemap but only show an item after a check if it exists in your search result. More in detail: You can create a basic php array from the sitemap as well from the search result with page id's. Then, showing the sitemap you could check for every item with php function "in_array" if the page id exists in the search array and only then echo the item. Worked perfect for me in a travelsite I built where people first choose a sort of trip. Based on the choice the site is searched for that type of trip (multiselectfield in every page) and after that a two level menu is created based on parts of the world and countries. So: part of the world - country - trip, more or less the same as your main - sub - page. Hope this gives you a direction.
    2 points
  13. @diogo Has that not (almost) always been possible? From http://processwire.com/api/selectors/ - title|body~=sushi tobiko - seems to have been there a long time if memory serves.
    2 points
  14. This is working for me in the latest dev! $pages->find("id|parent=1236|1244|1264|1768|1456") The pipe is working also on the left side of the operator. When did Ryan add this? I completely missed it! :)
    2 points
  15. I use Artisteer myself in combination with Processwire. Just export your design as basic website template. If you, before you export, put basic explanatory texts in your Artisteer design where you want your PW fields or menu appear, it is easy to replace them later with a normal editor with the necessary php from the PW API. But this will help no matter which design tool you use. Change the extension of the files from .html to .php and add the pagefiles to the site/templates directory and in the admin add them as templates (Setup - Templates). After that you can add the necessary fields to the templates (select the template for editing and click Add Field). Next step is to call the fields with php in your pagefiles in the places where you have put the explanatory texts. Don't forget to edit the includes in the head tag as well according to the PW instructions. With one page design in Artisteer you can now, through the PW admin, add multiple pages to your site. Much more to say about this but I hope this basics help you get going.
    2 points
  16. The example of @SiNNuT works with 20th / 21st centurys, Simpler and shorter (and 20th / 21st centurys): (19|20)\d\d Only 21st century: (20)\d\d
    2 points
  17. I'm not exactly sure what you're thinking "combine" means here, but this field does exactly what the description says; it grabs data from other fields, mashes it all together into one big blob of (JSON) content -- and that's just about it. One very simple (yet sometimes very practical) use case is if you've got, say, 15 different text fields and you need to find pages that contain value "john doe" in any of those. Instead of doing this: $john_does = $pages->find('field1|field2|field3|field4|field5|...|field15%="john doe"'); .. you can create a cache field, select all of those fields to be cached in it, and then do this: $john_does = $pages->find('my_cache_field%="john doe"'); Not only does this look clean, in certain situations it can wildly improve query performance.
    2 points
  18. Introducing ProcessDiagnostics and it's helper module suite. (Is this ProcessWire's first community-created module suite?) Description This suite adds a page under the setup menu that displays information about your installation. Each section's data is provided by a specialist diagnostic helper module but it is all collected and displayed by ProcessDiagnostics. The ProcessDiagnostics module itself does not encode any knowledge about what makes up a good or bad setting in PW - (that's done by the helper modules) - but it does the following... Gather the diagnosics (thanks to PW's hook system) Display the collected diagnostics Provide helper functions for describing some common things Dispatch actions to diagnostic provider modules (again thanks to PW's hook system) And eventually it will: Allow control of the verbosity of the output Allow the output to be emailed to a sysop Store the results between visits to the page Detect differences between results at set times Send a notification on detection of changes Although I am curating the collection, anyone is welcome to fork the repo, make changes in a topic branch, and submit pull requests. I've already had submissions from horst and Nico. Diagnostic Providers The current diagnostic providers include... DiagnosePhp - Simple diagnostics about the PHP envirnoment on the server DiagnoseModules - An ajax based module version checker by @Nico DiagnoseImagehandler - Lets you know about GD + Imagick capabilities by @horst DiagnoseDatabase - Checks each DB table and lets you know what engine and charset are in use DiagnoseWebserver - Checks the webserver setup DiagnoseFilesystem - Looks at how your directory and files are configured and warns of permission issues (currently incomplete) There is also a bare bones demonstration diagnostic module... DiagnoseExample - minimal example to get module authors started. Translations English & German (thank you @Manfred62!) Help translating this suite to other languages is always welcome. On The Net Check out Nico's blog post about this suite on supercode.co!
    1 point
  19. Hello, I created a simple REST helper in order to create REST APIs with Processwire, without depending on external routers Here you go!. https://gist.github.com/clsource/dc7be74afcbfc5fe752c
    1 point
  20. This Textformatter module for ProcessWire enables you to break up a single textarea field (using either TinyMCE or CKEditor) into multiple pages. You include all of the content in a single rich text field and separate each pagination with a line of hyphens (5+). When rendered on the front-end, the user will see pagination links at the bottom of the page enabling them to move forward and backward through the content/article. Also included is the option for title pagination. That means assigning a title/headline to each pagination and giving the user a list of those titles they can click on to move to each section of the article. Example of this module in action Documentation and customization options GitHub Page Module Page Download ZIP Install class: TextformatterPagination
    1 point
  21. I'm starting this topic for a problem I see with the German translations of relative times. But other languages may be affected as well. You can see the problem when the Lister module shows a column with a past date. In English it says "3 years ago" and in German it's translated to "3 Jahre vor". But it really should be "vor 3 Jahren". The phrase is constructed with the single translations of "years" and "ago" in the same order as it is in English. So the problem is about grammar and word order in the German translation. Maybe it could be solved by a list of translatable phrases with placeholders, so that it looks like "%d years ago" or in German "vor %d Jahren". That is just a quick thought and it probably should be discussed here before it is posted as an issue on github.
    1 point
  22. @zwergo, I took the freedom to correct the links in your post, the "watch?v=" part was missing. Hope you don't mind.
    1 point
  23. Btw, you links to the demo videos here lead to 404s...the ones on your site work just fine...
    1 point
  24. Hi, In the travelsite I have taken a little different approach. I'm just a sparetime php scripter, so I'me sure the more experienced ones can simplify the following code or come up with a better solution. I've changed what I use a little bit to fit your situation. If there would be more levels of pages a recursive function would also be better I think. $selection = $pages->find("your search"); // check if there is a search result if(count($selection) > 0) { foreach($selection as $selected) { // get id's of found pages #selectionid[] = $selected->id; // get id's of parent pages $firstparentsid[] = $selected->parent_id; // get parents for next foreach $firstparents[] = $selected->parent; } foreach($firstparents as $first) { // get page id's of next level $secparentsid[] = $first->parent_id; } // combine all id's $all_ids = array_merge($selectionid , $firstparentsid , $secparentsid); // remove double results $all_ids = array_unique($all_ids); } In my case where I use this in the travel site to build menus it's different from your case because my mainmenu and submenu are build seperately (different templates) where a sitemap has to combine the different levels. In your case you can check if the pageid of a link is included in the $all_ids array before printing it in your sitemap. I have a sitemap in the travelsite for which I use the listChildrenTree function in this topic: https://processwire.com/talk/topic/1886-submenu-with-overview-links/ It should be simple to add a check with the array to the echo statements.
    1 point
  25. ahhh, ok, thank you! i got it now and it works!
    1 point
  26. I see, the 1 you insert is a preset, but it doesn't have the "remove spaces before colons" turned on by default. You need to replace the 1 preset with all the individual parser attributes you want, so it might look something like : qDe:-;-
    1 point
  27. I wonder if PW becomes vulnerable to the XML Quadratic Blowup Attack (as Drupal and Wordpress were), in connection with XML-RPC... src: http://mashable.com/2014/08/06/wordpress-xml-blowup-dos/
    1 point
  28. Yes...read Ryan's reasons from here downwards...especially post #27
    1 point
  29. Or you can just use PocketGrid CSS (grid system only) and have any number of columns you want...
    1 point
  30. You would need cache field per template. If your "parent" template and PageTable template has same searchable fields, then you would be good with one cache field. Although I am not sure if one field would go in either way (if it just skips the fields that are not interested template then one field works). Anyway, both of your templates need cache field attached, selector could be something like "(cachefield%=$q), (PageTable.cachefield%=$q)". Parenthesis make it Or selector, so it would be enough either of selectors match, no need for both to match.
    1 point
  31. @appeisa, you're right of course. Already corrected it.
    1 point
  32. We really had a long discussion about it. I think it won't change at least until 3.0 anymore
    1 point
  33. To avoid adding all the fields (and also making your search faster) you should use cache field: https://processwire.com/talk/topic/5513-fieldtype-cache-please-elaborate/ "Sub sub fields" are not available, but subqueries should do it: pagetable.repeater=[subsubfield%=$q]
    1 point
  34. hey joer80, Did something very similar to this recently. This link may be of some help.
    1 point
  35. Let me ask a basic question than. Can I use a theme designer, such as Artisteer, export it as an HTML website and then edit it so that it connects up with Processwire?
    1 point
  36. This is what soma is talking about: https://processwire.com/talk/topic/6605-module-textarea-preview/
    1 point
  37. Therese already One I zhought by owzim?
    1 point
  38. That's not the link Sparrow is referring to; This is the broken one..(further down that page)...there's some extra stuff in the URL in the link to the Skeleton CSS Framework.. Markup and styles based on the Skeleton boilerplate CSS framework.
    1 point
  39. new german updates for actual PW dev 2.4.10 (06 August 2014). Zip contains only updated/added files (in comparison to the default 2.4 lang pack). updated files: wire--modules--process--processfield--processfield-module.json wire--modules--inputfield--inputfieldckeditor--inputfieldckeditor-module.json added files: wire--modules--process--processfield--processfieldexportimport-php.json pw-lang-de-dev-update.zip
    1 point
  40. Hi Sparrow, Wow, it seems we are not doing a good job advertising what's already available in ProcessWire .... There's already two Blogging solutions (actually one is just an extension of the other...) 1. Blog Profile: http://mods.pw/2M 2. Blog Module: http://mods.pw/6U They both support commenting (though not threaded comments)....For any specific help please post in their respective forums...
    1 point
  41. That's not to say PHP isn't messy or inconsistent at times (probably why I get on so well with it ), but it is good.
    1 point
  42. I want to like this post multiple times but the forum software doesn't allow me to do that. So: Like. Like. Like. Like. Like. Like. Like. Like. Like. Like. Like. Like. Like. Like. Like. Like. Honestly: It's comparing apples to oranges. PW is strong. It is the most intuitive, the best designed (in terms of API and UI) CMS out there with the smallest footprint possible. I recently used again the multi language support. I mean, look at the API. Look at the solution for a problem each CMS has. It is just beautiful. You have several ways to solve that problem (as always with PW). But it is there, written in the core, well documented on one(!) API page, because it just works intuitively, it is just simple. Every addition to the core is an addition which solves general problems and the way Ryan solves them is just genius. There is no addition you have to scratch your head when reading the new API. You always think: "wow, clever". And this is the way to go with the core. Make it simple, make it smart, make it beautiful! Regarding themes, profiles and such: It is already possible. It is out there. Provide a custom profile for a real estate agent: Give him a set of modules, fields and templates to handle his offers. This is no problem! This is even easier and more flexible than it ever will be in WordPress, because it goes way beyond a custom theme and can be installed with one click. But: Nobody will care at the moment, because ProcessWire has no own category in theme/template websites, because ProcessWire has not the attention of other plug&play systems. And this is totally okay! Think of TYPO3, a widely spread system, mostly used in enterprise environments and even on small sites (dunno why), but the point is: Everyone (at least in Europe) knows it, it is one of the most used systems in the business sector (not on private children soccer club websites). But: this is the goal! Be the system developers use. Don't be the system every idiot wants to use. Concentrate on performance, flexibility and most of all: beauty of the API! The rest will follow.
    1 point
  43. Really interesting discussion here! Many very important aspects are already mentioned, many good points are made. But: reading the WPTavern / "30 minutes" article, I stumbled over one particular sentence: Wouldn't that be a nice idea? At your first login, right after the installation process (where such a thing would be misplaced). This welcome screen could contain: If you are a designer, then (intro, links, resources). If you are a developer then (intro, links to official tutorials, resources) and look at the beauty and effectiveness of this: $echo $pages->get("/products/2010/")->find("template=faq, body*=Tobiko")->first()->url; Such a screen could at least give a tease to the experienced developer to find out more. Therefore, the choice of links would be crucial. But, fortunately, an official set of tutorials is on the rise. And maybe, with such a screen, PW could increase the possibility to stand the "trial of 30 minutes." And for people like me, who start with a blank profile anyway you could offer an option to disable: $config->showWelcomeScreen = false, or so.
    1 point
  44. Hi Jeff The first thing is about the young bit. Ryan first developed PW as a commercial system quite some years ago (he can give you the history if you are interested). He then made it open source in more recent years. Consequently, the core of ProcessWire (the Wire bit, if you like) is very stable and very developed. However, quite a few of the users on this forum are very experienced developers and coders, and this has helped speed up the development. I should point out, though, that this has not been at a break neck speed; Ryan is very much in control here and development is carefully undertaken. There are many differences between systems like PW and others like WP. The main difference between PW and WP is about the design philosophy. ProcessWire does not have any templating engine or system, it simply has a templates directory where you do most of your playing. The default install does have files in there, but to be honest, you could chuck most of them away (with the exception of admin.php) if you wanted to. Most of us do. So, if I want to design a site using, for instance, the Bootstrap CSS Framework, I simply shove it into the Templates directory as I would if it were going to be a static site. I can now create my file structure as I would normally. Perhaps a header and footer file, for instance. Maybe call these into a main template that I am using for a bunch of pages as I would do any other PHP structured website by using includes. Once I have done that, I just need to add the PW API to retrieve the information. Okay, so there is a little more to it than that, but the point is that anyone who has used Bootstrap would look at the templates and recognise just about everything that is going on there. That is incredibly powerful - it makes it accessible to many different levels of designers and developers very quickly. And that is important too - to a greater extent these are people trying to make a living; they need a system that works for them and does not force them down a particular route. More structured CMSs like WordPress need you to work in their way with their methods. That is great if that is what you want, but if you need to break out of that, you either have to get very imaginative or hope someone has done "a plugin for that." There is no doubt that you can get a fully featured WP site up faster than a PW site - but the PW site will be a lot more specific and tailored to the brief, and for most of us, that is far more important.
    1 point
  45. thanks Teppo, worked great after 1 amendment: on first attempt I got an error: "Error: Exception: Can't save field from page 1028: /blog/posts/test-post/: Call $page->setOutputFormatting(false) before getting/setting values that will be modified and saved." so, I did as the error suggested end ended up with: $comment = new Comment; $comment->text = "my text"; $comment->cite = "my name"; // etc. $p = $pages->get('/about/'); $p->setOutputFormatting(false); // added $p->comments->add($comment); $p->save('comments'); checking the PW cheatsheet for $page->setOutputFormatting() makes it clear why that's needed.
    1 point
  46. @dazzyweb: I'd assume so too.. at least as long as you're willing to swallow their other requirements, such as the "fair use" clause accompanied by statement that they alone decide what this "fair use" consists of. I for one wouldn't, but that's just a my personal opinion. There's a whole world of difference between proprietary and free software and I know which side I prefer
    1 point
  47. @kongondo so explicit in your feedback and i love your approach, am getting to know things better. i am really comfortable with PHP, CSS AND HTML and with what you just explain now i will do the experiment and get back and i know how to work with the developer tools in FIREFOX OR BUG. I am really grateful for your support and all those who contributed. making sense.
    1 point
  48. Thanks Martijn, I went with http://example.yourdomain.com, but you can also run your own ngrok server for that purpose if you want. My dev environment is coming nicely together
    1 point
  49. I have used services like http://www.noip.com/ & http://dyn.com/dns/ long time ago, those were free for several hostnames. ( Had a carracho server in those days )
    1 point
  50. ryan - just a thought, but would it be possible to make it so that fields can be shown depending on whether a user has a certain role, or even ID? Certainly roles would take you one step closer to a system I used to use where there was an editing flow with a website's content - someone would work on content, then their manager would fill out some other fields on the same page, sometimes in another tab in the editor, before finally publishing a page. It's not something that everyone needs, but to my untrained eye it also doesn't look like it would be too difficult to add (*ducks for cover*), would make it even more powerful and could be useful in many different scenarios. I guess the selector for that would be something like user.role=editor|manager as well as user.id=41 maybe for scenarios where the main admin user wants to test some stuff or have hidden fields that other superusers can't see (though that's silly as other superusers could give themselves access anyway - just thinking of odd scenarios!). Can anyone else think of uses for this?
    1 point
×
×
  • Create New...