2011-10-15 00:49:26 +02:00
|
|
|
<?php
|
2013-05-18 16:53:58 +02:00
|
|
|
require __DIR__ .'/../vendor/autoload.php';
|
2011-10-25 22:49:57 +02:00
|
|
|
|
2011-10-30 13:26:51 +01:00
|
|
|
$faker = Faker\Factory::create();
|
|
|
|
$faker->seed(5);
|
2014-01-28 04:04:38 -05:00
|
|
|
|
|
|
|
echo '<?xml version="1.0" encoding="UTF-8"?>';
|
2011-10-15 00:49:26 +02:00
|
|
|
?>
|
|
|
|
<contacts>
|
|
|
|
<?php for ($i=0; $i < 10; $i++): ?>
|
2011-10-30 13:26:51 +01:00
|
|
|
<contact firstName="<?php echo $faker->firstName ?>" lastName="<?php echo $faker->lastName ?>" email="<?php echo $faker->email ?>"/>
|
|
|
|
<phone number="<?php echo $faker->phoneNumber ?>"/>
|
|
|
|
<?php if ($faker->boolean(25)): ?>
|
|
|
|
<birth date="<?php echo $faker->dateTimeThisCentury->format('Y-m-d') ?>" place="<?php echo $faker->city ?>"/>
|
2011-10-15 00:49:26 +02:00
|
|
|
<?php endif; ?>
|
|
|
|
<address>
|
2011-10-30 13:26:51 +01:00
|
|
|
<street><?php echo $faker->streetAddress ?></street>
|
|
|
|
<city><?php echo $faker->city ?></city>
|
|
|
|
<postcode><?php echo $faker->postcode ?></postcode>
|
|
|
|
<state><?php echo $faker->state ?></state>
|
2011-10-15 00:49:26 +02:00
|
|
|
</address>
|
2011-10-30 13:26:51 +01:00
|
|
|
<company name="<?php echo $faker->company ?>" catchPhrase="<?php echo $faker->catchPhrase ?>">
|
|
|
|
<?php if ($faker->boolean(33)): ?>
|
|
|
|
<offer><?php echo $faker->bs ?></offer>
|
2011-10-15 00:49:26 +02:00
|
|
|
<?php endif; ?>
|
2011-10-30 13:26:51 +01:00
|
|
|
<?php if ($faker->boolean(33)): ?>
|
|
|
|
<director name="<?php echo $faker->name ?>" />
|
2011-10-15 00:49:26 +02:00
|
|
|
<?php endif; ?>
|
|
|
|
</company>
|
2011-10-30 13:26:51 +01:00
|
|
|
<?php if ($faker->boolean(15)): ?>
|
2011-10-15 00:49:26 +02:00
|
|
|
<details>
|
2011-10-15 13:21:13 +02:00
|
|
|
<![CDATA[
|
2012-11-10 12:31:37 +01:00
|
|
|
<?php echo $faker->text(400) ?>
|
2011-10-15 13:21:13 +02:00
|
|
|
]]>
|
2011-10-15 00:49:26 +02:00
|
|
|
</details>
|
|
|
|
<?php endif; ?>
|
|
|
|
</contact>
|
|
|
|
<?php endfor; ?>
|
2012-12-10 16:03:57 +01:00
|
|
|
</contacts>
|