Register for your free account! | Forgot your password?

You last visited: Today at 07:35

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[Release]Simple SQL TO XML Converter

Discussion on [Release]Simple SQL TO XML Converter within the Metin2 PServer Guides & Strategies forum part of the Metin2 Private Server category.

Reply
 
Old   #1
 
TraxWall's Avatar
 
elite*gold: 0
Join Date: Oct 2010
Posts: 178
Received Thanks: 86
Smile [Release]Simple SQL TO XML Converter

Hello
Here is a simple conversion that I item_proto

Code

PHP Code:
<?php
    
# MySQL host
    
$host 'SQL Host';
    
# MySQL port
    
$port '3306';
    
# MySQL User
    
$user 'SQL User';
    
# MySQL Password
    
$password 'SQL PW';
    
$adatbazis_kapcs mysql_connect($host.":".$port$user$password);    

?>


<?php


$sql 
"SELECT * FROM player.item_proto";

$result mysql_query($sql);

while (
$row mysql_fetch_assoc($result)) {




?>

    
<textarea rows="4" cols="130"><Item vnum="<?php echo $row["vnum"]; ?>" hashName="<?php echo $row["name"]; ?>" name="<?php echo $row["locale_name"]; ?>" type="<?php echo $row["type"]; ?>" subtype="<?php echo $row["subtype"]; ?>" weight="<?php echo $row["weight"]; ?>" size="<?php echo $row["size"]; ?>" antiflag="<?php echo $row["antiflag"]; ?>" flag="<?php echo $row["flag"]; ?>" wearflag="<?php echo $row["wearflag"]; ?>" immuneflag="<?php echo $row["immuneflag"]; ?>" gold="<?php echo $row["gold"]; ?>" buy_price="<?php echo $row["shop_buy_price"]; ?>" limittype0="<?php echo $row["limittype0"]; ?>" limitvalue0="<?php echo $row["limitvalue0"]; ?>" limittype1="<?php echo $row["limittype1"]; ?>" limitvalue1="<?php echo $row["limitvalue1"]; ?>" applytype0="<?php echo $row["applytype0"]; ?>" applyvalue0="<?php echo $row["applyvalue0"]; ?>" applytype1="<?php echo $row["applytype1"]; ?>" applyvalue1="<?php echo $row["applyvalue1"]; ?>" applytype2="<?php echo $row["applytype2"]; ?>" applyvalue2="<?php echo $row["applyvalue2"]; ?>" value0="<?php echo $row["value0"]; ?>" value1="<?php echo $row["value1"]; ?>" value2="<?php echo $row["value2"]; ?>" value3="<?php echo $row["value3"]; ?>" value4="<?php echo $row["value4"]; ?>" value5="<?php echo $row["value5"]; ?>" socket0="<?php echo $row["socket0"]; ?>" socket1="<?php echo $row["socket1"]; ?>" socket2="<?php echo $row["socket2"]; ?>" socket3="<?php echo $row["socket3"]; ?>" socket4="<?php echo $row["socket4"]; ?>" socket5="<?php echo $row["socket5"]; ?>" refine_vnum="<?php echo $row["refine_vnum"]; ?>" refine_set="<?php echo $row["refine_set"]; ?>" magic_pct="<?php echo $row["magic_pct"]; ?>" specular="<?php echo $row["specular"]; ?>" socket_pct="<?php echo $row["socket_pct"]; ?>" /></textarea><br>
<?php
}
?>
TraxWall is offline  
Thanks
4 Users
Old 10/05/2013, 13:16   #2
 
lollozzo's Avatar
 
elite*gold: 0
Join Date: Sep 2011
Posts: 76
Received Thanks: 48
how it works? i need to create a file .bat? visual basic? what i need to do?
lollozzo is offline  
Old 10/05/2013, 13:54   #3
 
TraxWall's Avatar
 
elite*gold: 0
Join Date: Oct 2010
Posts: 178
Received Thanks: 86
This is a PHP file: D
Web Server to be
recommended XAMPP
TraxWall is offline  
Thanks
1 User
Old 10/05/2013, 13:56   #4
 
elite*gold: 260
Join Date: Jan 2013
Posts: 178
Received Thanks: 104
you need a webserver and edit your MySQL details to make it work.

Thank you for your effort
Metin2 Team is offline  
Old 10/05/2013, 13:58   #5
 
lollozzo's Avatar
 
elite*gold: 0
Join Date: Sep 2011
Posts: 76
Received Thanks: 48
Thank you man

It works 100%, thanks <3
lollozzo is offline  
Old 10/05/2013, 15:20   #6
 
elite*gold: 2
Join Date: Nov 2008
Posts: 628
Received Thanks: 1,633
I already have a tool like this, but thanks for sharing will beusefull for others
xSanii is offline  
Old 10/05/2013, 17:08   #7
 
Akzyra's Avatar
 
elite*gold: 0
Join Date: Sep 2012
Posts: 124
Received Thanks: 80
Use it like that, then everything is in one fiel and easier to copy/paste.
Every line is one line in the mysql table.
PHP error are turned of -> You copy no error in your xml

Akzyra is offline  
Thanks
1 User
Old 10/05/2013, 20:02   #8
 
TraxWall's Avatar
 
elite*gold: 0
Join Date: Oct 2010
Posts: 178
Received Thanks: 86
Quote:
Originally Posted by Akzyra View Post
Use it like that, then everything is in one fiel and easier to copy/paste.
Every line is one line in the mysql table.
PHP error are turned of -> You copy no error in your xml

Thank you.
Anyway, I base my webserver was turned off PHP error
TraxWall is offline  
Reply


Similar Threads Similar Threads
[Release] SQL to XML Converter (Hen! CMS)
08/31/2013 - Metin2 PServer Guides & Strategies - 5 Replies
Hi epvp :pimp: Item Proto Converter Code: <h2>ItemProto.sql to ItemProto.xml Converter By DexterSK</h2> <?php if($_SESSION>=$adminRights) { if(isset($_POST))
[Release].php SQL zu XML Converter
06/14/2012 - Metin2 PServer Guides & Strategies - 8 Replies
Hey ho, ich hab mir mal die Mühe gemacht *hust* und habe einen .php Script erstellt, mit welchem man Items & Monster ( item_proto & mob_proto ) aus der Datenbank in das XML Format umwandelt. Wozu man das braucht? Wenn ihr "locale_name" habt:
[Release]DDS-Converter
01/20/2011 - Metin2 PServer Guides & Strategies - 22 Replies
Hey ich habe heute mal mein Desktop aufgeräumt :P und da fand ich plötzlich eine komische Datei. Aufeinmal stellte sich raus das es ein DDS-Converter war. Er wandelt DDS Dateien in jpg und png dateien um. Da das für manche Client´s nützlich ist dachte ich ich stell es mal hier rein. Virustotal Screen http://img3.fotos-hochladen.net/uploads/virrustot al0t16k9zq.png Screen vom Programm http://img3.fotos-hochladen.net/uploads/programmn gw8demb.png MfG Fun-Zocker
[RELEASE] DDS converter
08/18/2009 - EO PServer Guides & Releases - 9 Replies
Well, because this is a tool, i post it here and not on another section :bandit: People were complaining they cant open or edit a dds file.. This tool, can convert the dds file to jpg,png,bmp,tga and it can convert "to" dds :handsdown:
[Share] Simple little Hex converter
09/25/2008 - RFO Hacks, Bots, Cheats, Exploits & Guides - 2 Replies
Simple little tool to figure hex, binary, and decimal conversions. just type in what # you wanna convert and hit <enter>



All times are GMT +2. The time now is 07:35.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.