Jump to content

Macrura

PW-Moderators
  • Posts

    2,766
  • Joined

  • Last visited

  • Days Won

    40

Everything posted by Macrura

  1. I'm using pagination on a site where it is outputting articles, and i'm also setting up a "Printer Friendly" view for the page, which would output the whole page body, but i'm having trouble 'unsetting' the pagination textformatter. Any tips on how to do that (i've tried a bunch of things, like $page->getUnformatted('body'), and $page->of(false)... but nothing seems to work - i always get the paginated version; i don't think it could be cached because the print view is generated off a url param (?printerFriendly=true) i guess i could apply the textformatter at runtime to the field where pagination is required - is that the best way to approach this?
  2. it should just need the path to the file . $ff should be the server path // Upload picture $picture->images->add($ff); $picture->save('images');
  3. I've had a good experience with FoxyCart+Processwire I'm hoping to try Padloper soon.
  4. site5 backstage allows clients to assign you to their account, so that you can 'switch' accounts to the client account when you are logged in and post support tickets, and depending on what type of account they have you can access the whm or cpanel, and setup ftp user etc..
  5. @wasta007 - you should post this in the formbuilder forum in the future. In the meantime you can download the latest formbuilder from the VIP area. as cstevensjr stated you will need the latest version.
  6. there is no $page context in lister, so you are trying to do a dependent select (e.g. one select list is populated based on the setting of a separate select). I'm not sure if lister can do dependent selects, but it would be no problem to do with a custom page list and some javascript. you would output your own filters and filter the dataTable with those custom filters; the dependent filter would populate with some ajax appending the results of the lookup after the first select is changed.
  7. Can you post your Formbuilder settings? Also.. In order to provide the best chance of help, could you provide the following info: Processwire Version Apache, MySQL & PHP Versions List of installed modules details of any applicable/related errors in your error log (assets/logs/errors.txt) Browser you are using In addition make sure to take the following steps before reporting errors: Upgrade to the latest stable version of PW Upgrade all modules to the current version Install the diagnostics module check that your server environment meets the minimum server requirements Repair database tables address any existing warnings or failures Try increasing your .ini variables like memory, and execution time *Note, if you cannot even run processwire due to WSOD or other fatal error, please try a clean install, and then import the site folder and database, prior to posting issue reports. When reporting errors that happen on a form such as the editor, please open the chrome console, or FF/firebug, and see if there are any network or JavaScript errors. Please report those errors along with your issue. Lastly Don't Panic
  8. sounds like you are specifically referencing the inline editing feature of LP? can you explain more about what LP is not showing?
  9. @joebaich - i've been (slightly) stung by this also at some point; your fix is appreciated - i often need to redirect the main site to www, but at the same time have a subdomain like dev but don't want that www prepended..
  10. you should probably post this on the module topic itself (in the future, e.g. don't double post this). https://processwire.com/talk/topic/6540-markup-rss-enhanced/ you can either roll your own custom RSS feed, or you'll need to append an image tag to the description so that it is within the [[CDATA]] you'd need to add this around line 149 $description .= $this->renderImage($page); you'd need to add something like this to the module (untested) /** * add an image to the description * * */ protected function renderImage(Page $page) { $name = $this->itemEnclosureField; if(!$page->template->hasField($name)) return ''; $fieldObject = $this->fields->get($name); // field object $field = $page->$name; $fieldType = $fieldObject->type; $maxFiles = $fieldObject->maxFiles; if(count($field) === 0) { return ''; } else if ($maxFiles != 1) { $field = $field->first(); } if($field instanceof Pageimage) { $width = (int) $this->width; $height = (int) $this->height; if ($width && $height && $this->boundingbox) { $ratiox = $width / $field->width; $ratioy = $height / $field->height; $width = min($ratiox, $ratioy) * $field->width; $height = min($ratiox, $ratioy) * $field->height; $field = $field->size($width, $height); } else if($width || $height) { $field = $field->size($width, $height); } return "<img src='{$field->httpUrl}' />"; } else { return ''; } }
  11. @justb3a's fix worked for me
  12. where are you adding it in the htaccess file? are you sure it is after the <IfModule mod_rewrite.c> also, i can't see how PW would throw an error on a page just because it has a url parameter; i've done tons of htaccess 301 redirects both with Redirect and RedirectMatch and it always works, i always put them after the www rule
  13. $relatedProjects = $page->related_projects->find("limit=2");
  14. you mean like this? <?php $relatedProjects = $pages->find("template=project,limit=2"); foreach($relatedProjects as $rp) { echo "<h2>{$rp->title}</h2>"; echo '<img src="' . $rp->images->first()->url . '" alt='' />'; }
  15. Each type of template you allow for the page table will have it's own button with the label of that template. on the details tab of your page table field, add some more templates and it should all work how you want.
  16. i ran into something like this, maybe it's the html purifier? (can't test right now); after you close the dialog, if you view source, is the rel attribute still there?
  17. @ukyo, thanks for this! Looks very cool, and I'll be psyched to test this at some point soon...
  18. right... good solution, and good to know about the 1 skin per page...
  19. I tried checking on some things, but as far as i can tell, the "skin" setting for each editor instance does need to be set in order to override the global skin setting. I think in the future there may need to be some additional setting for global ckeditor style to prevent the current behavior which is loading the default editor stylesheet, but then overriding the editor style with the skin parameter set in the json... So my suggestion would be to see if the module can hook into the ckeditor module with a setting for the option of global skin setting to lightwire. maybe another setting which "allow field-specific skins", and then if this is the case, then the fields that don't have a skin specifically set need to inherit the global setting, and specify that in the json (since right now there is no skin setting in the json for fields where it is not specifically set).. or maybe just modify the current system to where the skin is set in the json and no global style is loaded? but then there needs to be a way to override that.
  20. there is a module that allows you to add reverse (new child at top). you can also specify sort setting for children in parent template. on the frontend you can sort by any property.
  21. yes, you have to craft your template files and you do need access to the FTP. You can use exisiting HTML/CSS templates and then integrate the calls to the Processwire API within those.
  22. @LostKobrakai - thanks for the clarification and correction... interesting indeed.
  23. the templates-admin is a vestigal folder from the earlier versions, but it is there in the event that the module fails, it is basically a failsafe at this point, as far as i can tell. If you are developing a new admin theme, then you would do it all self-contained in your module.
  24. @cb2004, care to share your solution for the community?
×
×
  • Create New...