00001 <?php
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040 include_once( 'lib/ezxml/classes/ezxml.php' );
00041 include_once( 'kernel/classes/ezcontentclass.php' );
00042 include_once( 'kernel/classes/ezpackagehandler.php' );
00043
00044 define( "EZ_PACKAGE_CONTENTCLASS_ERROR_EXISTS", 1 );
00045 define( "EZ_PACKAGE_CONTENTCLASS_ERROR_HAS_OBJECTS", 101 );
00046
00047 define( "EZ_PACKAGE_CONTENTCLASS_REPLACE", 1 );
00048 define( "EZ_PACKAGE_CONTENTCLASS_SKIP", 2 );
00049 define( "EZ_PACKAGE_CONTENTCLASS_NEW", 3 );
00050 define( "EZ_PACKAGE_CONTENTCLASS_DELETE", 4 );
00051
00052 class eZContentClassPackageHandler extends eZPackageHandler
00053 {
00054
00055
00056
00057 function eZContentClassPackageHandler()
00058 {
00059 $this->eZPackageHandler( 'ezcontentclass',
00060 array( 'extract-install-content' => true ) );
00061 }
00062
00063
00064
00065
00066
00067 function explainInstallItem( &$package, $installItem )
00068 {
00069 if ( $installItem['filename'] )
00070 {
00071 $filename = $installItem['filename'];
00072 $subdirectory = $installItem['sub-directory'];
00073 if ( $subdirectory )
00074 $filepath = $subdirectory . '/' . $filename . '.xml';
00075 else
00076 $filepath = $filename . '.xml';
00077
00078 $filepath = $package->path() . '/' . $filepath;
00079
00080 $dom =& $package->fetchDOMFromFile( $filepath );
00081 if ( $dom )
00082 {
00083 $content =& $dom->root();
00084
00085
00086 $className = $content->elementTextContentByName( 'name' );
00087 if( !$className )
00088 {
00089
00090 $serializedNameList = $content->elementTextContentByName( 'serialized-name-list' );
00091 if( $serializedNameList )
00092 {
00093 $nameList = new eZContentClassNameList( $serializedNameList );
00094 $className = $nameList->name();
00095 }
00096 }
00097
00098 $classIdentifier = $content->elementTextContentByName( 'identifier' );
00099 return array( 'description' => ezi18n( 'kernel/package', "Content class '%classname' (%classidentifier)", false,
00100 array( '%classname' => $className,
00101 '%classidentifier' => $classIdentifier ) ) );
00102 }
00103 }
00104 }
00105
00106
00107
00108
00109
00110 function uninstall( &$package, $installType, $parameters,
00111 $name, $os, $filename, $subdirectory,
00112 &$content, &$installParameters,
00113 &$installData )
00114 {
00115 $classRemoteID = $content->elementTextContentByName( 'remote-id' );
00116
00117 $class = eZContentClass::fetchByRemoteID( $classRemoteID );
00118
00119 if ( $class == null )
00120 {
00121 eZDebug::writeNotice( "Class having remote id '$classRemoteID' not found.", 'eZContentClassPackageHandler::uninstall()' );
00122 return true;
00123 }
00124
00125 if ( $class->isRemovable() )
00126 {
00127 $choosenAction = $this->errorChoosenAction( EZ_PACKAGE_CONTENTCLASS_ERROR_HAS_OBJECTS,
00128 $installParameters );
00129 if ( $choosenAction == EZ_PACKAGE_CONTENTCLASS_SKIP )
00130 {
00131 return true;
00132 }
00133 if ( $choosenAction != EZ_PACKAGE_CONTENTCLASS_DELETE )
00134 {
00135 $objectsCount = eZContentObject::fetchSameClassListCount( $class->attribute( 'id' ) );
00136 $name = $class->attribute( 'name' );
00137 if ( $objectsCount )
00138 {
00139 $installParameters['error'] = array( 'error_code' => EZ_PACKAGE_CONTENTCLASS_ERROR_HAS_OBJECTS,
00140 'element_id' => $classRemoteID,
00141 'description' => ezi18n( 'kernel/package',
00142 "Removing class '%classname' will result in the removal of %objectscount object(s) of this class and all their sub-items. Are you sure you want to uninstall it?",
00143 false,
00144 array( '%classname' => $name,
00145 '%objectscount' => $objectsCount ) ),
00146 'actions' => array( EZ_PACKAGE_CONTENTCLASS_DELETE => "Uninstall class and object(s)",
00147 EZ_PACKAGE_CONTENTCLASS_SKIP => 'Skip' ) );
00148 return false;
00149 }
00150 }
00151
00152 eZDebug::writeNotice( sprintf( "Removing class '%s' (%d)", $class->attribute( 'name' ), $class->attribute( 'id' ) ) );
00153
00154 include_once( 'kernel/classes/ezcontentclassoperations.php' );
00155 eZContentClassOperations::remove( $class->attribute( 'id' ) );
00156 }
00157
00158 return true;
00159 }
00160
00161
00162
00163
00164
00165 function install( &$package, $installType, $parameters,
00166 $name, $os, $filename, $subdirectory,
00167 &$content, &$installParameters,
00168 &$installData )
00169 {
00170 $classNameList = new eZContentClassNameList( $content->elementTextContentByName( 'serialized-name-list' ) );
00171 if ( $classNameList->isEmpty() )
00172 $classNameList->initFromString( $content->elementTextContentByName( 'name' ) );
00173 $classNameList->validate();
00174
00175 $classIdentifier = $content->elementTextContentByName( 'identifier' );
00176 $classRemoteID = $content->elementTextContentByName( 'remote-id' );
00177 $classObjectNamePattern = $content->elementTextContentByName( 'object-name-pattern' );
00178 $classIsContainer = $content->attributeValue( 'is-container' );
00179 if ( $classIsContainer !== false )
00180 $classIsContainer = $classIsContainer == 'true' ? 1 : 0;
00181
00182 $classRemoteNode = $content->elementByName( 'remote' );
00183 $classID = $classRemoteNode->elementTextContentByName( 'id' );
00184 $classGroupsNode = $classRemoteNode->elementByName( 'groups' );
00185 $classCreated = $classRemoteNode->elementTextContentByName( 'created' );
00186 $classModified = $classRemoteNode->elementTextContentByName( 'modified' );
00187 $classCreatorNode = $classRemoteNode->elementByName( 'creator' );
00188 $classModifierNode = $classRemoteNode->elementByName( 'modifier' );
00189
00190 $classAttributesNode = $content->elementByName( 'attributes' );
00191
00192 $dateTime = time();
00193 $classCreated = $dateTime;
00194 $classModified = $dateTime;
00195
00196 $userID = false;
00197 if ( isset( $installParameters['user_id'] ) )
00198 $userID = $installParameters['user_id'];
00199
00200 $class = eZContentClass::fetchByRemoteID( $classRemoteID );
00201
00202 if ( $class )
00203 {
00204 $className = $class->name();
00205 $description = ezi18n( 'kernel/package', "Class '%classname' already exists.", false,
00206 array( '%classname' => $className ) );
00207
00208 $choosenAction = $this->errorChoosenAction( EZ_PACKAGE_CONTENTCLASS_ERROR_EXISTS,
00209 $installParameters, $description );
00210 switch( $choosenAction )
00211 {
00212 case EZ_PACKAGE_NON_INTERACTIVE:
00213 case EZ_PACKAGE_CONTENTCLASS_REPLACE:
00214 include_once( 'kernel/classes/ezcontentclassoperations.php' );
00215 if ( eZContentClassOperations::remove( $class->attribute( 'id' ) ) == false )
00216 {
00217 eZDebug::writeWarning( "Unable to remove class '$className'." );
00218 return true;
00219 }
00220 eZDebug::writeNotice( "Class '$className' will be replaced.", 'eZContentClassPackageHandler' );
00221 break;
00222
00223 case EZ_PACKAGE_CONTENTCLASS_SKIP:
00224 return true;
00225
00226 case EZ_PACKAGE_CONTENTCLASS_NEW:
00227 $class->setAttribute( 'remote_id', md5( (string)mt_rand() . (string)mktime() ) );
00228 $class->store();
00229 $classNameList->appendGroupName( " (imported)" );
00230 break;
00231
00232 default:
00233 $installParameters['error'] = array( 'error_code' => EZ_PACKAGE_CONTENTCLASS_ERROR_EXISTS,
00234 'element_id' => $classRemoteID,
00235 'description' => $description,
00236 'actions' => array() );
00237 if ( $class->isRemovable() )
00238 {
00239 $errorMsg = ezi18n( 'kernel/package', "Replace existing class" );
00240 $objectsCount = eZContentObject::fetchSameClassListCount( $class->attribute( 'id' ) );
00241 if ( $objectsCount )
00242 $errorMsg .= ' ' . ezi18n( 'kernel/package', "(Warning! $objectsCount content object(s) and their sub-items will be removed)" );
00243 $installParameters['error']['actions'][EZ_PACKAGE_CONTENTCLASS_REPLACE] = $errorMsg;
00244 }
00245 $installParameters['error']['actions'][EZ_PACKAGE_CONTENTCLASS_SKIP] = ezi18n( 'kernel/package', 'Skip installing this class' );
00246 $installParameters['error']['actions'][EZ_PACKAGE_CONTENTCLASS_NEW] = ezi18n( 'kernel/package', 'Keep existing and create a new one' );
00247 return false;
00248 }
00249 }
00250
00251 unset( $class );
00252
00253
00254 $currentClassIdentifier = $classIdentifier;
00255 $unique = false;
00256
00257 while( !$unique )
00258 {
00259 $classList = eZContentClass::fetchByIdentifier( $currentClassIdentifier );
00260 if ( $classList )
00261 {
00262
00263 if ( preg_match( '/^(.*)_(\d+)$/', $currentClassIdentifier, $matches ) )
00264 $currentClassIdentifier = $matches[1] . '_' . ( $matches[2] + 1 );
00265 else
00266 $currentClassIdentifier = $currentClassIdentifier . '_1';
00267 }
00268 else
00269 $unique = true;
00270
00271 unset( $classList );
00272 }
00273
00274 $classIdentifier = $currentClassIdentifier;
00275
00276
00277 $class = eZContentClass::create( $userID,
00278 array( 'version' => 0,
00279 'serialized_name_list' => $classNameList->serializeNames(),
00280 'create_lang_if_not_exist' => true,
00281 'identifier' => $classIdentifier,
00282 'remote_id' => $classRemoteID,
00283 'contentobject_name' => $classObjectNamePattern,
00284 'is_container' => $classIsContainer,
00285 'created' => $classCreated,
00286 'modified' => $classModified ) );
00287 $class->store();
00288
00289 $classID = $class->attribute( 'id' );
00290
00291 if ( !isset( $installData['classid_list'] ) )
00292 $installData['classid_list'] = array();
00293 if ( !isset( $installData['classid_map'] ) )
00294 $installData['classid_map'] = array();
00295 $installData['classid_list'][] = $class->attribute( 'id' );
00296 $installData['classid_map'][$classID] = $class->attribute( 'id' );
00297
00298
00299 $classAttributeList = $classAttributesNode->children();
00300 foreach ( $classAttributeList as $classAttributeNode )
00301 {
00302 $isNotSupported = strtolower( $classAttributeNode->attributeValue( 'unsupported' ) ) == 'true';
00303 if ( $isNotSupported )
00304 continue;
00305
00306 $attributeDatatype = $classAttributeNode->attributeValue( 'datatype' );
00307 $attributeIsRequired = strtolower( $classAttributeNode->attributeValue( 'required' ) ) == 'true';
00308 $attributeIsSearchable = strtolower( $classAttributeNode->attributeValue( 'searchable' ) ) == 'true';
00309 $attributeIsInformationCollector = strtolower( $classAttributeNode->attributeValue( 'information-collector' ) ) == 'true';
00310 $attributeIsTranslatable = strtolower( $classAttributeNode->attributeValue( 'translatable' ) ) == 'true';
00311 $attributeSerializedNameList = new eZContentClassAttributeNameList( $classAttributeNode->elementTextContentByName( 'serialized-name-list' ) );
00312 if ( $attributeSerializedNameList->isEmpty() )
00313 $attributeSerializedNameList->initFromString( $classAttributeNode->elementTextContentByName( 'name' ) );
00314 $attributeSerializedNameList->validate();
00315 $attributeIdentifier = $classAttributeNode->elementTextContentByName( 'identifier' );
00316 $attributePlacement = $classAttributeNode->elementTextContentByName( 'placement' );
00317 $attributeDatatypeParameterNode = $classAttributeNode->elementByName( 'datatype-parameters' );
00318
00319 $classAttribute =& $class->fetchAttributeByIdentifier( $attributeIdentifier );
00320 if ( !$classAttribute )
00321 {
00322 $classAttribute = eZContentClassAttribute::create( $class->attribute( 'id' ),
00323 $attributeDatatype,
00324 array( 'version' => 0,
00325 'identifier' => $attributeIdentifier,
00326 'serialized_name_list' => $attributeSerializedNameList->serializeNames(),
00327 'is_required' => $attributeIsRequired,
00328 'is_searchable' => $attributeIsSearchable,
00329 'is_information_collector' => $attributeIsInformationCollector,
00330 'can_translate' => $attributeIsTranslatable,
00331 'placement' => $attributePlacement ) );
00332
00333 $dataType = $classAttribute->dataType();
00334 $classAttribute->store();
00335 $dataType->unserializeContentClassAttribute( $classAttribute, $classAttributeNode, $attributeDatatypeParameterNode );
00336 $classAttribute->sync();
00337 }
00338 }
00339
00340
00341 $classGroupsList = $classGroupsNode->children();
00342 foreach ( $classGroupsList as $classGroupNode )
00343 {
00344 $classGroupName = $classGroupNode->attributeValue( 'name' );
00345 $classGroup = eZContentClassGroup::fetchByName( $classGroupName );
00346 if ( !$classGroup )
00347 {
00348 $classGroup = eZContentClassGroup::create();
00349 $classGroup->setAttribute( 'name', $classGroupName );
00350 $classGroup->store();
00351 }
00352 $classGroup->appendClass( $class );
00353 }
00354 return true;
00355 }
00356
00357
00358
00359
00360 function add( $packageType, &$package, &$cli, $parameters )
00361 {
00362 foreach ( $parameters['class-list'] as $classItem )
00363 {
00364 $classID = $classItem['id'];
00365 $classIdentifier = $classItem['identifier'];
00366 $classValue = $classItem['value'];
00367 $cli->notice( "Adding class $classValue to package" );
00368 $this->addClass( $package, $classID, $classIdentifier );
00369 }
00370 }
00371
00372
00373
00374
00375
00376
00377 function addClass( &$package, $classID, $classIdentifier = false )
00378 {
00379 $class = false;
00380 if ( is_numeric( $classID ) )
00381 $class = eZContentClass::fetch( $classID );
00382 if ( !$class )
00383 return;
00384 $classNode =& eZContentClassPackageHandler::classDOMTree( $class );
00385 if ( !$classNode )
00386 return;
00387 if ( !$classIdentifier )
00388 $classIdentifier = $class->attribute( 'identifier' );
00389 $package->appendInstall( 'ezcontentclass', false, false, true,
00390 'class-' . $classIdentifier, 'ezcontentclass',
00391 array( 'content' => $classNode ) );
00392 $package->appendProvides( 'ezcontentclass', 'contentclass', $class->attribute( 'identifier' ) );
00393 $package->appendInstall( 'ezcontentclass', false, false, false,
00394 'class-' . $classIdentifier, 'ezcontentclass',
00395 array( 'content' => false ) );
00396 }
00397
00398
00399
00400
00401 function handleAddParameters( $packageType, &$package, &$cli, $arguments )
00402 {
00403 return $this->handleParameters( $packageType, $package, $cli, 'add', $arguments );
00404 }
00405
00406
00407
00408
00409 function handleParameters( $packageType, &$package, &$cli, $type, $arguments )
00410 {
00411 $classList = false;
00412 foreach ( $arguments as $argument )
00413 {
00414 if ( $argument[0] == '-' )
00415 {
00416 if ( strlen( $argument ) > 1 and
00417 $argument[1] == '-' )
00418 {
00419 }
00420 else
00421 {
00422 }
00423 }
00424 else
00425 {
00426 if ( $classList === false )
00427 {
00428 $classList = array();
00429 $classArray = explode( ',', $argument );
00430 $error = false;
00431 foreach ( $classArray as $classID )
00432 {
00433 if ( in_array( $classID, $classList ) )
00434 {
00435 $cli->notice( "Content class $classID already in list" );
00436 continue;
00437 }
00438 if ( is_numeric( $classID ) )
00439 {
00440 if ( !eZContentClass::exists( $classID, 0, false, false ) )
00441 {
00442 $cli->error( "Content class with ID $classID does not exist" );
00443 $error = true;
00444 }
00445 else
00446 {
00447 unset( $class );
00448 $class = eZContentClass::fetch( $classID );
00449 $classList[] = array( 'id' => $classID,
00450 'identifier' => $class->attribute( 'identifier' ),
00451 'value' => $classID );
00452 }
00453 }
00454 else
00455 {
00456 $realClassID = eZContentClass::exists( $classID, 0, false, true );
00457 if ( !$realClassID )
00458 {
00459 $cli->error( "Content class with identifier $classID does not exist" );
00460 $error = true;
00461 }
00462 else
00463 {
00464 unset( $class );
00465 $class = eZContentClass::fetch( $realClassID );
00466 $classList[] = array( 'id' => $realClassID,
00467 'identifier' => $class->attribute( 'identifier' ),
00468 'value' => $classID );
00469 }
00470 }
00471 }
00472 if ( $error )
00473 return false;
00474 }
00475 }
00476 }
00477 if ( $classList === false )
00478 {
00479 $cli->error( "No class ids chosen" );
00480 return false;
00481 }
00482 return array( 'class-list' => $classList );
00483 }
00484
00485
00486
00487
00488
00489 function &classDOMTree( &$class )
00490 {
00491 if ( !$class )
00492 {
00493 $retValue = false;
00494 return $retValue;
00495 }
00496
00497 $classNode = eZDOMDocument::createElementNode( 'content-class' );
00498 $classNode->appendChild( eZDOMDocument::createElementTextNode( 'serialized-name-list',
00499 $class->attribute( 'serialized_name_list' ) ) );
00500 $classNode->appendChild( eZDOMDocument::createElementTextNode( 'identifier',
00501 $class->attribute( 'identifier' ) ) );
00502 $classNode->appendChild( eZDOMDocument::createElementTextNode( 'remote-id',
00503 $class->attribute( 'remote_id' ) ) );
00504 $classNode->appendChild( eZDOMDocument::createElementTextNode( 'object-name-pattern',
00505 $class->attribute( 'contentobject_name' ) ) );
00506 $classNode->appendAttribute( eZDOMDocument::createAttributeNode( 'is-container',
00507 $class->attribute( 'is_container' ) ? 'true' : 'false' ) );
00508
00509
00510 $remoteNode = eZDOMDocument::createElementNode( 'remote' );
00511 $classNode->appendChild( $remoteNode );
00512
00513 $ini =& eZINI::instance();
00514 $siteName = $ini->variable( 'SiteSettings', 'SiteURL' );
00515
00516 $classURL = 'http://' . $siteName . '/class/view/' . $class->attribute( 'id' );
00517 $siteURL = 'http://' . $siteName . '/';
00518
00519 $remoteNode->appendChild( eZDOMDocument::createElementTextNode( 'site-url',
00520 $siteURL ) );
00521 $remoteNode->appendChild( eZDOMDocument::createElementTextNode( 'url',
00522 $classURL ) );
00523
00524 $classGroupsNode = eZDOMDocument::createElementNode( 'groups' );
00525
00526 $classGroupList = eZContentClassClassGroup::fetchGroupList( $class->attribute( 'id' ),
00527 $class->attribute( 'version' ) );
00528 foreach ( array_keys( $classGroupList ) as $classGroupKey )
00529 {
00530 $classGroupLink =& $classGroupList[$classGroupKey];
00531 $classGroup = eZContentClassGroup::fetch( $classGroupLink->attribute( 'group_id' ) );
00532 if ( $classGroup )
00533 $classGroupsNode->appendChild( eZDOMDocument::createElementNode( 'group',
00534 array( 'id' => $classGroup->attribute( 'id' ),
00535 'name' => $classGroup->attribute( 'name' ) ) ) );
00536 }
00537 $remoteNode->appendChild( $classGroupsNode );
00538
00539 $remoteNode->appendChild( eZDOMDocument::createElementTextNode( 'id',
00540 $class->attribute( 'id' ) ) );
00541 $remoteNode->appendChild( eZDOMDocument::createElementTextNode( 'created',
00542 $class->attribute( 'created' ) ) );
00543 $remoteNode->appendChild( eZDOMDocument::createElementTextNode( 'modified',
00544 $class->attribute( 'modified' ) ) );
00545
00546 $creatorNode = eZDOMDocument::createElementNode( 'creator' );
00547 $remoteNode->appendChild( $creatorNode );
00548 $creatorNode->appendChild( eZDOMDocument::createElementTextNode( 'user-id',
00549 $class->attribute( 'creator_id' ) ) );
00550 $creator =& $class->attribute( 'creator' );
00551 if ( $creator )
00552 $creatorNode->appendChild( eZDOMDocument::createElementTextNode( 'user-login',
00553 $creator->attribute( 'login' ) ) );
00554
00555 $modifierNode = eZDOMDocument::createElementNode( 'modifier' );
00556 $remoteNode->appendChild( $modifierNode );
00557 $modifierNode->appendChild( eZDOMDocument::createElementTextNode( 'user-id',
00558 $class->attribute( 'modifier_id' ) ) );
00559 $modifier =& $class->attribute( 'modifier' );
00560 if ( $modifier )
00561 $modifierNode->appendChild( eZDOMDocument::createElementTextNode( 'user-login',
00562 $modifier->attribute( 'login' ) ) );
00563
00564
00565 $attributesNode = eZDOMDocument::createElementNode( 'attributes' );
00566 $attributesNode->appendAttribute( eZDOMDocument::createAttributeNode( 'ezcontentclass-attribute',
00567 'http://ezpublish/contentclassattribute',
00568 'xmlns' ) );
00569 $classNode->appendChild( $attributesNode );
00570
00571 $attributes =& $class->fetchAttributes();
00572 for ( $i = 0; $i < count( $attributes ); ++$i )
00573 {
00574 $attribute =& $attributes[$i];
00575 unset( $attributeNode );
00576 $attributeNode = eZDOMDocument::createElementNode( 'attribute',
00577 array( 'datatype' => $attribute->attribute( 'data_type_string' ),
00578 'required' => $attribute->attribute( 'is_required' ) ? 'true' : 'false',
00579 'searchable' => $attribute->attribute( 'is_searchable' ) ? 'true' : 'false',
00580 'information-collector' => $attribute->attribute( 'is_information_collector' ) ? 'true' : 'false',
00581 'translatable' => $attribute->attribute( 'can_translate' ) ? 'true' : 'false' ) );
00582 unset( $attributeRemoteNode );
00583 $attributeRemoteNode = eZDOMDocument::createElementNode( 'remote' );
00584 $attributeNode->appendChild( $attributeRemoteNode );
00585 $attributeRemoteNode->appendChild( eZDOMDocument::createElementTextNode( 'id',
00586 $attribute->attribute( 'id' ) ) );
00587 $attributeNode->appendChild( eZDOMDocument::createElementTextNode( 'serialized-name-list',
00588 $attribute->attribute( 'serialized_name_list' ) ) );
00589 $attributeNode->appendChild( eZDOMDocument::createElementTextNode( 'identifier',
00590 $attribute->attribute( 'identifier' ) ) );
00591 $attributeNode->appendChild( eZDOMDocument::createElementTextNode( 'placement',
00592 $attribute->attribute( 'placement' ) ) );
00593 unset( $attributeParametersNode );
00594 $attributeParametersNode = eZDOMDocument::createElementNode( 'datatype-parameters' );
00595 $attributeNode->appendChild( $attributeParametersNode );
00596
00597 $dataType = $attribute->dataType();
00598 if ( is_object( $dataType ) )
00599 {
00600 $dataType->serializeContentClassAttribute( $attribute, $attributeNode, $attributeParametersNode );
00601 }
00602
00603 $attributesNode->appendChild( $attributeNode );
00604 }
00605 return $classNode;
00606 }
00607
00608 function contentclassDirectory()
00609 {
00610 return 'ezcontentclass';
00611 }
00612
00613
00614
00615
00616
00617
00618
00619
00620
00621
00622
00623
00624
00625
00626
00627
00628
00629
00630
00631
00632
00633
00634
00635 }
00636
00637 ?>