Montego Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic
Author Message
montego
Site Admin/Owner
Site Admin/Owner



Joined: Feb 12, 2005
Posts: 1294

PostPosted: Tue Apr 14, 2009 7:58 pm Reply with quote

Can't vouch for that validation link, but when I log into Google I see that my sitemap is showing as valid...

That isn't my Google site map link. Mine is:

http://montegoscripts.com/modules.php?name=Sitemap&op=Google

That one is showing as valid in Google.

_________________
“To err is human, but when the eraser wears out ahead of the pencil, you’re overdoing it.”
-- Josh Jenkins 
View user's profile Send private message Visit poster's website
Testy1
Newbie
Newbie



Joined: Jan 06, 2009
Posts: 17

PostPosted: Mon Apr 20, 2009 10:58 pm Reply with quote

I had let this go for a while but got an idea this morning.Any thoughts on this approach........

Original Code:
Code:

if ( $xml ) {
                    //XML-Output
                    @f write( $var, "  <url><loc>$nukeurl/modules.php?name=Content&amp;pa=list_pages_categories&amp;cid=$cid20</loc><changefreq>daily</changefreq></url>\n" );
                }


Replacement Code:
Code:

if ( $xml ) {
          global $tnsl_bUseShortLinks, $tnsl_bAutoTapBlocks, $tnsl_bAutoTapLinks, $tnsl_bDebugShortLinks, $tnsl_sGTFilePath;
          if ( defined('TNSL_USE_SHORTLINKS') ) {

            $string = 'modules.php?name=Content&amp;pa=list_pages_categories&amp;cid=';
            $patterns[0] = '/modules.php\?name=Content&amp;pa=list_pages_categories&amp;cid=/';
            $replacements[0] = 'content-cat-';
            $writeto = preg_replace( $patterns, $replacements, $string );

            @f write( $var, "  <url><loc>$nukeurl/$writeto$cid20.html</loc><changefreq>daily</changefreq></url>\n" );

          } else {

            @f write( $var, "  <url><loc>$nukeurl/modules.php?name=Content&amp;pa=list_pages_categories&amp;cid=$cid20</loc><changefreq>daily</changefreq></url>\n" );

          }
        }
 
View user's profile Send private message
montego
Site Admin/Owner
Site Admin/Owner



Joined: Feb 12, 2005
Posts: 1294

PostPosted: Tue Apr 21, 2009 8:52 am Reply with quote

I don't see how this really helps you to be quite honest. You might as well do the if (defined()) and then just hard code the links. Its pretty much what you are doing anyways with that code, but why add more processing time to do the preg_replace?

_________________
“To err is human, but when the eraser wears out ahead of the pencil, you’re overdoing it.”
-- Josh Jenkins 
View user's profile Send private message Visit poster's website
Testy1
Newbie
Newbie



Joined: Jan 06, 2009
Posts: 17

PostPosted: Tue Apr 21, 2009 6:06 pm Reply with quote

do you mean hard code as in.....

Code:

@f write( $var, "  <url><loc>$nukeurl/content-cat-$cid20.html</loc>


mmmm makes more sense, Ill try that.But I sill cant make up my mind which sitemap to use lol, do you have and code for that Sad
 
View user's profile Send private message
montego
Site Admin/Owner
Site Admin/Owner



Joined: Feb 12, 2005
Posts: 1294

PostPosted: Tue Apr 21, 2009 8:02 pm Reply with quote

Yes, I believe nukeSEO already is ShortLinks enabled. I have all of the nukeSEO core modules taps done. If you create additional content classes to add to the sitemap, you'll have plenty of samples to work from to also "tap" them.

_________________
“To err is human, but when the eraser wears out ahead of the pencil, you’re overdoing it.”
-- Josh Jenkins 
View user's profile Send private message Visit poster's website
Display posts from previous:       
Post new topic   Reply to topic

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 4 Hours
 
Forums ©
linear-bunchlinear-bunch