Validate_ISPN
[ class tree: Validate_ISPN ] [ index: Validate_ISPN ] [ all elements ]

Class: Validate_ISPN

Source Location: /Validate_ISPN-0.6.1/Validate/ISPN.php

Class Overview


Data validation class for International Standard Product Numbers (ISPN)


Author(s):

Version:

  • Release: @package_version@

Copyright:

  • 1997-2005 Piotr Klaban, Damien Seguy, Helgi Žormar Žorbjörnsson, Pierre-Alain Joye

Methods


Inherited Variables

Inherited Methods


Class Details

[line 59]
Data validation class for International Standard Product Numbers (ISPN)

This class provides methods to validate:

  • ISBN (International Standard Book Number)
  • ISSN (International Standard Serial Number)
  • ISMN (International Standard Music Number)
  • ISRC (International Standard Recording Code)
  • EAN/UCC-8 number
  • EAN/UCC-13 number
  • EAN/UCC-14 number
  • UCC-12 (U.P.C.) ID number
  • SSCC (Serial Shipping Container Code)



[ Top ]


Method Detail

ean8   [line 255]

bool ean8( string $ean)

Validate a EAN/UCC-8 number

This function checks given EAN8 number used to identify trade items and special applications. http://www.ean-ucc.org/ http://www.uc-council.org/checkdig.htm


Parameters:

string   $ean     number (only numeric chars will be considered)

[ Top ]

ean13   [line 275]

bool ean13( string $ean)

Validate a EAN/UCC-13 number

This function checks given EAN/UCC-13 number used to identify trade items, locations, and special applications (e.g., coupons) http://www.ean-ucc.org/ http://www.uc-council.org/checkdig.htm


Parameters:

string   $ean     number (only numeric chars will be considered)

[ Top ]

ean14   [line 295]

bool ean14( string $ean)

Validate a EAN/UCC-14 number

This function checks given EAN/UCC-14 number used to identify trade items. http://www.ean-ucc.org/ http://www.uc-council.org/checkdig.htm


Parameters:

string   $ean     number (only numeric chars will be considered)

[ Top ]

isbn   [line 61]

void isbn( $isbn)


Parameters:

   $isbn     

[ Top ]

isbn10   [line 124]

bool isbn10( string $isbn)

Validate a ISBN 10 number The ISBN is a unique machine-readable identification number, which marks any book unmistakably.

This function checks given number according

Manual can be found at http://www.isbn-international.org

  • Return: true if number is valid, otherwise false
  • Author: Damien Seguy <dams@nexen.net>
  • Author: Helgi Žormar <dufuz@php.net>
  • Access: public

Parameters:

string   $isbn     number (only numeric chars will be considered)

[ Top ]

isbn13   [line 94]

bool isbn13( string $isbn)

Validate a ISBN 13 number The ISBN is a unique machine-readable identification number, which marks any book unmistakably.

This function checks given number according

Manual can be found at http://www.isbn-international.org


Parameters:

string   $isbn     number (only numeric chars will be considered)

[ Top ]

ismn   [line 194]

bool ismn( string $ismn)

Validate a ISMN (International Standard Music Number)

This function checks given ISMN number (ISO Standard 10957) ISMN identifies all printed music publications from all over the world whether available for sale, hire or gratis--whether a part, a score, or an element in a multi-media kit.

Manual can be found at: http://www.ismn-international.org/

  • Return: true if number is valid, otherwise false
  • Author: Piotr Klaban <makler@man.torun.pl>
  • Access: public

Parameters:

string   $ismn     ISMN number

[ Top ]

isrc   [line 231]

bool isrc( string $isrc)

Validate a ISRC (International Standard Recording Code)

This function validates an International Standard Recording Code which is the international identification system for sound recordings and music videorecordings.


Parameters:

string   $isrc     ISRC number

[ Top ]

issn   [line 160]

bool issn( string $issn)

Validate an ISSN (International Standard Serial Number)

This function checks given ISSN number ISSN identifies periodical publications: http://www.issn.org

  • Return: true if number is valid, otherwise false
  • Author: Piotr Klaban <makler@man.torun.pl>
  • Access: public

Parameters:

string   $issn     number (only numeric chars will be considered)

[ Top ]

process   [line 354]

bool process( int $data, $length, &$weights, [int $modulo = 10], [int $subtract = 0], int $lenght, array $weights)

Does all the work for EAN8, EAN13, EAN14, UCC12 and SSCC and can be used for as base for similar kind of calculations
  • Return: true if number is valid, otherwise false
  • See: Validate::_checkControlNumber()
  • Access: public

Parameters:

int   $data     number (only numeric chars will be considered)
int   $lenght     required length of number string
int   $modulo     (optionsl) number
int   $subtract     (optional) numbier
array   $weights     holds the weight that will be used in calculations for the validation
   $length     
   &$weights     

[ Top ]

sscc   [line 335]

bool sscc( string $sscc)

Validate a SSCC (Serial Shipping Container Code)

This function checks given SSCC number used to identify logistic units. http://www.ean-ucc.org/ http://www.uc-council.org/checkdig.htm


Parameters:

string   $sscc     number (only numeric chars will be considered)

[ Top ]

ucc12   [line 315]

bool ucc12( string $ucc)

Validate a UCC-12 (U.P.C.) ID number

This function checks given UCC-12 number used to identify trade items, locations, and special applications (e.g., * coupons) http://www.ean-ucc.org/ http://www.uc-council.org/checkdig.htm


Parameters:

string   $ucc     number (only numeric chars will be considered)

[ Top ]


Documentation generated on Tue, 27 Mar 2007 19:00:04 -0400 by phpDocumentor 1.3.0. PEAR Logo Copyright © PHP Group 2004.