Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

ÍÂѪÁË,Ìá¸öPHPдXMLµÄÎÊÌâ - PHP / ¿ªÔ´×ÊÔ´

´úÂë:
<?php
$im=$_POST['upPicName'];
$it=$_POST['upPicTitle'];
$pa=$_POST['upPicAlbum'];
$pt=$_POST['upPicThumb'];

//echo $im.$it.$pa.$pt;

$doc = new DOMDocument();
$doc ->formatOutput = true;
$doc->load('pic.xml');

$project=$doc->documentElement->getElementsByTagName('medias');

//$root = $doc->createElement('media');
//$doc->appendChild($root);

/**Ìí¼ÓͼƬµÄÃû×Ö
$root_im = $doc->createAttribute('imgname');
$root->appendChild($root_im);

$root_im_text=$doc->createTextNode($im); 
$root_im->appendChild($root_im_text);
//½áÊø

//Ìí¼Ó±êÌâ
$root_it = $doc -> createAttribute('title');
$root->appendChild($root_it);

$root_it_text=$doc->createTextNode($it);
$root_it->appendChild($root_it_text);
//½áÊø

//Ìí¼Óר¼­Ãû³Æ
$root_pa=$doc->createAttribute('section');
$root->appendChild($root_pa);

$root_pa_text=$doc->createTextNode($pa);
$root_pa->appendChild($root_pa_text);
//½áÊø

//ÊÇ·ñΪ±êÌâ
$root_pt=$doc->createAttribute('thumb');
$root->appendChild($root_pt);

$root_pt_text=$doc->createTextNode($pt[0]);
$root_pt->appendChild($root_pt_text);
**///½áÊø

$doc->saveXML('pic.xml');
?>

XML:
<?xml version="1.0" encoding="utf


Ïà¹ØÎÊ´ð£º

ÀûÓÃC#±àдtxtת»¯µ½xmlµÄ³ÌÐò

txt ºÍXML ¸ñʽÏàÓ¦
²»½èÖúDataSet
µ¼Èë¶ÁÈ¡TXTÎļþ
È»ºóÖ±½ÓдÈëXML(ͬһÎļþ,²»Í¬Êý¾Ý,µÝÔöÔ­Êý¾ÝûÓб»¸²¸ÇÇé¿öÏÂÔö¼ÓÊý¾Ý.)
½Ì¸öÒªµã»ò×îºÃÊÇÓиö´úÂëÌáʾµÄ
¹ý·ºÃºº °ï¸öæÈö^^
²»»á£¬°ïÂ¥Ö÷ ......

ÕÒ¹¤×÷ºÍ¶Ô¸ÕѧPHPµÄÅóÓѵÄÖÒ¸æ - PHP / ¿ªÔ´×ÊÔ´

Ä¿Ç°ÔÚÎ人ÕÒ¹¤×÷  
·¢Ïִ󲿷ֹ«Ë¾ÎÞÍâºõÁ½ÖÖ
Ò»ÖÖÊǸãÍâ°üµÄ ÒªÓÃzend,cakephpµÈÍâ¹ú¿ò¼Ü
»¹ÒªÊìϤÍâ¹ú¿ªÔ´ÏµÍ³
Ò»ÖÖ¹úÄÚµÄ ÎÞÍâºõ dedecms ecshop shopexÕ⼸ÖÖ¸ÄÕ¾µã ÓеĹ«Ë¾ÉõÖÁÄÃһЩ¸üСµÄϵͳ¸ ......

PHPÈçºÎÉèÖÃÒ³Ã滺´æ1ÐÇÆÚ - PHP / »ù´¡±à³Ì

ÈçÌ⣬Ôõôд¸öheadÍ·²¿ ÈÃÒ³Ã滺´æ1ÐÇÆÚ¡£
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
Äã°ÑÀïÃæµÄʱ¼ä£¬¸Ä³Éµ±Ç°Ê±¼ä¼ÓÉÏÒ»¸öÐÇÆÚ
¼ÇµÃҪת»»³Égmtʱ¼ä

ÎÒÕâÑùдµÄ ²»ÖªµÀÐв»ÐС£
Ò»¸öÐ ......

ÓÃphp±¸·ÝÊý¾Ý¿â³É¹¦£¬»¹Ô­Ê±³ö´í - PHP / ¿ªÔ´×ÊÔ´

ÊÇÓñðÈËдµÄÀà×öµÄ£¬»¹Ô­Ê±ÌáʾYou have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'INSERT INTO admin(seq,passwd,type,n ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ