Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 01/22/2013 in all areas

  1. As briefly discussed earlier with Ryan (http://processwire.com/talk/topic/1560-searching-multiple-fieldtypes/page-2#entry23307), I tried to build some sort of test suite for ProcessWire. The tests aim for selector consistency (in-memory and db) and of course making them free of bugs - once and for all. The beginning of the test suite with instructions can be found from https://github.com/niklaka/ProcessWireTests . I wouldn't be surprised if I had to go and restructure the whole thing sooner than later (more than once even), but that'll do for now. Next I'll focus on writing a basic set of tests to cover at least the most common selectors (as there's currently only a few of the most simple ones there). This testing stuff if somewhat new to me and I've been reading lately a little something on the subject. Hope I got at least something right . Having said that, any help (or constructive criticism) from you my dear friends is highly appreciated. Especially if you'd happen to have any/some experience on testing - but I'll take kind words from anyone . I decided to try where I'm able to get with PHPUnit and so far it looks like it would be very much possible to build something useful with it (no, I'm not exactly surprised as it sure is a proven tool for such a thing). I did take Ryan's idea of using Skyscrapers profile as a base for testing (you're not making changes to it are you Ryan ), but there may be need for some other approach as well, even another Skyscrapers based one. Well, I'll go and write a a couple of more tests now. (PS: If some admin feels this post fits some other area better, please do move it - I wasn't sure where to put it myself.)
    9 points
  2. Custom Page List lets you easily customize the page list (tree) in the admin section. I wanted something more (easily) configurable than the existing solutions, so I tried to add some new functionality with an easy to use interface. This is my first module for ProcessWire, so don't hesitate to let me know how to make it better Based on the work of Philipp Urlich (somatonic): PageListImageLabel https://github.com/somatonic/PageListImageLabel Adam Spruijt (adamspruijt): PageListBetterLabels https://github.com/adamspruijt/PageListBetterLabels Features Customize styles and separators used in the page list Display custom labels for each field Display image thumbnails Display formatted dates Display info from related models (e.g. title field of related pages) Display on/off checkbox as "Yes/No" (ready for translation) Define output filter(s) for each field Configuration See the README that comes with the download. Download Source code is available at https://github.com/hgassen/custom-page-list.
    7 points
  3. Hi Ryan, just saw this now. We're working with someone now who found out about the job from this post. We're excited to be working with someone who's got solid PW skills. Thanks for the offer anyway. Should we ever come across any PW work that mere mortals can't solve, we'll be sure to reach out
    2 points
  4. Oh you guys! In case you didn't know Thomas, ProcessWire has this repeater field… oh, well Good work, good selection for first site, and until you are all like 'pretty straightforward', it's going good.
    1 point
  5. OT: I re-programmed the forum software so you can't post as fast diogo - randomly deleting some content should slow you down Actually, I don't know, but I have had an unrelated weird issue today that I'm hoping was just badly cached javascript.
    1 point
  6. http://listjs.com/ Could maybe help you.
    1 point
  7. The ProcessWire equivalent would be repeater fields: http://processwire.com/videos/repeater-field-type/ And you could easily set field widths to have a layout similar or indeed slightly better than that interface But yes, what diogo said about coding it without storing settings in the database is also very relevant. EDIT: Stop replying so fast you guys, I'm having a slow day
    1 point
  8. Hi Thomassausen That is a great way to start - and a nice clean site, by the way. I am just doing a similar exercise on my own portfolio site .... though I keep getting distracted playing with functionality that the site will never use! Joss
    1 point
  9. Just watched this, thanks Dave. It's a very interesting talk, and I would say PW fits on her idea of a good CMS (besides, maybe that the content is associated to URLs), but the fact that our content chunks are grouped in something called "pages" would definitely put her away in a first impression...
    1 point
  10. Hi Ryan, is it possible to hack something in PW, so it will work on two different servers? (staging AND live server) something like (pseudocode): $LIVE = (set_by_url) ? true : false; if($LIVE){ $db = 'hujul'; $db_user = 'user'; $db_pw = 'pw'; $db_server = 'this-one.com'; }else{ $db = 'staging-db'; $db_user = 'root'; $db_pw = 'root'; $db_server = 'staging.that-one.com'; }
    1 point
  11. We do need to setup something like this, and hopefully will soon.
    1 point
  12. Nico, can you provide any examples of what kind of permission/roles would be beneficial in your use cases? I am not keen on complicating permission stuff just because there is only 9 default permissions (I think it is great to have just few).
    1 point
  13. Have you seen this? http://processwire.com/about/sites/ And this? http://processwire.com/talk/forum/9-showcase/
    1 point
  14. What you suggest should work just fine. Using your example, here's how I'd code it in your /site/config.php: Solution 1: <?php // If your dev/staging isn't 'localhost' then replace it with // whatever $_SERVER['HTTP_HOST'] is on your dev server: if($_SERVER['HTTP_HOST'] == 'localhost') { // staging or dev server $config->dbHost = 'localhost'; $config->dbName = 'pw2_blank'; $config->dbUser = 'root'; $config->dbPass = 'root'; $config->dbPort = '3306'; } else { // live server $config->dbHost = 'something'; $config->dbName = 'db_name'; $config->dbUser = 'db_user'; $config->dbPass = 'db_pass'; $config->dbPort = '3306'; } Solution 2: Another solution, and the one I use is to maintain a separate config file called /site/config-dev.php. ProcessWire looks for this file, and if it sees it, it'll use that rather than /site/config.php. If you just keep this file on your staging/dev server, and not on your live server, then that solves it for you. I also added that file to my .gitignore file so that it doesn't ever get deployed, while /site/config.php does. To get started with this method, just copy your /site/config.php to /site/config-dev.php (on your staging/dev server) and change the database settings in the config-dev.php version.
    1 point
×
×
  • Create New...