Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 05/12/2015 in all areas

  1. Another small, but potentially helpful module. This fieldtype references a field in a page, where the field's data is retrieved from a somehow related remote page. It's kinda like a one way symlink to a remote field. To make this description a little easier to understand I'll just add a example. Imagine you've some pages placed all over the page-tree, but you need editors to be aware of a specific setting in a single page. With this Fieldtype you would set this up like this: - Get the page (php snippet kinda like for page fields) return $pages->get("/special-settings-page/"); - Setup template to field pairing settings=my_special_field - Add this field to any template you need this on. Now this special setting is visible in the backend, if someone edits a page with this reference field, and via the api as read-only field. The field can use all collapsed modes, which do not allow editing, so it can be hidden if it's only needed by the api. This can be useful for content heavy sites, where information is scattered around multiple (parent) pages, but maybe all information needs to be available for the children. It's also nice for creating (shorter) selectors for inputfield dependencies or dynamic page fields. More elaborate examples about this options can be found in the readme of the module. Todo Add checks to prevent infinite loops Maybe make it a field, which can be edited and saved. GitHub: https://github.com/LostKobrakai/FieldtypeReference
    5 points
  2. If it works (can't test) it would be best to add those settings to the site/modules/InputfieldCKEditor dir. Nice stuff, because the table plugin always bothered me.
    3 points
  3. This is the solution to remove unwanted table attributes from CKEditor. Go to /wire/modules/Inputfield/InputfieldCKEditor/ckeditor-4.4.6/config.js and insert this piece of code into the config.js: CKEDITOR.on( 'dialogDefinition', function( ev ) { var dialogName = ev.data.name; var dialogDefinition = ev.data.definition; if (dialogName == 'table') { // Get the advanced tab reference var infoTab2 = dialogDefinition.getContents('advanced'); //Set the default // Remove the 'Advanced' tab completely dialogDefinition.removeContents('advanced'); // Get the properties tab reference var infoTab = dialogDefinition.getContents('info'); // Remove unnecessary bits from this tab infoTab.remove('txtBorder'); infoTab.remove('cmbAlign'); infoTab.remove('txtWidth'); infoTab.remove('txtHeight'); infoTab.remove('txtCellSpace'); infoTab.remove('txtCellPad'); infoTab.remove('txtCaption'); infoTab.remove('txtSummary'); } }); After that you have only a few attributes left. This is the best way to prevent customers from filling out useless table attributes. This works for other plugins (images, links and so on) too. A big thanks to Lostkobrakai for pointing me into the right direction.
    3 points
  4. Page Field Edit Links GitHub: https://github.com/thetuningspoon/AdminPageFieldEditLinks Direct Download: https://github.com/thetuningspoon/AdminPageFieldEditLinks/archive/master.zip This module is based on--and is the successor to--Macrura's AdminPageSelectEditLinks (https://processwire.com/talk/topic/8477-adminpageselecteditlinks-module-for-enabling-edit-links-on-multipage-selects/) Page Field Edit Links adds modal editing capability to ProcessWire's Page fields in the admin editor, allowing editors to easily view and edit the content of any page(s) that have been selected, as well as create new pages without leaving the current screen. Edit links are updated in real time when new pages are added to the field. Compatible with all available types of Inputfields including Select, SelectMultiple, Checkboxes, Radios, AsmSelect, PageListSelect, PageListSelectMultiple, and PageAutocomplete.
    2 points
  5. very simple module to turn this: into this: <?php /** * ProcessWire Yumpu Replace Textformatter * * @copyright Copyright (c) 2015, Bernhard Baumrock, dimacon.at */ class TextformatterYumpu extends Textformatter { public static function getModuleInfo() { return array( 'title' => 'Yumpu replace', 'version' => 1, 'summary' => 'Replaces Yumpu Links with responsive Iframes', 'author' => 'Bernhard Baumrock, dimacon.at', ); } /** * Format the input string * * @param string $str The block of text to parse * * The incoming string is replaced with the formatted version of itself. **/ public function format(&$str) { // convert yumpu links to iframes $str = preg_replace("/https:\/\/www.yumpu.com\/(..\/)?embed\/view\/\w*/", '<div class="TextformatterVideoEmbed" style="position:relative;padding:30px 0 56.25% 0;height:0;overflow:hidden;"><iframe style="position:absolute;top:0;left:0;width:100%;height:100%;" width="640" height="360" src="\0" frameborder="0" allowfullscreen></iframe></div>', $str); } } I think there are also other solutions but maybe this one fits better for someone...
    2 points
  6. Not as unusual of an need: https://processwire.com/talk/topic/9879-fieldtypereference/ Edit: If you need the whole page instead of a field you'd just need to adjust the module by removing the whole "get a field" part.
    2 points
  7. I just pushed version 1.0.3. This version introduces a new option: "Do not detect language if GET parameter is set". You can now set a GET parameter to prevent language redirection on some requests with this parameter. For example, if this parameter is set to "nodetect" and the user requests "http://example.com/de/?nodetect", the plugin will not redirect the user to the user's preferred language or fall back to default.
    2 points
  8. I thought that new Avatar was some extremist uniform until I realised it was a Viking outfit. But I showed this post to a developer friend via Skype. The conversation went like this: Me: ProcessWire scalability (and link to thread) Friend: Impressive - ISIS must be very pleased with their dev Me: that's a beard ! Friend :oh, horns. obviously casual Friday
    2 points
  9. Thats not a beard, my chin just hit puberty
    2 points
  10. want to say many thanks to @thetuningspoon for putting this together, and doing all the work of submitting to the directory. It's surely a useful module (use it almost every site), and we hope that all y'all will like it..
    2 points
  11. PDF Fieldtype/Inputfield Module for ProcessWire allowing you to easily generate thumbnails of the PDF files embedded to the site. Current version: 1.1.2 (Changelog) Module page: http://modules.processwire.com/modules/fieldtype-pdf Github: https://github.com/uiii/ProcessWire-FieldtypePDF For detailed instructions see: https://github.com/uiii/ProcessWire-FieldtypePDF/blob/master/README.md
    1 point
  12. On GitHub: https://github.com/plauclair/AutodetectLanguage PW's Modules repo: http://modules.processwire.com/modules/autodetect-language/ This ProcessWire 2.x module tries finds a best match between HTTP_ACCEPT_LANGUAGE and currently installed languages. If a match is found, the user will be redirected from the requested page to the same page in his preferred language. This match occurs only on the first page load, and will work with default caching on. If no match is found, the website will revert back to the "default" language. Installation info and more details on GitHub. Please submit any bug on the bug tracker, as it is easier to track different issues.
    1 point
  13. Words of encouragement from the Pub's amateur psychiatrist (Read best in a soft spoken, German accent) Ah, you are here because you have been reading things in this forum about pages that have left you confused, disorientated, befuddled. You thought you knew what a page was - you have been thumbing through them, folding them, studying them, wrapping things up in them and scrolling up and down them for most of your life! A page is this solid item - this great lump of data stuffed with things. But now you have come to Processwire, and everything you thought was true, simply isn't any more. For in Processwire pages are completely different - they are not great gulps of information, but tiny little things, nothing more than a link to the more interesting world of fields and templates; just a little blip of data in your huge fascinating database. Pages in Processwire are used for all kinds of things. They can be used as a marker in your pages list. They can be used as a group parent for other pages. They can be used as categories, tags or lists or users. And they can even be used for simple drop-down selects - just to supply a label and value. It can seem crazy to use such an iconic thing like a page for such a mundane and trivial task! But don't worry and fret, don't lose sleep or pace the floor as you think the reputation of the noble page is being crushed! In Processwire, they are fulfilling their duty to the full - and the more slight the task, the more they bound up to the wall and jump up and down shouting "use me, use me!" And, as a bonus, they can even be used for content - for all that stuff you thought was a page, but in Processwire isn't! So, don't be put off by the Processwire page - use it for everything! it is much smaller than you think, takes up hardly any space at all, is well behaved and only will do its thing when it is called. In fact it is hardly a page at all .... and then again, it is also so much more!! Better now? Joss Freud
    1 point
  14. Hi Alan you have to do all yourself through ssh, there´s a lot of information well documented in bitnami.com, it worth a look or two.
    1 point
  15. Or you can go even shorter with: $fields->yourField->icon
    1 point
  16. Hi, thanks for the reply. I haven't tried the PW 2.6 yet. The reason why I used image inputfield is to render the PDF thumbnails exactly the same way as images. But maybe you are right, I should have used my own render method. I'll check it out.
    1 point
  17. Another way is {$page->fields->yourField->icon}
    1 point
  18. No problem! "start" is hidden - try turning on Advanced Mode on the API Cheatsheet and you'll see it under the selectors section.
    1 point
  19. Hi Adrian. You are fast. And it works as expected. Don't know that there is a "start" selector at all. I can't find any document mention about it. Thanks a lot. Gideon
    1 point
  20. I think you need to override the "start" selector that is being added from PagerNav. Setting it to 0 should fix things. $grandChildren = $child->children("limit=5, start=0");
    1 point
  21. Hi, I installed this module on 2.5.25 version and as soon as I tried to create a new field I got the following error. Any ideas? Error: Using $this when not in object context (line 112 of /home/maloco15/public_html/site/modules/FieldtypeSelectExtOption/FieldtypeSelectExtOption.module) This error message was shown because you are logged in as a Superuser. Error has been logged
    1 point
  22. How about this? http://docs.ckeditor.com/#!/guide/dev_howtos_dialog_windows
    1 point
  23. Another German article about PW. This time by a huge hoster (300.000+ users): https://www.df.eu/blog/2015/05/11/processwire-ein-cms-mit-besonderer-flexibilitaet/
    1 point
  24. I know... old... This is why I bought form-builder and actually never use it ...
    1 point
  25. Blog version 2 Introducing Blog version 2! There are lots of changes so this will be a long read. For upgrading from version 1 to this version, please read the next post. I’ll appreciate beta testers. As you’ll see below, there’s lots of new things (and combination of things!) to test. Many thanks! TL:DR: Blog version 2 is available for beta testing. It comes with a two-step installer that allows you to structure where your Blog lives in your page tree just the way you want and cleans-up after itself in case it isn’t your cup of tea. Please see next post about updating version 1 to 2. Main Changes 1. Configurable Blog 2 is a now configurable module (i.e. ProcessBlog). On a fresh install, you will first have to set a couple of settings before you can run the module. More on this below. 2. Installer Blog 2 comes with a two-step installer. No more installing things you don’t want. In the first step, you set the module configurations in the module settings page as mentioned in #1. The configurable settings are outlined later below. In the second step, via the Blog dashboard, you will see an overview of the settings you selected in the first step above. Here you finalise Blog’s installation. Before you click the button to run the install wizard, nothing will happen yet. You can still go back and change the module configuration settings. Until you run the install wizard in this second step, you will have no Blog pages, fields, templates, etc. On this page, you will also be able to rename your Blog’s main pages before they are created. Yes! If you don’t do it at this stage, you can also rename them post-install in the ProcessWire tree! If you are happy with your settings, click the install wizard to proceed. Blog will be fully installed with your settings before you can dash out to make a coffee . You will then see the familiar Blog dashboard Please note: If you need to change some configurations, you can go back to the module settings and do it BEFORE you finalise step two of the installation. It is important that once the installation is finalised, in case you had left the ProcessBlog's module configuration's browser window open, NOT to press submit again. Otherwise, MarkupBlog may not like it . However, if you reload the module configurations screen once the second-part of the installer has finished, you will not be able to change the configuration settings. Instead, you will be presented with an overview of your installed settings. 3. Blog styles Blog now allows you to install your Blog pages from a choice of 4 different URL structures, aka Blog styles! These should cover most (all?) needs. This means that your Blog pages will live exactly where you want them in the tree, hence give you the URL you want. You select the style you want in ProcessBlog’s module configuration screen (first step of the installer). A visual of the 4 styles is presented on that screen. Example paths for the 4 styles are: Blog style 1: /mysite/blog/posts/example-post/ (similar to Blog version 1) Blog style 2: /mysite/blog/example-post/ (as requested by FuturShoc) Blog style 3: /mysite/posts/example-post/ (same as Ryan’s Blog profile) Blog style 4: /mysite/example-post/ (as requested by PWired) 4. Commenting feature In the first step of the installer (module's configuration's screen), you can choose to install commenting feature or not. The default is to install commenting feature. If you elect not to install this feature, Blog will not install any comments-related components – so no comment fields, associated pages, templates and template files! Note, you CANNOT add this setting once Blog install has been finalised. 5. Auto-publish/unpublish This much requested feature has now arrived! You choose whether to install this feature or not via ProcessBlog’s module configuration screen. The default is auto-publish/unpublish is not enabled. If you want to use this feature, you will FIRST have to install the great SchedulePages module. If you have the module installed, this will be specified in Blog’s module configuration screen. Again you will not be able to proceed with installing this feature unless SchedulePages is installed. If you install this feature, you will see two date fields when editing a blog post, i.e. ‘Auto-publish from’ and ‘Auto-unpublish on’. You will also see these two date fields in Blog’s Quick post’s dashboard. Note, you CANNOT add this setting once Blog install has been finalised. 6. Templates Blog will install templates according to the Blog style you have selected. So, if you went with style #4, you will not have a template called ‘blog’ nor one called ‘blog-posts’. 7. Template files In the first step of the installer (module configurations screen – I know, I am repeating myself!), you have three options when it comes to template files when installing Blog. The default is to install blank template files (with nothing but php tags – a little something to help you get started quickly). The second option is to install demo blog template files (more on this later) and the third is not to install any template files. 8. Demo template files These files have now been streamlined. No more verbose code! A blog-main.inc contains most of the markup and the other template files contain most of the code. The demo will work with any of the 4 Blog styles. 9. Cleanup One of the annoying things with Blog version 1 was not only that it installed things you probably did not need, it also left behind, uh, leftovers (templates, role, pages, fields, template files). Well, no more! Uninstalling Blog is now a two-step process. If you are logged in as a superuser, you will see a Blog menu item called ‘Cleanup’. It will lead to a screen with info about all the fields, templates, pages and role you are about to delete. It will also list the Blog template files that, if you wish, you can also delete. This utility is also useful when you want to try out the different Blog styles without uninstalling the whole Blog module. It returns Blog to the state similar to when you first installed the module. Of course, in case you want to remove Blog as well, just go ahead and uninstall in the normal way but AFTER you have cleaned-up . 10. Renaming Blog pages As mentioned previously, you can rename any of your Blog pages pre- or post-install. Want Diary or Journal instead of Blog? Sure, go ahead. Want Writers instead of Authors? What about Chronicles in lieu of Archives? You can have those too. The only things you should NOT do are to delete the main Blog pages (i.e. anything other than Example Tag, Example Category and Example Post) OR (however remote the chance of this is) CHANGE the IDs of these pages (in the database). In order to allow for flexibility, Blog stores and tracks its main pages using their IDs. 11. Fields and templates admin tag In step 1 of the installer you can choose to change the default name of the tag used to group Blog fields and templates in the admin. You can as well choose not to have any tag and let anarchy reign in your admin pages! 12. Context aware Most of the Blog dashboard is now context aware. It will only display info about Blog components that are installed. No comments? Fine, no comments in Posts dashboard, etc. Apart from ‘Posts’ dashboard, the other Blog dashboards will be labelled according to the titles of your main Blog pages. For instance, if you called ‘Categories’ ‘Classifications’, that is the name you will see in the ‘Categories’ dashboard label. Same for Authors, Tags, etc. Even Cleanup is context aware and will only list components related to the Blog style you installed. OK, so how do I get Blog 2? You can install via ProcessWire modules screen. get it on the dev branch of Blog in GitHub. It is also attached below (please use Github - it is the latest version). I thoroughly tested this but I probably missed something or mixed up my code somewhere so there could be bugs . Please help me find and swat them, thanks! Next post, updating Blog 1 to 2.
    1 point
  26. Can I just say that if ever there is a book written about how to use ProcessWire, this should be the foreword - it's perfect! I did fail to read it in the suggested accent and read it in an Austrian Arnold Schwarzenegger accent - it was amazing (like this - http://bit.ly/c7op9H ).
    1 point
  27. I'm using a nice variation of the infinite scroll http://www.fieg.nl/i...a-jquery-plugin This plugin it's really easy to use, it doesn't requires any particular modification in the code because it uses the pagination links to generate the infinite scroll, in this way also google is happy because I generate my content with pagination as usual and the users have the enhanced version.
    1 point
×
×
  • Create New...