Jump to content

adrian

PW-Moderators
  • Posts

    10,912
  • Joined

  • Last visited

  • Days Won

    349

Everything posted by adrian

  1. +1 for the RCDefaultApp - I should have mentioned that one in my list. I find that really important too! I was tempted to use the windows maximizer, but decided I would try the Mac way - not really panning out for me There is a great article somewhere about this but I can't find it at the moment. Basically talks about people who like to have typical overlapping windows on a Mac, vs fully maximized windows on Windows and something about being better multi-taskers, or something like that. Sounds like rubbish to me
  2. This forum needs a way to spread the love to the person who really deserves it - in this case, Nico! Maybe this would help a little: https://processwire.com/talk/topic/6373-mention-system-for-the-forums/
  3. Well I don't have the recording mode done yet, but thanks to Nico we now have the ability to migrate content from a Wordpress site into PW. Firstly, this module has been renamed - now it is simply: "Migrator" https://github.com/adrianbj/ProcessMigrator so please uninstall your old one and install this new version. The module now supports 3rd party plugin modules for migrating content from other sources. The first one is: MigratorWordpress: https://github.com/NicoKnoll/MigratorWordpress Here's what it looks like in action. Not much action in that screenshot I know, but you can see how MigratorWordpress adds in a new data source option (a WordPress xml export file). There are instructions on exporting in the MigratorWordpress readme. For those of you who still have access to a WordPress site, simply run WP's built in exporter, then import the resulting xml file into Migrator. At the moment the Wordpress site needs to still be live because any embedded images are installed to PW from their full existing URL. Also if you have ideas for other plugins, please feel free to start coding If there is interest I'll write a guide defining what is required for the module to be recognized by Migrator and also about the JSON schema that is required. So please test out and let us know how things go.
  4. Perhaps this will be more affordable: http://www.adobe.com/products/creativecloud/buying-guide.html Single app - $20 / month Illustrator really is phenomenal, but if you are in need of a vector app for free, Inkscape is functional, and in a pinch try out SVGEdit.
  5. One comment on your function - there is no need to have $selects as an argument in your function. You can leave it blank between the (). You need to: echo selector(); EDIT: You need to do something with the results of selector(). You could put a foreach inside the function if the output will always be formatted the same way, or do as Ozwim suggests below if you want to treat them differently each time.
  6. Depending on just how corrupted things are, this should remove the field from all templates and then delete the field: $field_name = "myfieldname"; foreach($templates as $template){ foreach($template->fieldgroup as $field){ if($field->name == $field_name){ $template->fieldgroup->remove($field); $template->fieldgroup->save(); break 2; } } } $fields->delete($field); The first chunk of code is stolen from Soma. I just added the bit at the end to delete the actual field as well.
  7. Actually I missed the bit about the text and layout being in Illustrator - I assumed Word. I am guessing that is why the bullets and other simple formatting are not importing correctly. You could probably export to svg and if you don't need to support legacy browsers, you could display the svg labels on the site. Apparently Google indexes text in SVGs. I don't honestly think this is a good idea - copying/pasting and reformatting will be better, but just thought I'd thrown it out there
  8. I'd be curious to see some examples of the different label layouts. I would think if I was selling products I would have a standard label layout format for all products. It sounds like it might even be better to have a few different fields for each product, like: Name Ingredients Usage Expiry date Just guessing what might be relevant of course, but the key thing with have the separate fields is that you can ensure a professional looking site by making sure the layout is identical for each product and quickly adjust them all at once through html/css. The way they want things now, it would be a nightmare to make any batch changes to the look of the labels. Of course I might not be fully understanding the requirements, in which case I am sorry - nothing to see here
  9. Things like bullets, bold, italics etc should copy across just fine. A standard paste in TinyMCE preserves these. There is also the Paste from Word option installed by default with CKEditor. In my opinion you don't want line spacing to copy across - you want it to match your sites css line-height. As for columns, that is another case where I don't think it is appropriate to copy across - this should be controlled by your site's markup. I think this is another case where the client needs to be educated that duplicating an exact layout from a Word document is actually not a good thing in most cases - their site would start looking like a jumbled mess and varying layouts very quickly.
  10. I don't actually see how your revised find would work, but this will: $id = $this->pages->get("include=all, sort=-id")->id + 1;
  11. Haven't needed this myself, but from the PHP date page: "To format dates in other languages, you should use the setlocale() and strftime() functions instead of date()." EDIT: Given the way this module uses dateFormat, it might not be possible easily without hacking the core of the module. Perhaps it would be better to implement a new way of defining the date format in the module by using strftime instead of date here: https://github.com/ryancramerdesign/MarkupLoadGCal/blob/master/MarkupLoadGCal.module#L351 If you have the time and skills this should be pretty easy and might be a nice pull request for enhancing the module. Perhaps someone more language savvy will chime in too.
  12. @darrenc The way you submit enhancements/fixes to a project on github is to first fork the project, then make the changes to your forked version, then submit a pull request to the original project. Ryan will receive notification of your PR and he can then review and accept the changes as is, or modify them as needed. Obviously it's hard to know whether your changes will be coded the way Ryan would prefer or not. Depending on the change it might be just as productive to simply submit an issue asking for the enhancement. You could look through some of the previous PR and issues and see if you think your enhancement suggestion and your coding quality would make it better suited to one approach or the other. Sorry, not a definitive answer, but hopefully helpful.
  13. The instructions for this module say to use the path relative to your templates directory, eg: styles/mystyles.css or scripts/myscript.js There is a setting in the module config: "Allow Directory Traversal: Enable the directory traversal option to make it possible to add files from outside of the template folders. (../)" which you can use if you need to access css and js files above the templates directory, but otherwise they should all be in subfolders of "templates" and linked to with a path relative to templates. Make sense? EDIT: not relevant to this module, but path vs url - depends on what is being done with the file being linked to. If it's a css or js file, typically you are going to want the url option. The path option is the full server path to the file which is useful for php operations on files, but no good for front-end display/calling of files.
  14. Wow @cstevensjr - I am feeling the love from you tonight
  15. Nico - this reminds me (not that I had really forgotten, but have been REALLY busy), that I need to do a little work associated with this for you. I really will try to get to it shortly!
  16. Ok, so I have added support for automatic populating the video title into the image description field for both Youtube and Vimeo. Not sure how much longer this method will work with Youtube, but I think it's simpler to keep using v2 of their API for the moment. I implemented both cURL and file_get_contents methods for Youtube and simplexml_load_file for Vimeo. Let me know how it works for everyone and I'll tweak methods if needed.
  17. Yeah, that is still working, but from a quick read I get the feeling it won't be in the future, but not certain. I did read something that suggested that maybe basic info like the title will still be available this way. Maybe I should just go with this for now and adapt later if needed. I might go with curl though to avoid issues with get_file_contents and those on hosts with allow_url_fopen disabled.
  18. So the only catch seems to be that google has deprecated v2 of the youtube data api and v3 requires an API key. I haven't investigated much, but do you have any ideas?
  19. Seems simple enough - would it suit your purposes if I stored the video title in the image description field, or do you have another preference?
  20. I have just updated this module with better support for video links that have a start time and other additional parameters in the url. It also now supports embed links and other variations. Please let me know if you find any issues with this new version.
  21. I had that 404 issue with the last module I submitted. Not sure why the "master" is missing from the filename. Don't know whether github changed something that is messing with Ryan's code for getting the name or what. It's obviously an easy edit, but maybe something we should bring to Ryan's attention.
  22. It's right there in the cheatsheet OK, so your turn to beat me this time!
  23. @pwFoo, Not sure exactly what you need - are you after admin or front-end notifications for users? If the latter, then I described a solution a while back that might take of what you need without a module: https://processwire.com/talk/topic/5534-new-articles-to-users-with-cookie/?p=53935 Obviously not exactly how you want it set up, but might be easily adaptable. Anyway, not sure if it is what you are after, but thought I'd see
  24. all you need is: echo $child->createdUser->name; assuming you have already set $child to the page in question. For the current page: echo $page->createdUser->name;
×
×
  • Create New...