-
Posts
11,182 -
Joined
-
Last visited
-
Days Won
372
Everything posted by adrian
-
Thanks for that info. I have a late 2011 model so hopefully ok, but I did see some people in that thread with 2012 models also reporting issues. Not exactly encouraging. Anyone else have any Mavericks experience to share?
-
Interesting to hear given that I am probably just about to upgrade from Lion to Mavericks. I avoided Mountain Lion, but now there is starting to be too many things that won't work on Lion that I am being forced into it. I can't say I am thrilled about the dumbing down on my desktop that seems imminent, but maybe I am making too much out of what I have read on the subject. Do you know if this was a common error for these machines when upgrading to Mavericks, or just an unlucky situation?
-
selector questions about pages with datetime field
adrian replied to PeterDK's topic in Getting Started
This is one of those cases where an SQL query would be easier. WHERE DAYOFWEEK(date) = '6' But it probably isn't worth it to do an SQL query for such a simple situation, so you might be best just removing the non-Saturday dates from the results. $results = $pages->find("date>=2014-01-01, date<=2014-12-31"); foreach ($results as $result) { if (date('l', $result->date) != 'Saturday'){ $results->remove($result); } } -
Repeaters within repeaters, and the pageFields inside them.
adrian replied to darrenc's topic in General Support
Why not just have them enter the period and the rate type and the rate in the repeater. If you used page fields to store the period and rate types, they could add new ones as needed using the "Allow new pages to be created from field?" so they wouldn't have to retype them each time. Do you think that would work at all? -
Ryan, If Peter went with that approach, what would you recommend he implement in his search.php script to make it possible to find those fictional rider pages? Maybe something like this: $matches = $pages->find("title|body|sidebar~=$q, limit=50"); $rider_matches = $users->find("name~=$q, limit=50"); $matches->append($rider_matches); foreach($matches as $m) { if($m->template == 'riders'){ $out .= "<li><p><a href='/riders/$m->name/'>{$m->name}</a></p></li>"; } else{ $out .= "<li><p><a href='{$m->url}'>{$m->title}</a><br />{$m->summary}</p></li>"; } }
-
Please let me know how you go with that module. There are some very recent changes in there that added support for API uploading on the front-end. Prior to that, it was only for admin uploads, so I'd like to hear about your experience with it and any changes you would like to see.
-
Hey Pete, the problem happens sometimes and not others. I'll reload the page and it works ok, and then reload again and it won't work at all, no matter what speed nor how fast I drag. Not sure if it is related to image not loading in time or what, but definitely not functional when it's mis-behaving. I am sure Joshua will get it sorted out though
-
From what I understand, you want to be able to rename an image during the upload process. A couple of options: Install Custom Upload Names and define rules for what files should be named what Hook into Pagefile::install and work with this code from Ryan Let us know if you need any specific help.
-
Hey joshua - it is very stylish indeed. One issue I am having is dragging the sliders sideways is temperamental for me. Most of the time they just bounce back to the start. I am on Chrome / OSX. Anyone else having this issue?
-
Just wanted to share a little story of my old Dell laptop. It was 9 years old and still running quite adequately, with only one RAM upgrade in its lifetime. I was spending a working holiday in Mexico for a month when the graphics card decided to pack it in one week into the trip. All I got on the screen was some random fuzzy lines. Not looking very promising A quick google, a screwdriver, some aluminum foil, a kitchen oven, and 15 minutes later she was good as new and is still working 2 years later! No chance of fixing something like that on a Macbook these days. FYI, I am on a Mac now and I have finally wrangled it into submission and am generally happy. Two things I shelled out for were an SSD and a matte screen - I know glossy are all the rage, but the reflection off the glass drives me nuts! Am I the only one?
-
Select setup taking too long: http://mods.pw/5R | Rename ugly uploaded filenames: http://mods.pw/5m | On demand SVG rasterizing: http://mods.pw/62
-
Configurable Process Module (Need walk through)
adrian replied to renobird's topic in Modules/Plugins
Hey reno, You can set your defaults like this. Just put it before your init(): protected static $configDefaults = array( "defaultSelector" => "default value here" ); /** * Data as used by the get/set functions * */ protected $data = array(); Add this line to your inputfield: $field->attr('value', $data["defaultSelector"]); And add the following at the top of your static public function getModuleConfigInputfields(array $data) {: foreach(self::$configDefaults as $key => $value) { if(!isset($data[$key]) || $data[$key]=='') $data[$key] = $value; } You can then access this throughout your module using: $this->defaultSelector; At least that is how I have been doing it - maybe someone else has something cleaner Does that make sense? PS, Sorry for all the consecutive edits. I really shouldn't try to offer device when I am busy with other things and rushing EDIT Again - I just read that tutorial you pointed to and I see if uses: public function __construct() to set the default values. I haven't used that before. I guess I started by copying from other modules and never came across that approach. I guess there are a few different options, but construct does seem cleaner.- 9 replies
-
- 11
-
-
Firstly wanted to say amazing job Ryan - PW just keeps getting more capable and powerful and it's a real pleasure being part of this community. I have never experienced anything else like it - so incredibly friendly and supportive. A far cry from so many others. Obviously a result of the tone and standards you set here. Just a quick request - I am sure it is on your list, but it would be helpful to have 2.4 checkbox option in the modules directory sooner than later. Thanks again for everything!
-
It really depends on the owner of those files and also the user that PHP is running as. Chances are you don't need to set them to 777. You should be able to set them to the same setting as the site/assets/ and site/config.php when you installed PW and also the modules directory, if you installed ModulesManager. Basically you need to set it to the lowest level that allows it to work, which would be write access for the owner (assuming the owner matches the php user. Does that make sense? If you are worried about security, you could ask your host about running PHP under SuExec and CGI.
-
I just tested this module again myself. The issue is most likely with file permissions. Not that you should necessarily leave it this way permanently, but try chmod'ing everything in your templates folder to 0777. If they are still blank, then you might have fopen disabled somewhere in your php config. Let us know how you go with these two options.
-
Are there any PHP errors being logged?
-
Some major additions today! Added the ability to specify the dimensions of the rasterized version that is added to the admin images field. See the tiger screenshot in the first post in this thread to see how the SVG which was scaled to 25 x 25px before uploading, resizes up to a 500 x 500px fully transparent PNG. You can go as large as you want with no loss in quality. More importantly, I added a new method: rasterize() for the front-end which can be called from your templates with or without dimensions for resizing. $image->rasterize(200,0)->url This method optionally resizes the vector version of the image before it rasterizes it, so you can scale it infinitely and there will be no loss of quality. Make sure you point it to the svg version in your images field. These versions are stored using the filename.200x0.png format, so they will be automatically removed by PW if you delete the original image from the admin. I think this will be really useful - you can now upload one SVG and use the rasterize method to generate whatever sizes you need throughout your site - I can see this being especially useful for icons/logos. Also for scaling drawings/illustrations/charts/maps for different screen dimensions (RWD techniques) without the usual artifacts that result from scaling these style of images. New version available from the modules directory. Please let me know how it works out for you!
-
Ok, I have added support for rendering the video in a Sublime Video player with: echo $page->video_field->eq(0)->play; Just register at sublime and enter your token on the config settings page of this module and that's it. I am not sure I am convinced about Sublime at the moment. I like the idea of a CDN approach to including the required file, but you can get mediaelementjs and other libraries through services like: http://www.jsdelivr.com/#!mediaelement Admittedly there is a lot more to include this way though. I think the main thing that puts me off about Sublime is how the process they take you through is designed to set up each video separately. Certainly you can just get the token for your domain and forget about the rest, but I would like it to be simpler. I have pushed this version to github, although I think maybe I should have made a separate branch - oh well. I am contemplating the idea of supporting several different players. Any thoughts on this, or how this new version of the module works?
-
From someone who hasn't really used either yet but is contemplating it (need to see what all the fuss is about), this is a decent article: https://medium.com/frontend-and-beyond/8b3812c7007c
-
From what Ryan posted here: http://processwire.com/talk/topic/5335-another-villas-site/?p=51628 it sounds like he went down that track a little with his latest villas site.
- 4 replies
-
- scalability
- load balancing
-
(and 1 more)
Tagged with:
-
Yep, I just ran that command on my server without rsvg compiled in and that's exactly the same output I get. Hopefully they are willing to fix it for you. Let us know how you go.
-
Thanks Manfred - this observation was actually with an upgrade - my bad!
-
Not exactly sure as I am not sure how it is installed and whether imagemagick was compiled to use it. Also, I would question the version of librsvg. I am using 2.32.1 and it is currently up to 2.40.1 (https://download.gnome.org/sources/librsvg/). That version you have is almost 4 years old, so that might be the problem, but given that your output exactly matches my test on a server without rsvg at all, I would ask them to check imagemagick using this command: convert -list format | grep SVG That should return something like this: MSVG SVG rw+ ImageMagick's own SVG internal renderer SVG SVG rw+ Scalable Vector Graphics (RSVG 2.32.1) SVGZ SVG rw+ Compressed Scalable Vector Graphics (RSVG 2.32.1) If not, then it's not set up correctly. Hope you can get them to help you out on this. Might also be worth asking what version of imagemagick and imagick they are running while you're at it.
-
Just a minor detail. When installing with the new admin theme as a module, there is no color set checked by default. Warm is what is being displayed by default, so I think that radio button should be checked, or whatever color you decide to go with as the new default
-
Hi Felix - nice looking site. Just a quick comment though - those images are nearly 500KB, so when I first started scrolling down, the images weren't showing. A quick look in Photoshop suggests that they could easily be half the size without any loss of quality.