Nesne yönelimli arayüz ile çalışma

Bu örnekte XMLWriter'ın nesne yönelimli arayüzü ile nasıl çalışılacağı gösterilmiştir.

Örnek 1 - Nesne yönelimli arayüz ile çalışma

<?php

$xw
= new XMLWriter();
$xw->openMemory();
$xw->startDocument("1.0");
$xw->startElement("kitap");
$xw->text("örnek");
$xw->endElement();
$xw->endDocument();
echo
$xw->outputMemory();

Yukarıdaki örneğin çıktısı:

<?xml version="1.0"?>
<kitap>örnek</kitap>

add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top