Ejemplo n.º 1
0
 /**
  * Remove a record from the name map
  *
  * @param \LibDNS\Records\Record $record The record to remove
  */
 private function removeFromNameMap(Record $record)
 {
     if (!empty($this->nameMap[$name = (string) $record->getName()])) {
         foreach ($this->nameMap[$name] as $key => $item) {
             if ($item === $record) {
                 array_splice($this->nameMap[$name], $key, 1);
                 break;
             }
         }
     }
     if (empty($this->nameMap[$name])) {
         unset($this->nameMap[$name]);
     }
 }
Ejemplo n.º 2
0
	<p>
		<label for="title">Title:</label>
		<input type="text" name="title" id="title">
	</p>
	<p>
		<label for="description">Description:</label>
		<textarea name="description" id="description"></textarea>
	</p>
	<p>
		<input type="submit" name="send" id="send" value="Send">
	</p>
</form>


<pre>
	
	<?php 
require_once 'Record.php';
if (isset($_POST['name']) && $_POST['name'] != '') {
    $myRecord = new Record();
    $myRecord->setName($_POST['name']);
    echo "The name of this record  is: ";
    $myRecord->getName();
} else {
    echo "Please enter the name of your record!";
}
?>
</pre>

</body>
</html>