Jump to content

diogo

Moderators
  • Posts

    4,314
  • Joined

  • Last visited

  • Days Won

    80

Everything posted by diogo

  1. Great! I'm participating on discussions without even knowing
  2. diogo

    Koding

    I didn't have any problem with the database, but I find the interface pretty buggy, especially when moving files or folders. I think koding is a very interesting idea, but there's still a long way to go concerning the implementation.
  3. It seems perfectly possible, with the bonus that you get to choose the format If the second is most likely to be the format for all the info, I would go with that one. You should have a look at more news to see if there is a pattern that you can rely on. After that pattern is identified, you can decide how to divide the data on each file in a way that is more useful for you to manipulate it. Then you can start working with regular expressions or even with a DOM or XML parser to actually divide all the data in pieces. Then comes the fun part , structuring PW to receive all the news (pages, fields, categories) and import everything to PW pages.
  4. diogo

    100+ modules reached!

    Two likes for this. Would be three if a "t" wouldn't be missing
  5. Josh's post encouraged me to tell what I have Laptop is a Dell Inspiron with 15'' display, and when at home I dual screen it with a 21'' Samsung monitor. The OS is the very new Fedora 18 Beta (I'm living on the edge ) with Gnome graphical user interface. When people know I'm a designer and I show up with something that is not a Mac, they say "YOU DON'T HAVE A MAC???"
  6. @ryan, coming from mindplay this should be taken as a big compliment
  7. first of all, @soma, when trying this I noticed that you have a problem in your hotmail example, because you are adding the error to the email value and not the object itself. You should change it to this instead: $emailfield = $form->get("email"); $vemail = $email->value; if($vemail && (strpos($vemail,'@hotmail') !== FALSE)){ // attach an error to the field // and it will get displayed along the field $emailfield->error("Sorry we don't accept hotmail addresses for now."); } (new code editing of the forum is great ) --- @david, I wouldn't use a hidden field only for printing an error... If you don't mind having the error outside the form, you can do simply something like this: if(your check) { $out .= "<p>Please fill one of those three</p>"; $out .= $form->render(); } if you really want to put the error inside the form, and between elements (alert: I will be a bit creative here because I don't really know how to change the render() method), I would suggest that you use a php dom parser (yep, creative, i told you). I tried this one http://simplehtmldom.sourceforge.net by putting it on my templates folder and changing it's extension to .inc and including it on my template with include('simple_html_dom.inc');. You would be able to do what you want by writing something like this inside your error check conditional: if(your check) { $out = str_get_html($out); //get the fielset by it's id $fieldset = $out->find('fieldset#id'); // prepend the message to the fieldset $fieldset->innertext = '<p class="error">Please, fill one of these three</p>' . $fieldset->innertext; echo $out; }
  8. Repeaters are always under /processwire/repeaters/for-field-130/for-page-2757/, where "processwire" is your admin name, "130" is the id of the repeater field, and "2757" is the id of the page where the field is.
  9. nooo, i mean one more forum only for snippets
  10. now we can have a snippets forum
  11. diogo

    Before PW & After PW

    Man! Wallace and Gromit!! Must be great to work with the Aardman people
  12. Like any other php script, just access to the php file through the url. Wish in PW world means accessing the page that has this in the template.
  13. A forum is a forum, and undoubtedly this must be one of the friendliest to anyone that wants to participate on discussions. And no matter what people say or how far this discussion is linked to, it can't be seen as more than a bunch of happy PW users agreeing on the benefits that PW brings over another tool and wishing that other people will see things as they do. There's nothing more natural than this, and unlike in many other forums, people that entered the discussion with a different opinion than the majority where warmly welcomed and their opinions where respected. I don't see any sign of alert here... More importantly. If there's a voice that should be taken has the official voice of the ProcessWire project, that's Ryan's voice. And this thread gave him the opportunity of showing once more how he respects other projects and those who are behind them. Also, I wouldn't worry too much about PW "not being there yet", in my opinion it's going in a very fast (and solid) pace. @panictree, maybe this thread went further than you expected, or even wanted, but from my part thanks for having started it edit: Pete sorry for another one... my paragraphs all glued toguether edit2: managed to fix them in firefox. I was on chrome when posted before edit3: chrome is fixed after refreshing some times
  14. I'm not a moderator and had to do the same as Antti. And yeah, it's great!!
  15. It shouldn't be too difficult to come up with a script to import the text in the flat files to pw pages.
  16. In Portugal we have an expression "giving us music" that means "playing with us" or "trying to full us". In this case it applies beautifully
  17. Great website! Love the full size slideshow with the grid filter on the homepage Edit: After going deeper, I have one suggestion. While I like the background pictures changing on the homepage, while looking at the pictures from the portfolio it can be distracting. What if you would have them changing only on the home, and pick a random picture on the subpages?
  18. The reason I like these kind of snippets so much is the freedom they offer. If you want to show the dev page to anyone that is logged in, change the conditional to: if($user->name='guest') If you want to give a special url like domain.com/?version=dev change it to: if($input->get->version!='dev') with the url version you can also make all the links work wth sessions like this: if($input->get->version!='dev' OR $session->version != 'dev') and inside the else: $session->version = 'dev';
  19. Adam, sorry, with the hurry to leave I forgot to answer to your question about the typeface. It's not my work unfortunately The font is called "LiebeErika" and was designed by the German designer Ulrike Wilhelm. Her fonts are here http://liebefonts.com/. They are really cute and well designed, and not expensive at all. Matthew, thanks for your nice answer! I also think that the idea has potential to be used in a different way, but that way we did it was conscious attending to the very specific objectives of this site. The site will be shown to a very limited, hand picked, number of people (besides the forum, of course). And the idea is to state that Erika has some experience in designing books to take these contacts a step further, not showing a lot of the books themselves. So, it's not really meant to be a gallery.
  20. Not really... this is a usability problem, so it's my bad. I will be away from the computer, but as soon as I come back I will think of a solution. Meanwhile, and as a temporary solution, I changed the cursor to the dragging hands hoping that they give a clue already. This is also why I like to post my sites here in the forum
  21. Thanks Adam. Tiny? Hm, what's the size of your screen?
  22. Erika needed a simple website to showcase the books that she designed. I think this is as simple as a book showcase can get http://diplom.erikagrafika.com/ There are lots of transparent PNGs to be shown at the same time (transparency because of the shadows and cut corners), to make them smaller I found an amazing tool http://pngquant.org/. No kidding, this tools can cut the size of a "saved for web" transparent PNG to half. I love how you can use it in a bunch of directories at the same time from the terminal, but if you only need it for a few pictures and don't want to mess around with the terminal, this online tool uses exactly the same process http://tinypng.org/. edit: I must have messed up the title, can someone entitled change it to "diplom.erikagrafika.com"?
  23. @Nik, you are right of course. Already changed it. @Matthew, seems interesting but I really like to keep it simple and adapted to each situations need. What you are asking can be closely achieved by creating a "dev" folder inside the templates folder and copying there your styles and scripts folders. Then, put this line on the top your header.php: if ($user->name == 'me') $config->urls->templates .= "dev/";
  24. A very simple tip, but that might be useful for someone that didn't think of it... This is what I usually do if I want to change something on a live site. if($user->name!='diogo'){ // live code }else{ // my new code } Like this I'm the only one that sees the changes. More examples: // test new javascript. do the same for styles <?php if ($user->name!='diogo'){?> <script src="<?php echo $config->urls->templates?>scripts/main.js"></script> <?php }else{?> <script src="<?php echo $config->urls->templates?>scripts/main-dev.js"></script> <?php }?> // test new head file if($user->name!='diogo'){ include(head.inc); }else{ include(head-dev.inc): } and so on... edit: corrected the first block by Nik's suggestion
  25. I understand perfectly but I think it's nice to present both
×
×
  • Create New...