• Namespace
  • Class
  • Tree
  • Deprecated
  • Todo
  • Hooks

Namespaces

  • None
  • SIW
    • Admin
    • API
    • Async
    • Batch
    • Compatibility
    • Data
    • Elements
    • Email
    • External
    • Forms
    • Modules
    • Newsletter
    • Page_Builder
    • Plato
    • Widgets
    • WooCommerce
      • Admin
      • Checkout
      • Email
      • Export
      • Frontend
      • Import

Classes

  • Animation
  • Assets
  • Attachment
  • Autoloader
  • Bootstrap
  • CSS
  • Elements
  • Formatting
  • Forms
  • Head
  • htaccess
  • HTML
  • i18n
  • Icons
  • Login
  • Media_Taxonomies
  • Options
  • Properties
  • Scheduler
  • Shortcodes
  • Update
  • Upload_Subdir
  • Util
  • Widgets

Class Formatting

Hulpfuncties t.b.v. formattering

Namespace: SIW
Copyright: 2019 SIW Internationale Vrijwilligersprojecten
Since: 3.0.0
Located at formatting.php

Methods summary

public static string
# format_percentage( float $percentage, integer $decimals = 0 )

Formatteert getal als percentage

Formatteert getal als percentage

Parameters

$percentage
$decimals

Returns

string
public static string
# format_amount( float $amount, integer $decimals = 0, string $currency_code = 'EUR' )

Formatteert getal als bedrag

Formatteert getal als bedrag

Parameters

$amount
$decimals
$currency_code

Returns

string

Uses

siw_get_currency()
public static
# format_sale_amount( float $amount, float $sale_amount, integer $decimals = 0, string $currency_code = 'EUR' )

Formatteert kortingsbedrag

Formatteert kortingsbedrag

Parameters

$amount
$sale_amount
$decimals
$currency_code
public static string
# generate_columns( array $cells )

Genereert kolommen

Genereert kolommen

Parameters

$cells

Returns

string
public static string
# parse_template( string $template, array $vars )

Parset template o.b.v. variabelen

Parset template o.b.v. variabelen

Parameters

$template
$vars

Returns

string
public static string
# generate_json_ld( array $data )

Genereert script-tag met JSON-LD op basis van array

Genereert script-tag met JSON-LD op basis van array

Parameters

$data

Returns

string
public static string
# format_date( string $date, boolean $year = true )

Formatteert datum als tekst

Formatteert datum als tekst

Parameters

$date
Y-m-d
$year
jaar toevoegen aan tekst

Returns

string
public static string
# format_date_range( string $date_start, string $date_end, boolean $year = true )

Formatteert datumrange als tekst

Formatteert datumrange als tekst

Parameters

$date_start
Y-m-d
$date_end
Y-m-d
$year
jaar toevoegen aan tekst

Returns

string
public static string
# format_month( string $date, boolean $year = true )

Formatteert maand uit datum als tekst

Formatteert maand uit datum als tekst

Parameters

$date
Y-m-d
$year
Jaar toevoegen aan tekst

Returns

string
public static string
# array_to_text( array $array, string $glue = SPACE )

Zet array van zinnen om naar tekst

Zet array van zinnen om naar tekst

Parameters

$array
$glue

Returns

string
public static string
# format_month_range( string $date_start, string $date_end, boolean $year = true )

Formatteert maand-range uit datums als tekst

Formatteert maand-range uit datums als tekst

Parameters

$date_start
Y-m-d
$date_end
Y-m-d
$year
jaar toevoegen aan tekst

Returns

string
public static string
# format_local_fee( float $fee, string $currency_code )

Formatteert lokale bijdrage

Formatteert lokale bijdrage

Parameters

$fee
$currency_code

Returns

string
public static string
# format_number_of_volunteers( integer $total, integer $male, integer $female )

Formatteert aantal vrijwilligers

Formatteert aantal vrijwilligers

Parameters

$total
$male
$female

Returns

string
public static string
# format_age_range( integer $min_age, integer $max_age )

Formatteert leeftijdsrange

Formatteert leeftijdsrange

Parameters

$min_age
$max_age

Returns

string
SIW API documentation generated by ApiGen