Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Number.php

function Number::alphadecimalToInt

Decodes a sorting code back to an integer.

Parameters

string $string: The alpha decimal value to convert

Return value

int The integer value.

See also

\Drupal\Component\Utility\Number::intToAlphadecimal

1 call to Number::alphadecimalToInt()
Comment::preSave in core/modules/comment/src/Entity/Comment.php
Acts on an entity before the presave hook is invoked.

File

core/lib/Drupal/Component/Utility/Number.php, line 97

Class

Number
Provides helper methods for manipulating numbers.

Namespace

Drupal\Component\Utility

Code

public static function alphadecimalToInt($string = '00') {
    return (int) base_convert(substr($string, 1), 36, 10);
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal