Jump to content

justb3a

Members
  • Posts

    321
  • Joined

  • Last visited

  • Days Won

    5

Everything posted by justb3a

  1. Welcome and Thanks. first #btconf Berlin is already over again... /@marcthiele http://t.co/zPKjXGUd7r

  2. mappen kannst du nur vermappen...

  3. enjoyed a ride on a roller coaster through the living room. pretty awesome @webgefrickel #OculusRift #btconf http://t.co/hw0yjk6ahb

  4. two days before the end of the season a car crashed into my motorcycle. thanks for nothing.

  5. @toothpaste: I need much more information. Please paste the error message you get. I'm using the latest ProcessWire as well and everything is going well.
  6. RT @mcs: Mexico has some opinions on your git workflow. #ShaffyMX http://t.co/wuyD8WuYgC

  7. just published my first rails project on #uberspace. @ubernauten thanks a lot for the great wiki and your philosophy!!!

  8. RT @jaimeohm: Coders are special. "We are expected to know how to do things we've never done before and estimate how long they will take." …

  9. RT @dantz: Attention web developers! Because of its thinness the iPad Air 2 only supports z-indexes below 100 – http://t.co/wBbDtxX86K

  10. @tobaco: gurkendoktor is more familiar with the caching issue, I asked him to answer
  11. You can destroy a slider with Javascript for a mobile version. But - you have to load all images (at least the first one) for the slider. And this is not that good in view of performance. (In my case, I do not remove the slider, I just need a modified html structure to use a special slider for mobile devices). Caching is another point to keep in mind, thanks for pointing that out.
  12. you can use this module to change the whole output. If this operation is recommended - there are different opinions on that. I guess it depends on your own needs. Ask two peoples and you get three answers. I use it to change the output (html structure) for a special slider, apart from this just for css assignments (responsive design, the content remains the same).
  13. RT @processwire: New module: Mobile Detect by @justb3a provides API-side tool for detecting mobile devices – http://t.co/8On3ECqNcW

  14. Overview Mobile Detect uses a lightweight PHP class Mobile_Detect for detecting mobile devices (including tablets). Installation 1a. Clone the module and place MobileDetect in your site/modules/ directory. [OR] 1b. Download it. git clone https://github.com/justonestep/processwire-mobiledetect.git your/path/site/modules/MobileDetect 2. Login to ProcessWire admin and click Modules. 3. Click "Check for new modules". 4. Click "install" next to the new SimpleContactForm module. Usage This Module extends $config and sets the following parameters: $config->mobileDetect = array( 'deviceType' => 'deviceType (phone, tablet or desktop)', 'browser' => 'mobile browser', 'operatingsystem' => 'mobile operatingsystem', 'device' => 'mobile device' ); You can access them where ever you want. See the example below: <body class="devicetype--<?php echo $config->mobileDetect->deviceType?>"> <body class="devicetype--{{config.mobileDetect.deviceType}}"> // twig Results in: <body class="devicetype--phone"> OR<body class="devicetype--tablet"> OR<body class="devicetype--desktop">
  15. If you need more than the description field to be translated, you can use the Module FieldtypeImageExtra.
  16. Thank you for the snippets, I used them to build a little Module to handle multi-language Image Descriptions and further image informations. Have a look at the module FieldtypeImageExtra.
  17. I felt the same need, that's why I build a little Module to handle multi-language Image Descriptions and further image informations. Have a look at the module FieldtypeImageExtra, maybe it helps you.
  18. Adds twig support for language translator list. To get your `.twig` files listed as well, you need to wrap the phrases like this: {{ __('text to translate', 'filepath/filename relative to site/templates/') }} {{ __('another text to translate', 'home') }} {{ __('one more text to translate', 'partials/header') }} first line - general usage second line - example for a text in site/templates/home.twig third line - example tor a text in site/templates/partials/header.twig
  19. This module is obsolete and will not be developed any further. Please use the ImageExtra Module instead. Overview This module allows you to add additional informations to an image (for example: title, description, link, orientation and any field you may need). If you want to, you can install FieldtypeImageExtraLanguage to get multi-language support. For more informations have a look at the readme. Installation 1a. Clone the module and place FieldtypeImageExtra in your site/modules/ directory. [OR] 1b. Download and unzip it from the module page. git clone https://github.com/justonestep/processwire-fieldtypeimageextra.git your/path/site/modules/FieldtypeImageExtra 2. Login to ProcessWire admin and click Modules. 3. Click "Check for new modules". 4. Click "install" next to the new FieldtypeImageExtra module. If you need multi-language support, you have to install the FieldtypeImageExtraLanguage module. 5. That's all - no settings are required but possible. Define your custom fields 1. Login to ProcessWire admin and click Modules. 2. Open `Images Extra Inputfield` Settings. The following fields are available by default: orientation - image orientation orientation values - values to use as classnames or identifiers for different image orientations title - image title to use for title/alt tag or/and caption, if empty, the content will be generated from the applications filename description - image description link - image link to internal pages If these fields are not enough for you, you can add any other field (for example _author_ and _location_) by writing it (separated by comma) in the field otherField. If you don't need all custom fields, you can easily disable them. One more exception is orientationValues. Here you can insert identifiers for classnames or similar separated by comma. This values will be available in a dropdown list. Usage 1. Under Setup and Fields create a new field using type `ImageExtra` or `ImageExtraLanguage`. 2. After entering the new field name and label, click Save. 3. Configure it depending on your own needs. 4. Save. 5. Add your new field to one or more Templates. Accessing the value This is no different than accessing the value of any other field. $image = $page->image->getRandom(); echo $image->title; echo $pages->get($image->link)->url For use with TemplateTwigReplace {% set image = page.images.getRandom() %} {{image.title}} {{pages.get(image.link).url}} Screenshots Here is a litte example how to access the new fields: // if there are images, lets choose one to output in the sidebar if (count($page->images)) { // if the page has images on it, grab one of them randomly... $image = $page->images->getRandom(); // resize it to 400 pixels wide $image = $image->width(400); // output the image at the top of the sidebar $sidebar = "<img src='$image->url' alt='$image->description' />" . "<h3>$image->title</h3>" . "<blockquote>$image->description</blockquote>" . "<p>$image->author ($image->location)</p>" . $page->sidebar; }
×
×
  • Create New...