• 02-09-2019, 23:22:28
    #10
    Dosyanızı utf-8 without BOM olarak kaydedin.
  • 02-09-2019, 23:45:53
    #11
    Developer
    Olmayan tablodan veri çekmeye çalışmış
  • 03-09-2019, 00:13:17
    #12
    <?php
    $servername = "localhost";
    $username = "xx";
    $password = "xx";
    $dbname = "xx";
    $conn = new mysqli($servername, $username, $password, $dbname);
    $sql = "SELECT * FROM aa_link";
    $result = $conn->query($sql); ?> 
    
    <?php header('Content-type: application/xml; ',true); ?> 
    
    <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9 http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd"> 
    
    <?php while($row = $result->fetch_assoc()) { ?> 
    
    <url> 
    
    <loc><![CDATA[<?php echo 'https://aa.com'.$row["aa_link"]; ?>]]></loc>
    
    <changefreq>weekly</changefreq> 
    <priority>0.7</priority> 
    
    </url> 
    
    <?php } ?> 
    
    </urlset>