Monthly Archiv: December, 2019

Matthias Noback – PHP & Symfony: Defining a custom filter and sorter for Sculpin content types

This blog runs on Sculpin, a static site generator. The generator itself runs on Symfony, which for me makes it easy to extend. However, I find that if you want something special, it can usually be done, but it may take several hours to get it right. In the end though, the solution is often quite el...

murze.be: ★ 📺 Video: Using tags and segments in Mailcoach

My team and I are currently building Mailcoach, a self-hosted solution to easily send out newsletters and email campaigns. In this video, I demonstrate how email lists can be segmented using tags.

Together with Mailcoach, we'll release a video course on how to use Mailcoach, and how it was buil...

A Look at the Proper Usage of the alt Attribute

By now, most of the web design industry knows the importance of accessibility. We talk about it incessantly and implore our clients to take it seriously. There is no denying the impact it has on the web and those who use it.

But sometimes the finer points get lost in the shuffle. For instance, we often hear screams from the virtual mountaintop of “Use alternative text on your images!”. This is good and well-intentioned advice. Still, it’s also a bit vague.

While it’s good to know that the alt attribute can be beneficial in terms of accessibility, what we really need is context. What is the right way to use them? Are there times when we shouldn’t use them?

These questions were inspired by a Twitter conversation I had with a few fellow designers and developers. It helped me realize that I’m not the only one out there who sometimes struggles with how to build websites that do right by users.

Today, we’ll attempt to clarify the proper usage of this vital attribute. Let’s get started!

The Changing Role of Imagery

The way web designers utilize images has changed quite a bit over the years. In the early days of the web, imagery was used in ways we probably wouldn’t think of doing now. We put them to work as page titles, navigation systems and (gasp) even entire pages full of content.

For users that rely on screen readers or other assistive technologies, this could render a page unusable. In cases where vast portions of content were displayed as an image, even a simple alt attribute wasn’t going to be of much help.

Thankfully, some important lessons have been learned. The explosion of web typography has taken away any design-related reasons to misuse images as in the past. And as accessibility has come to the forefront, many now realize that images have specific roles to play.

Person using a laptop computer.

The Importance of Alternative Text

It stands to reason that smarter use of images should result in better accessibility. While that holds true to a degree, we still have the ability to mess things up. This is where alternative text can come in and save the day – if it’s used correctly.

Remembering to use the alt attribute by itself doesn’t necessarily provide much benefit to users. For example, let’s say that we have a heading tag that reads “About Us”. Below that is a group photo of company employees. If we were to simply set the alt attribute to alt=“About Us”, it becomes redundant when read by assistive technologies. Thus, it doesn’t really tell users what the image is or what it means.

So, what should we use instead? A lot depends on the content of the page itself and the image’s role within. This, however, brings up another potential point of confusion.

Thankfully, the W3C has a helpful guide that breaks down images into different concepts:

  • Informative
  • Decorative
  • Functional
  • Images of text
  • Complex
  • Groups of images
  • Image maps

The guide offers brief explanations of each concept, along with examples that can help you determine the most relevant path for providing alternative text. If you’re still unsure, take a look at the alt Decision Tree for more guidance.

How should this photo be described?

Not Always Necessary?

One of the most interesting tidbits of information in the W3C’s guide is that not all images need alt attributes.

But, wait a second. What about all of those calls to use alt every single time? Aren’t we ignoring accessibility?

It turns out that, in the case of decorative images (which don’t add any information to the page), the alt attribute becomes unnecessary. In these situations, providing alternative text can “add audible clutter to screen reader output”. So, much like a lack of whitespace can lead to a cluttered visual page layout, this extra bit of text can do the same for those who rely on these tools.

What makes this difficult for web designers is that automated accessibility tools such as WAVE flag images without alternative text as they read through a page. Even Google may send you annoying emails complaining that a particular image isn’t accessible in their view. This compels us to fill in the attribute, just to pass an automated test.

Therefore, it’s up to us to take these results with a grain of salt and, when necessary, explain the situation to clients. It so happens that an empty alt attribute can be beneficial under specific circumstances.

Example of a decorative image.

It’s About Helping Users

In doing a bit of research about how to use the alt attribute, I came to realize how often I’ve taken the wrong approach. I’d suspect that a lot of designers out there have done the same.

To some degree, it’s understandable. This attribute, while having been around for a long time, isn’t exactly exciting. It’s utilitarian and not always in the front of our minds.

Yet, for a great many users, it is vitally important. Consider that not everyone can easily see the images we integrate into a page. For these folks, the alt attribute is there to help bring context to the content they are consuming.

It’s something to keep in mind as we build an increasingly complex web.

The post A Look at the Proper Usage of the alt Attribute appeared first on Speckyboy Design Magazine.

Derick Rethans: Xdebug Update: November 2019

  Xdebug Update: November 2019 
   
     London, UK 
    Tuesday, December 10th 2019, 09:17 GMT 
   
  Another month, another monthly update where I explain what happened with Xdebug development in this past month. It will be published on the first Tuesday after t...

Community News: Latest PECL Releases (12.10.2019)

Latest PECL Releases:

  • igbinary 3.1.0b3
    * Skip over object properties that are uninitialized or unset when serializing, instead of serializing them as null. This is done to avoid Errors when unserializing their values for php 7.4 typed properties.

  • ev 1.0.8
    - Fixed build warnings with PHP 7.4.0-alpha1: 'incompatible pointer type' warnings occurred in assignments to the write property handlers (thanks to Remi Collet). - Re-fixed the Windows build errors related to errno in a way that the libev sources are left pristine. (The root of the issue is actually rooted in the PHP code where the errno macro is re-defined.)
  • xdebug 2.9.0
    Mon, Dec 9, 2019 - xdebug 2.9.0
    • Improvements:

      • Fixed issue #1723: Class/function pre-analysis for code coverage speed improvements
    • Removed features:

      • Fixed issue #1301: Removed aggregated profiler feature
      • Fixed issue #1720: Remove superfluous xdebug.remote_handler setting

    = Fixed bugs:

    • Fixex issue #1722: Build warning issues on FreeBSD
    • Fixed issue #1724: Missing property types and uninitialised values in variable dumping routines
  • skywalking 3.2.4
    Support php7.4
  • igbinary 3.1.0b2
    * Fix crashes related to unserializing instances of classes with php 7.4 typed properties.
  • igbinary 3.1.0b1
    * Support php 7.4's __serialize/__unserialize the same way serialize()/unserialize() does. This deliberately only supports __serialize/__unserialize in php 7.4, to making switching to/from serialize()/unserialize() as straightforward as possible.
  • rdkafka 4.0.1
    BREAKING CHANGE: Since version 4.0, the client no longer polls for network events at shutdown (during object destructor). This behaviour didn't give enough control to the user in case of server issue, and could cause the script to hang while terminating.

    Starting from 4.0, programs MUST call flush() before shutting down, otherwise some messages and callbacks may be lost.

    Features

    • Added RdKafkaConsumerTopic::consumeCallback() (#310, @nick-zh)

    Enhancements

    • Run integration tests in CI (#223, @Steveb-p)
    • Improved README (#295 #297 #298, #307 @Steveb-p @sndsgd @nick-zh)
    • Fix windows test cases (#296, @cmb69)
    • Add testsuite in pecl archive (#291, @remicollet)
    • Add editor config (#308, @Steveb-p)

    Bugfixes

    • Fix build (#290, @nick-zh)
    • Fix segfault during module shutdown (#293, @arnaud-lb @nick-zh)
    • Fix RdKafkaTopic visibility in PHP 7.4 (#316, @nick-zh)
    • Fix headers memory management in producev (#318 , @nick-zh)
    • Fix partition number in error (#321, @nick-zh)
  • rdkafka 3.1.3
    * Fix segfault during module shutdown (#293, @arnaud-lb @nick-zh) * Fix RdKafkaTopic visibility in PHP 7.4 (#316, @nick-zh)
  • ev 1.0.7
    - Updated libev - Fixed Windows build by applying a patch suggested by Christoph M. Becker.
  • gRPC 1.26.0RC2
    - Fix php5.5 build
  • xhprof 2.1.2
    -- Fixed build with PHP-7.4 #32
  • datadog_trace 0.35.0
    ### Added
    • Compile-time metric #648
    • Health metrics: track segmentation faults #621

    Changed

    • Migrate Mysqli integration to sandboxed api #635
    • Migrate Zend framework integration to sandboxed api #655
    • Migrate Symfony framework integration to sandboxed api #667
    • Migrate Mongo library integration to sandboxed api #669
    • Refactor opcode hooks #659

    Fixed

    • CodeIgniter namespace definition #650
    • Error reporting in case of fatal errors #671
    • Mutation of Memcached result code #663
  • gRPC 1.26.0RC1
    - gRPC Core 1.26.0 update - #20991: Added php.ini option to set custom grpc log location - #20987: Performance improvement to Call::startBatch() - #20903: Init ssl roots cert only once
  • mongodb 1.6.1
    ** Bug * [PHPC-1503] - Fix MONGOC_CC assignment in config.w32 for PHP 7.4

    ** Task

    • [PHPC-1504] - Add PHP 7.4 to AppVeyor build matrix
    • [PHPC-1505] - Update to libmongoc 1.15.2
  • swoole 4.4.13RC1
    New API --- + Built-in Connection Pool ([examples](https://github.com/swoole/library/tree/master/examples)) ([doc](https://wiki.swoole.com/wiki/page/p-library.html)) (@twose)

    Enhancement

    • Support websocket compression on CoroutineHttpServer (#2943) (@twose)
    • Support CURLOPT_PUT, CURLOPT_INFILE, CURLOPT_INFILESIZE (#2954) (@twose)
    • Add error info for bind error (@LeiZhang-Hunter) (@twose) (#2972)
    • Update error info if socket call failed (it will not warn anymore if not necessary) (1e9b8cbb) (@twose)
    • Make library submodule (@twose)

    Fixed

    • Fixed gdbinit in docker (missing symbol) (d46dc2d7 (@twose)
    • Fixed compression in POST request (#2947) (@twose)
    • Fixed compatibility of Websocket->push method (ac7dbcbc) (@twose)
    • Fixed $output result inconsistency (Yurunsoft) (#2955)
    • Fixed Coroutine::fread (#2958) (@matyhtf)
    • Fixed CoroutineServer can not exit normally #2837 (#2962) (@twose)
    • Fixed memory leak in HTTP2Server (#2964) (@twose)
    • Fixed unsafe_event (#2970) (@matyhtf)
    • Fixed illegal call after server start (#2977) (@twose)
    • Fixed WebSocketFrame can not enable mask (#2982) (#2983) (@twose)
    • Fixed memory leak of Process callback (898894a7) (@twose)
    • Fixed case where minfd is never updated (#2985)
    • Fixed HTTP2 module is always enable (3925e212) (@twose)
    • Fixed HTTP2 context double free (#2987) (f4cdff1b) (@twose)
    • Fixed string comparison (#2988) (97c6c425) (9e5eae63) (@twose)
    • Fixed HTTP2 pipeline (#2993) (@twose)
    • Fixed coroutine context has been destroyed (#2991) (@twose)

    Kernel

    • Refactor swoole_(get|set)_object to the way of extending zend_object (more stable and faster) (#2966) (@twose)
    • Support Github Actions (@twose) (@matyhtf)
  • memcached 3.1.5
    PHP 7.0 - 7.1 - 7.2 - 7.3 - 7.4 release of memcached extension. Note that support for libmemcached 0.x series has been discontinued and the oldest actively tested version is 1.0.8. It is highly recommended to use version 1.0.18 of libmemcached.

    Fixes

    • Fix build with PHP 7.4 release due to ulong typedef removal (#445)
  • sqlsrv 5.7.1preview
    [Added] - Support for PHP 7.4 - Support for Red Hat 8 and macOS Catalina (10.15) - Feature Request [#1018](https://github.com/microsoft/msphpsql/issues/1018) - support for [PHP extended string types](https://github.com/microsoft/msphpsql/wiki/Features#natlTypes) - Pull Request [#1043](https://github.com/microsoft/msphpsql/pull/1043) - [Always Encrypted with secure enclaves](https://github.com/microsoft/msphpsql/wiki/Features#alwaysencryptedV2), which requires [MS ODBC Driver 17.4+](https://docs.microsoft.com/sql/connect/odbc/download-odbc-driver-for-sql-server?view=sql-server-ver15) and [SQL Server 2019](https://www.microsoft.com/sql-server/sql-server-2019) [Removed] - Dropped support for [PHP 7.1](https://www.php.net/supported-versions.php) [Fixed] - Issue [#1027](https://github.com/microsoft/msphpsql/issues/1027) - Fixed how drivers handle query timeout settings - Pull Request [#1049](https://github.com/microsoft/msphpsql/pull/1049) - performance improvement for fetching from tables with many columns - cached the derived php types with column metadata to streamline data retrieval [Limitations] - No support for inout / output params when using sql_variant type - No support for inout / output params when formatting decimal values - In Linux and macOS, setlocale() only takes effect if it is invoked before the first connection. Attempting to set the locale after connecting will not work - Always Encrypted requires [MS ODBC Driver 17+](https://docs.microsoft.com/sql/connect/odbc/linux-mac/installing-the-microsoft-odbc-driver-for-sql-server) - Only Windows Certificate Store and Azure Key Vault are supported. Custom Keystores are not yet supported - Issue [#716](https://github.com/Microsoft/msphpsql/issues/716) - With Always Encrypted enabled, named parameters in subqueries are not supported - Issue [#1050](https://github.com/microsoft/msphpsql/issues/1050) - With Always Encrypted enabled, insertion requires the column list for any tables with identity columns - [Always Encrypted limitations](https://docs.microsoft.com/sql/connect/php/using-always-encrypted-php-drivers#limitations-of-the-php-drivers-when-using-always-encrypted) [Known Issues] - Data Classification metadata retrieval requires ODBC Driver 17.4.2.1+ and [SQL Server 2019](https://www.microsoft.com/sql-server/sql-server-2019) - Connection pooling on Linux or macOS is not recommended with [unixODBC](http://www.unixodbc.org/) < 2.3.7 - When pooling is enabled in Linux or macOS - unixODBC <= 2.3.4 (Linux and macOS) might not return proper diagnostic information, such as error messages, warnings and informative messages - due to this unixODBC bug, fetch large data (such as xml, binary) as streams as a workaround. See the examples [here](https://github.com/Microsoft/msphpsql/wiki/Features#pooling)
  • pdo_sqlsrv 5.7.1preview
    [Added] - Support for PHP 7.4 - Support for Red Hat 8 and macOS Catalina (10.15) - Feature Request [#1018](https://github.com/microsoft/msphpsql/issues/1018) - support for [PHP extended string types](https://github.com/microsoft/msphpsql/wiki/Features#natlTypes) - Pull Request [#1043](https://github.com/microsoft/msphpsql/pull/1043) - [Always Encrypted with secure enclaves](https://github.com/microsoft/msphpsql/wiki/Features#alwaysencryptedV2), which requires [MS ODBC Driver 17.4+](https://docs.microsoft.com/sql/connect/odbc/download-odbc-driver-for-sql-server?view=sql-server-ver15) and [SQL Server 2019](https://www.microsoft.com/sql-server/sql-server-2019) [Removed] - Dropped support for [PHP 7.1](https://www.php.net/supported-versions.php) [Fixed] - Issue [#1027](https://github.com/microsoft/msphpsql/issues/1027) - Fixed how drivers handle query timeout settings - Pull Request [#1049](https://github.com/microsoft/msphpsql/pull/1049) - performance improvement for fetching from tables with many columns - cached the derived php types with column metadata to streamline data retrieval [Limitations] - No support for inout / output params when using sql_variant type - No support for inout / output params when formatting decimal values - In Linux and macOS, setlocale() only takes effect if it is invoked before the first connection. Attempting to set the locale after connecting will not work - Always Encrypted requires [MS ODBC Driver 17+](https://docs.microsoft.com/sql/connect/odbc/linux-mac/installing-the-microsoft-odbc-driver-for-sql-server) - Only Windows Certificate Store and Azure Key Vault are supported. Custom Keystores are not yet supported - Issue [#716](https://github.com/Microsoft/msphpsql/issues/716) - With Always Encrypted enabled, named parameters in subqueries are not supported - Issue [#1050](https://github.com/microsoft/msphpsql/issues/1050) - With Always Encrypted enabled, insertion requires the column list for any tables with identity columns - [Always Encrypted limitations](https://docs.microsoft.com/sql/connect/php/using-always-encrypted-php-drivers#limitations-of-the-php-drivers-when-using-always-encrypted) [Known Issues] - Data Classification metadata retrieval requires ODBC Driver 17.4.2.1+ and [SQL Server 2019](https://www.microsoft.com/sql-server/sql-server-2019) - Connection pooling on Linux or macOS is not recommended with [unixODBC](http://www.unixodbc.org/) < 2.3.7 - When pooling is enabled in Linux or macOS - unixODBC <= 2.3.4 (Linux and macOS) might not return proper diagnostic information, such as error messages, warnings and informative messages - due to this unixODBC bug, fetch large data (such as xml, binary) as streams as a workaround. See the examples [here](https://github.com/Microsoft/msphpsql/wiki/Features#pooling)

Zipek PHP ZipArchive Unzip and Zip files

Package:
Zipek PHP ZipArchive Unzip and Zip files
Summary:
Compress or decompress zip files using ZipArchive
Groups:
Compression, Files and Folders, PHP 5
Author:
Ijon Tichy
Description:
This class can compress or decompress ZIP files using ZipArchive...

Read more at https://www.phpclasses.org/package/11461-PHP-Compress-or-decompress-zip-files-using-ZipArchive.html#2019-12-10-05:57:52
Powered by Gewgley