Jump to content

Soma

Moderators
  • Posts

    6,798
  • Joined

  • Last visited

  • Days Won

    158

Everything posted by Soma

  1. Thanks, yes I know that already. But not quite what I was looking for. Problem is, modules that have a .js with the same name, as the module, will get added automaticly. So no need for -$config->scripts->add() and the like; .How I solve the problem (as I get to this point every time), is to add it manually using in the init or execute function, or using str_replace in hooks to get the desired location. I just thought it's strange it gets added before jquery core. I'm doing it now with renaming the .js file and using $this->config->scripts->add() in the execute function, which does add it after jquery core.
  2. How? I'm facing the same problem everytime I want to create a process module with a js. It will automaticly get added which is great, but unfortunately before jquery core. Is there a way say where it should get added? How is the order of them defined anyway?
  3. Great I'm sure I will have a run soon. Thanks Ryan for the great work. Now we have two "Languages" setup ... Olivers multilanguage module. Now, you'll have a look at the cheatsheet?
  4. I can't speak for Ryan, and I'm not sure. I guess it's to simplify things on not have endless dimensional for sake of the change tracking? Anyhow, can't you just use $_POST $_GET? Or are you really needing processInput? On a side note: Why doing quadruple posts? Please use the edit button to add things. Thanks
  5. Are you looking for this? $config->paths->root . $page->image->url;
  6. Good idea, thanks for sharing Nico. Not sure what the nofollow would do to your sites rank... I would also consider doing this as a simple hook on all/notall pages render. Have just looked a moment into code. Not sure, but wouldn't it remove existing classe ar attributes?
  7. Just will comment on this. I don't get what you mean. It actually IS in a folder. THe download is like "ryancramerdesign-FieldtypeMapMarker-09847d5" just rename it to "FieldtypeMapMarker", drop it in modules folder and your set.
  8. Thanks Ryan for including them, glad I could help and fix them finally. Whohooo my code is in the core! Feels a little proud.
  9. Thanks Ryan for adding it! Great, now after working on it the last couple days, I haven't really come to see how useful and great this is already... Good idea having a "simple/advanced" option would be great. Just not sure what would go where. I think I would need some help here deciding. As for undocumented functions and such. I didn't even started to look at what else there is to be found in the codebase, I just added all from the API pages. But there's already a couple things added that are not in the docs yet. Now looking at the code and seeing more and more that I discover I'm a little confused to what's intended to be used and what not, which are left out on purpose or by accident... or not have made it in yet. Also since I'm not very experienced in OO PHP and still not have the complete understanding how everything works together in PW core yet, I would be very happy to have you Ryan help me out there as much as you can. Though the nice thing is I experienced a boost in my understanding while doing this cheatsheet, as I'm now trying stuff out and looking at core more and again. BTW I discovered a method in Template: hasField(name|id|Field) . Which I didn't know but found could be useful to know. Just as an example. I added it to the cheatsheet in the next update.
  10. I'm a little confused. Further down you have the root tree "Home" and it has a "view" button which does the same. Though I see there could be a more prominent button somewhere visible, but this comes down to personal preference. Creating you own custom theme is so easy anyway in PW. There's a lot of thing that can be helpful. Anyway I yet have to find a CMS that makes it so easy and straight forward changing the whole admin theme and even layout and add widgets. This also is enabled only by the way it's build. Simple straight HTML/PHP CSS. Gotta love it everytime I think about it! This is something PW shines over all CMS' I know of.
  11. I couldn't have said it better Ryan. I was thinking the very same. It just makes me wonder, and wish to know to what reason is they're doing it. Is it may personal or just scared off of a newcomer sensing that many switch from Textpattern, Typo3, Wordpress, Joomla, MODX ... ;D
  12. I just checked on opensourcecms.com and PW is now on first place of worst-to-best list! With 1442 votings.... Bastards. :-\ --- Every few minutes a couple ratings more... Well how comes this doesn't surprise me much.
  13. Can you explain a little more about this and Wire/PageArrays in general? What exactly is the difference between PageArray and WireArray? I learned to use new PageArray(), to fill it with pages using import or add and do further manipulation.
  14. Thanks Ryan! Glad you like it. What do you mean put on API page? A link? No problem go for it. I rather see this as a official reference page wen the team will manage. I'm looking through your comments and implements those as soon as possible. As you can guess all what's there (except a only a few) are copied from the API pages. So if somethings not there it's most likely not on the API pages. If you don't mind adding them and note them to a text file, so I could easily look through them and add them. My plans: Make this as useful as it can get; complete, comprehensive list of all most basic and useful API stuff. So my idea is, this is a working prototype. I see this pretty soon to be a PW app! ( Fun! ;D) So from there PW team could add and manage themself. Make color codes for example to distinct get/set methods/properties is something I was thinking about and would like to do it but I'm not very save in that area when it comes to descide what is what. I would love if you could lend some time and may at some point implement it. If this would be a PW app, it would be easy. Change layout to floated cols and may have media queries to adapt layout to screensize (nice to have) My questions/comments: WireArray Here I wasn't sure, it looks like PageArray is the same? So I thought I'll just put WireArray for now. Selectors Here I'm really happy if you can help out getting them right. I wasn't sure how and what to put there. I'll have a go with you input. $templates $template Those are very confusing to me and may others too. While there is now: $page $pages $fields $field $templates $template ... You mean to separate them? Confusing may be that there's no "$field" variable, and also not a "$template" variable... those are meant to be in real like $page->template and $page->field_name. Or when one uses: $field = $fields->get(name); echo $field->name; I would like to have this more clear to new users, as this was what also confused me a little. General API It's great to see an overview of the "whole" API and I'm also surprized that there are still some I didn't know or know well, and some are still not there it seems. Also one may start to question why isn't there an $users $roles $permissons var? Thanks
  15. Thanks diogo I've just commited major update. Cleaned up some and added new features. - Added index collumn on left side - You can now toggle sections using the index - Also toggle show/hide all description of a category when clicking on blue titles. - It resets if you click on the table somehwere (white space) Hope you guys like the changes. -- I noticed that in mozilla, the live search filtering wasn't working after the changes i've done to it. I figured mozilla has no innerText, which is very practical to get content of a node but not subnodes. I had to use textContent, which returns all text including subnodes, so the search filter doesn't work as good as in other Browsers. May I find a way to work around it.
  16. Cool, glad it works better now! Thanks. I just changed the toggle behaviour... and it's inline now. Also changed descr font to monospace default.
  17. Yeah your right, but I'm working hard on it ... Can you try again , just updated improved live search version. -- Thanks for your feedback and ideas. I will certainly consider some of those.
  18. This is correct, but not using the page->render module method I mentioned. Assuming you have a template setup for the side panel with a php file like this: <div class="side_panel"> <h4><?php echo $page->title; ?></h4> <?php echo $page->body; ?> </div> Assuming the page field is allowed multiple, then your code could be: <?php if($page->side_panel) { foreach($page->side_panel as $p) { echo $p->render(); } } $page->render(); just renders your side panel page using the template file with the variables filled in. Then you can have multiple different side panel types with own templates and fields for own purposes. Hope that makes sense.
  19. Yes, it has a search heuristic which find also wrong spelled word similarities. I can't really agree that it's not desirable, I like how it works to filter and also find similar matches, which can even be helpful if you consider it. Like config->modules find more than just the exact match. It's just that I can't figure the best setting and think it's stumbling over the -> chars, and because of the description texts adding to the results.
  20. Thanks for asking. I use some code from JResig from a while ago, he showed an improved example for someone elses live search. It's using quicksilver js for scoring. So it checks for if score > 0.1 , which is pretty lazy and finds many things. I tried to find a setting which is a good balance, but it's two sided sword. BTW, the hidden description texts also count. Also if you enter -> or $ it works better. If I set it to > 0.5 or 0.8 it seems to not find stuff that should... I don't know if it has to do with the $-> chars. I'm still trying to see if I can improve it, I'll try to do some investigations. But also would like to hear what you think - try again using the -> in search..
  21. Ah haven't done that yet. Thanks for the tip. I've tried and created a branch and now I'm a little confused with those two separate branches "master" and "gh-pages". Is there a way to have the master always getting pushed to the gh-pages? The github project page is now available here: http://somatonic.github.com/ProcessWireCheatsheet/
  22. Then you have Courier set in Chrome as default monospace font (it's the default). It works all well for me in Chrome and all others. Don't know if I'll change it back, now that it's configurable I don't see any big level of complexity here. --- May be best to just specify monospace as font, so whatever you define in your browser is chosen. Since courier is default in all browser I would be fine with it. I quickly changed it, can you have a look diogo if that works for you, I guess you'll still see courier... Anyway, for the font sizes, not each font will render same size consistent, that's why you seen the font size change because I defined "Courier New" and your default monospace is "Courier" and set different size or may render differently for you.
  23. Thanks, can you try again with chrome? It works for me the browser default monospace is shown for me...
  24. ahh Thanks apeisa for the head's up that makes sense now... You mean if you select monospace? What browser? For me it also shows courier, dunno what my default monospace font is
  25. I used to do it like this: Add page reference field, that configured to allow to select pages with template "sidebar" for example. This sidebar template has just title and body and may other fields. Now add a page tree section ie "Sidebar Elements" in the tree, where you create the sidebar pages. Now on your normal content pages you can select 1 or more of them through the page reference field and even sort them. You can then render them using foreach over fields or using ->render method (need to install the module I think) for pages to render them using their own template file, which would only contain the markup for the sidebar element of course. There's a few more options and ways to archive this, but this turnes out to be very flexible and easy. You could also inherit those to while sub page branches aswell, like the mood image on basic site.
×
×
  • Create New...