Jump to content

Peter Knight

Members
  • Posts

    1,377
  • Joined

  • Last visited

  • Days Won

    5

Everything posted by Peter Knight

  1. Is there something wrong with the following redirect syntax ? <?php $session->redirect($page->get(1184)->url); ?> I've used this (below) to successfully redirect to a child URL so thought I was on the right track. <?php $session->redirect($page->child->url); ?>
  2. @Kongondo - thanks for the examples. It does but I have it in a separate PHP call. Not sure if that matters. At the moment it's not working but leave it with me for a few hours. I'd like to fine comb it and try figure it out.
  3. Sorry - that was me typing/thinking out loud. :-/ Thanks for the sample. I'm set up and at the moment the LIs correctly produce <li class="" data-uk-filter="Kitchen"><a href="#">Kitchen</a></li> <li class="" data-uk-filter="Bedroom"><a href="#">Bedroom</a></li> <li class="" data-uk-filter="Bathroom"><a href="#">Bathroom</a></li> <li class="" data-uk-filter="Sitting-Room"><a href="#">Sitting Room</a></li> etc Now I need to apply image tags to a DIV surrounding an image. In UI Kit, each filtered item (my image tag) separated by a comma: <div data-uk-filter="filter-a,filter-b">...</div> or <div data-uk-filter="Bedroom,Gym,Basement" >...</div> I've spent the last few hours goofing around with some code LostKobrakai gave me before which implodes an array but that was based on Page tags <div data-uk-filter='{$tags->implode(", ", "tags")}'</div> and then some code from your own example (which explodes!) $tagsArray = explode(' ', $image->tags); and i'm not getting anywhere. So just to rewind a bit, here's my current base code which works but doesn't separate the image tags with a comma <?php foreach($page->images as $image) { $large = $image->width(800); $thumb = $image->size(380); echo " <div data-uk-filter=\"{$image->tags}\"> <a class='fancybox-portfolio port-item' href='$image->url' rel='gallery1'></a> </div> "; } ?> I know in my mind, what I need to do but cab't translated that to working code when using image tags Vs page tags. Worst case scenario, I can save each image as a page but I've a programming itch now I need to scratch :-/ Any tips after your 3am Media Manager marathon?
  4. Looks amazing. Looking forward to purchasing. Are you looking for any feedback at this stage or would you rather keep developing it? Can we get BETA access?
  5. I've just tried that and it works in terms of outputting a list with no duplicates. You're right though about commas within the LI. <li class="" data-uk-filter="Gym Basement"> <a href="#">Gym Basement</a> </li> Unfortunately, this means the UIKit filtering is broken as "Gym Basement" doesn't match images which are "Gym, Basement".
  6. Thanks K I'll give it a go. Er, no idea. I think it was a code block in a quote
  7. Hi guys Trying to output a series of image tags in surrounded by an <li> a I've been partially successful in that the tags are displaying BUT they're repeating. IE the following code ... will output Sitting-Room Kitchen Kitchen Home-Office Gym Basement Bedroom Gym Basement There's repetition in there. I only need a tag listed once. There's also a case where an image has 3 tags IE Bedroom Gym Basementis actually 3 separate tags. That's the first 2 parts of my problem
  8. Just noticed there's quite a few videos and screenshots in the docs using very old Admin themes. Screenshots should be relatively easy to update once a theme is accepted (default or Reno). Videos are going to be tricker. But as someone who initially looked at PW and then bounced off due to the look of the early admin (bloody designers!) I think these first impressions are vital and should be updated.
  9. Really impressed. For some reason (before you built this) I assumed the Monitor app would be accessed via a private web page. Of course, it would naturally be part of the Admin as you've done. Not sure why I jumped to that conclusion :-/
  10. Yes - good points Martijn. In this case, I am developing for my own skills / curiosity but I'll definitely keep that in mind. I have an earlier post bookmarked too regarding sanitizing entered data etc,
  11. Thanks guys. That gives me a direction at least. Much appreciated.
  12. Hi guys. I want to learn something new but not sure where to get started or what the technique is even called. I have a page inside the PW admin with several fields. I'd like to present this fields (not their values) on the front end of a web page. Populating them (front end) would create a new PW page in the admin with the values etc. I'll start looking at some kind of form hooked up to the PW API but I wondered if fields such as auto complete and page select were possible or would rely on several 3rd party libraries? Just looking for point in right direction as opposed to code etc. thanks.
  13. Ryan - you're the twinkly fairy atop our ProcessWire Christmas tree. But seriously, I wonder if you should include a screen grab from GoogleTrends too? It does a great job of showing the increase in Searches for ProcessWire on Google. BTW, your clarity and openness here just highlights the WTF-fest surrounding another platform I use. Nobody knows the number of the next version, they can't agree on the product name, there's no public (if any) roadmap and it's probably over a year since there was any type of public info. I wish them well but reading great posts like yours on how solid PW is and how bright it's future (and present) is, clarifies for me that banking on PW has been the right decision for my business and clients too. And that's not because the other CMS is headlining at Confusion-Palooza but because PW on its own merits has a bright, long road ahead. You've written too a post which I'll happily send clients to when they ask "well, what is ProcessWire"?
  14. I think a central manager (ProcessWatch ?) is a great idea and something I've needed in the past. My collection of PW sites is growing rapidly and a birds eye view if all of them would be a real bonus as we manage more and more. Are there recent developments with PW3 which allows it to share data with other PW sites? Maybe the time has never been better to have a central PW install with the: 1. Ability to see which version is running and what latest Dev and Stable version is 2. Ability to upgrade , backup database etc 3. See a modules installed and their version. See if a new version is available 4. See the health of a site (some kind of ping or status - live or non responsive) 5. See who is logged in per site 6. See latest changes per site I think all of the above are already available within a PW install via native functions and Module so I wonder how they could be harnessed on a central console.
  15. Hmm, I'm not sure what mean. Possibly I've misunderstood what you're trying to do. Initially I thought you were trying to make a 1-level / linear menu but you may be trying to nest items? Why don't you create a simple mockup of how you want this to look on the front end of your site? I'd have a better idea then. It maybe a case that Somas navigation module might be better if you are building a hierarchy instead of a flat nav menu although I don't think that allows you to cherry pick what items are included.
  16. If it's a page, you can add it regardless of depth.
  17. I'm sure there was a way to manually crop an image within an Images field BEFORE you added it to a page? Am I imagining this? There was a small crop icon on the top right of an image and now it's gone. Possibly it's a result of changing an Images field to CroppableImage but I thought it may have been a bug?
  18. And the most used plugin types are security based. Because you'd need em, right?
  19. Solved with the help of Tom's question in 2012 I adapted it slightly to <?php if ($page->prev->id) { $prevThumb = $page->prev()->Images->first()->getCrop('articlesquare'); echo " <h3>Previous Article</h3> <figure class='uk-overlay'> <img src='{$prevThumb->url}' /> <div class='uk-overlay-panel uk-overlay-chevron-left'></div> </figure> <a href='{$page->prev->url}'>{$page->prev->title}</a> ";} ?>
  20. Hi I have a series of child pages with Next and Back thumbnails under each page. Parent - Child 1 - Child 2 - Child 3 - Child 4 I want Child page 1 to know it's the first page and not try to render a thumbnail. Likewise, I want Child page 4 to know it's the last page etc... My code works when I am not trying to call a thumbnail but as soon as I try to check for the existence of a previous or next page, my check fails. <figure class="uk-overlay"> <?php //get the cropped thumbnail from the previous page $image = $page->prev->Images->first()->getCrop('articlesquare'); // if there is a previous page, show a thumbnail if($page->prev){ echo "<img src='{$image->url}' alt='{$image->description}' class='art-prev' />"; } else { echo "";} ?> <div class="uk-overlay-panel uk-overlay-chevron-left"></div> </figure> <a class="<?=$page->prev->id ? 'previous' : 'no-before'?>" href="<?php echo $page->prev->path; ?>"><?=$page->prev->title?></a> Should I in fact be approaching this differently as the page is first looking for the existence of a cropped thumbnail?
  21. Nice idea. I was looking into something similar today.
  22. Peter Knight

    404 Hits

    isn't the default url domain.com/wp-admin.php In PW I can only setup page urls like this domain.com/wp-admin/
  23. @benbyford I got a little lost in the Docs and found them hard to follow. Eventually I reverted to a Plesk extension which did the hard work for me. Which part are you stuck on? I found that the default PW .htaccess was preventing the installation of the extension and had to temporarily rename it.
  24. I have HootSuite running for social media management. One thing I like to do is have separate streams running for various CMS I have an interest in. This means I can quickly see all posts mentioning CMS A, CMS B, CMS C etc in a dedicated stream. Makes it easy to follow community topics and product developments etc. But it also makes it easy to gauge social media chatter in relation to a CMS. One thing I've always noticed is how few mentions and tweets PW gets compared to other CMS. IMHO we have a very active and enthusiastic community (as evident from the forums) but a relatively quiet community when it comes to Twitter and Facebook. I'm guilty of this myself but the same thing occurs to me every time I see those three social media streams lined up side by side. Why is it that users of CMS B and CMS A are so vocal on twitter, google plus etc and quick to promote their CMS when PW gets a mention or re-tweet only every second of third day? Incidentally, the 2 other CMS I follow are not huge platforms where you'd naturally expect thousands of tweets a day in comparison to ProcessWire. Anyway, the above occurred to me again after reading Ryan's roadmap post where there was specific mention of This was followed by mention of : curiously there was no mention of social media. Is there an unintentional prejudice against Twitter, GooglePlus and Facebook etc that we're not aware of? Ok, it's an odd question but I thought it'd be worth a check. ProcessWire is growing in userbase, the forums are attracting new members weekly, the CMS itself is a work of art, we have wonderful blog updates on a weekly basis and we have Teppo's PW Weekly too. That energy and excitement seems to ripple out so far and then stop when it reaches an invisible social media force field...
×
×
  • Create New...