Jump to content

Macrura

PW-Moderators
  • Posts

    2,765
  • Joined

  • Last visited

  • Days Won

    40

Everything posted by Macrura

  1. @everfree.. it would be good to have a definitive module that combines all of the ideas and features needed to have this working in all possible scenarios, and all different page select (asm, autocomplete, list) types.. Being able to set what fields it applies to is probably a much needed feature.. Originally the module I made was borne out of a need on a a site that i'm finishing now, a record label where the albums need to have artists added as pages... but then once you add or create a new artist you need to go right away and do some settings, like type, instruments, bio, sort name etc. so it would have been difficult to go and search for the artist you just added in order to do those settings... I have now used it on 2 additional new projects and implemented it on 3-4 other sites and i do find it pretty much indispensable.., and it will likely be in every site from now on..
  2. @ajben - very nice - some of my 'older' clients would probably benefit from a simpler admin (even though pw admin with Reno is IMHO state of the art..)! Would be willing to contribute, help in any way to push forward alternative admin themes!
  3. @everfree.. did you see my version of this - might be similar.. (yours looks a lot more definitive..) my version is super simple, just enables a feature that as Soma pointed out is already in the core; and then using some jQuery, enables the editing of pages in other types of page selects like autocomplete, page list select etc.. https://processwire.com/talk/topic/8477-adminpageselecteditlinks-module-for-enabling-edit-links-on-multipage-selects/?p=82020
  4. @adrianmak - it would be a standard page set to hidden, on the settings tab; or it also works to put sharrre.php in the root if you don't want to use pw pages..
  5. i only read the last post.. but if you have repeaters and want to output them as pages... i think you may need to use segments, and then in the repeater have a required field for the page name; then in the parent page check for the URL segment1, and compare it to the available repeaters; if it is a match then output the data from the repeater; if not output a 404. you may want to break out your code into some include files, or use functions if you are getting lost in nested stuff; online_tools sounds like a simple case of using the new api for imploding; https://processwire.com/talk/topic/5098-new-wirearray-api-additions-on-dev/?p=49166
  6. @Roope - thanks - really appreciate the reply! Will take a look at the options and come up with a workaround for this site... thanks again for making this module..
  7. @roope - i downloaded the latest version, and replaced it, but it still picks up the retina images, which are marked up like this: <a href="/" class="retina-logo" data-dark-logo="/site/templates/images/lk-logo-dark@2x.png"> i guess there is no way to prevent this sort of thing, because i see in the code that the module will exclude head, images and forms.., but this is a link with a data attribute... but maybe there could be an option to allow the module to only work on parts of the page in a setting, for example, "container classes to apply the obfuscation to", then it would be possible for designers to limit to only specific places in the page, which would reduce the chance of it picking up images with the @ symbol.. thanks..!
  8. @Roope - ok awesome - many thanks ! I will be back on the project soon and will report back..
  9. @Roope - great module! Used on a recent site; And now trying to use it on a new site, but having 2 issues: 1.) There was a point where there was accidentally an email address in the meta description of the site, and that triggered the emo, which broke the page; any way to disable it in the head section? 2.) the emo is triggering on a retina image (@2x in the image name...) Thanks!
  10. @adrianmak, the widget include file should contain all of the necessary markup to render the widget; for example, here is a simple text widget, that is being used in a bootstrap based site: <div class="col-md-4 bottommargin<?=$wClass?>"> <?php echo $widget->body?> <?php if($widget->page_select) { ?> <a href="<?=$widget->page_select->url?>" class="more-link">Read More</a><? } ?> <div class="clear"></div> </div> here's another widget that is being used in a "call to action" <?php $image = $widget->images->first(); $image = $image->width(720); $description = $image->description; $markdown->format($description); ?> <div class="col-md-4 bottommargin <?php echo $widget->widget_type->name?><?=$wClass?>"> <div class="entry clearfix"> <div class="entry-image"> <?php if($widget->page_select) { ?><a href="<?=$widget->page_select->url?>"><?php } ?> <img src="<?=$image->url?>" class="image_fade" alt="<?=$widget->title?>"> <?php if($widget->page_select) { ?></a><?php } ?> <div class="caption"><?php echo $description?></div> </div> <?php if($widget->page_select) { ?> <a href="<?=$widget->page_select->url?>" class="more-link">Read More</a><? } ?> </div> </div>
  11. @pravin, you would have maybe 3 different options, the 1st 2 being server-side: 1.) Create a page called /tag/ or /category/ and then have it accept URL segments; then you would analyze the url segment and use that in a selector to get the pages to show. /tag/css/ (where css is the segment), and then you would use $input->urlSegment1 to tell which pages to get. 2.) use a URL with a querystring, like this: mysite.com/?category=css then use $input->get to build your selector. 3.) have category page that lists all the projects and have filters for category and tag, using e.g. isotope.
  12. you should maybe reference the name which is already the 3 letter code; the title also can be the same uppercase code; where you are echoing you could use a function to convert to the right entity function get_cur_symbol($price,$cur) { $symbol = ''; switch($cur) { case 'USD': return '$'.$price; break; case 'AUD': return 'AU$'.$price; break; case 'CAD': return 'CA$'.$price; break; case 'GBP': return '£'.$price; break; case 'JPY': return '¥'.$price; break; case 'EUR': return '€'.$price; break; case 'CHF': return 'C'.$price; break; case 'CZK': return 'K'.$price; break; case 'DKK': return 'k'.$price; break; case 'HKD': return '圓'.$price; break; case 'HUF': return 'F'.$price; break; case 'SGD': return 'S$'.$price; break; case 'NOK': return 'k'.$price; break; case 'NZD': return '$'.$price; break; case 'PLN': return 'z'.$price; break; case 'SEK': return 'k'.$price; break; } }
  13. @kongondo - truly awesome work! Can't wait to check this out.. i'm sure this has some wide applications.. will report back!
  14. looks like only the footer is loading, no header or body content
  15. @richard cook - i think what you want to do might be achievable with some jQuery; have you considered using Admin Custom Files, and then using jquery to collapse the repeaters, and also add the required content where needed?
  16. @adrian - i'm doing something similar, but instead of automatically importing, i let the user choose a 'save action' which could be either to create the pages from the media (in my case audio files), or delete the files on save; this of course save so much time because users can batch upload a huge set of media, and then on save they can batch create pages from those files.. the best of both worlds.. I was going to have the action also delete the files, but i was thinking that the user should check to make sure it all worked and they no longer needed the source set of files.. but a lot of times the users are forgetting to delete the audio; i was thinking that it would be cool to have a popup or something that said "import successful, you may remove the source files" as a reminder, but haven't worked out how to get that to display after save yet... maybe load a new js file with that...
  17. could it be a server issue? I had a problem with a server blocking certain combinations of words, it was really strange; turned out to be a mod security issue..
  18. yeah, you would create in your page tree a branch, let's say "settings" (or whatever); you'll end up with tons of stuff under there anyway; So then you'll have another page called 'Selects' and under that all of your selects and their options; average sites i do these days have between 5-20 'selects'; you could create a template called 'option' (for the options) and another template called 'option-index' or 'option-folder' to hold the options. and setup the family rules to keep it clean. the option template could have just a title; but you can later on extend it if you need additional things like data-description attribute, or link, etc..
  19. instead of using repeaters you could use page table, so you would have your classes page table and then it would popup and you would choose the class and the level; and you would see a clean table of those on the edit page. as far as dependencies - it would be a matter of "show this field if..."
  20. with a combination of Lister Pro, admin custom pages, and admin custom files you can really extend the backend.. check out some of those modules and also maybe some of the tutorials. i used dashboard on one project, but then when listerpro came out, it got to be so easy to make custom listings of processwire objects (because you can filter on anything), that the dashboard was no longer necessary, in that case; the only thing i ended up having on my dashboard that i couldn't do with lister was a calendar; but turned out they didn't need it anyway; i would still use dashboard if i wanted to include a page in the admin with charts, calendars, feeds, and other items that couldn't be represented in the lister; however with admin custom pages, you can make any page you want in the backend; the dashboard was helping out with getting it to be the first page loaded when you login;
  21. How about saving the page instead of the field?
  22. yeah, forklift is indispensable for mac.. i almost always have forklift, transmit and coda open at once.
  23. but you can live edit in transmit, just setup your preferred editor in prefs; i've never had an issue, and transmit is a good ftp client
  24. Did you save the field? After adding the items? $pp = $pages->get(1234); // page you're adding the children to the page table foreach($pp->children as $child) { $pp->page_table_field->add($child); } $pp->of(false); $pp->save('page_table_field');
  25. Hi BernhardB - awesome and thanks so much for joining in on this.. i really like your approach to the widgets also; the InputfieldSelector field isn't that new, i can't remember when it was announced - i think this past summer; but in terms of the CMS, it is pretty new and it was conceived by Antti Peisa, coded by Ryan Cramer and sponsored by Avoine; it is in the core, so you just need to install it. The field is used in the listers; as a standalone field i haven't seen many posts about day-to-day use of it and i kept thinking of when and where it might come in handy.. then while i was setting up this one site I came across this situation where i wanted a certain widget only to show up on the child pages of another page; so first i did a plain field and typed in the selector and sort of moved on... but something kept nagging at me and then it suddenly dawned on me that there is already this field that could make setting up the selector more user friendly and reliable, and it works great; It provides feedback to tell you how many pages match your selector; for some clients who have a little technical knowledge and skill, this is a really simple and easy way to specify a selector for pages, and then be able to test against that selector in conditionals.. i think in some instances it is probably too technical to be of use; i wonder if you could use the new selector field in your setup, as you can add additional lines to the selector, which would be like your repeaters... i haven't done extensive testing or experimenting yet with this, but i have 3 more sites to launch and i'm sure this selector field will get more use in situations like this..
×
×
  • Create New...