Jump to content
LemmeCheck.Info

Creating A Sitemap In Tgpx


Robert
 Share

Recommended Posts

1. Create a sitemap of all of your categories:

{php} echo '<?xml version="1.0" encoding="UTF-8"?>'; {/php}
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
{categories var=$categories order=name}
{foreach var=$category from=$categories counter=$counter}
<url>
<loc>http://www.YOURDOMAIN.com/{$category.name|htmlspecialchars|strtolower|treplace_special::''}/</loc>
</url>
{/foreach}

2. Create a sitemap of all of your galleries (if you host them locally and have them added to your TGPX database):

{define name=globaldupes value=true}
{define name=pagedupes value=false}

{* PULL THE SUBMITTED GALLERIES FROM THE DATABASE *}
{galleries
var=$galleries
type=any
format=any
getnew=true
allowused=true
preview=any
amount=10000
category=MIXED
sponsor=any
order=date_approved DESC
reorder=date_approved DESC}

{* DISPLAY ALL OF THE GALLERIES In SITEMAP FORMAT *}
{php} echo '<?xml version="1.0" encoding="UTF-8"?>'; {/php}
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
{foreach from=$galleries var=$gallery counter=$counter}
<url>
<loc>{$gallery.gallery_url|htmlspecialchars}</loc>
</url>
{/foreach}
</urlset>
Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use, Privacy Policy, and We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. policies