Advertisement:

Author Topic: Sitemap  (Read 585772 times)

Offline nitins60

  • Sr. Member
  • ****
  • Posts: 838
  • Gender: Male
  • LoVE mAKeS lIFe bEauTIfUL
    • Simple Mobile Forum - SMF
Re: SMF Sitemap
« Reply #20 on: May 22, 2007, 09:39:49 AM »
Nothing wrong. Smf generates urls like http://forum.com/index.php/etc.html and index.php? Nothing wrong


Offline SlammedDime

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,280
  • School of Air Ride
    • matt.zuba on Facebook
    • @mattzuba on Twitter
    • ZubaFitness
Re: SMF Sitemap
« Reply #21 on: May 22, 2007, 09:54:53 AM »
I've got a problem. The XML is generating URLs like http://www.example.com/index.php/board,15.0.html instead of index.php?board=15.0 or ?topic=350.0

The viewer sitemap pages work fine.

Any suggestions before I start digging in to the code to hack a fix?
There shouldn't be a fix needed... I need to see a URL to see whats going on on your site.  If the XML links are being formatted like that, then you have queryless urls enabled on your board.  If you do not have this enabled, or have no clue what it is, I need to see a URL.
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...
                     

Offline Nutter

  • Semi-Newbie
  • *
  • Posts: 17
    • Forums, Blogs, Wikis
Re: SMF Sitemap
« Reply #22 on: May 22, 2007, 10:17:27 AM »
I assume that's "Search engine friendly URLs" which I have unchecked.  Shouldn't the URLs in the XML file be the same as the normal sitemap?

Sitemap is http://forums.photoartsforum.com/index.php?action=sitemap [nofollow] , xml is http://forums.photoartsforum.com/index.php?action=sitemap;xml [nofollow]
- Ryan [nofollow]

Offline SlammedDime

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,280
  • School of Air Ride
    • matt.zuba on Facebook
    • @mattzuba on Twitter
    • ZubaFitness
Re: SMF Sitemap
« Reply #23 on: May 22, 2007, 03:15:58 PM »
I assume that's "Search engine friendly URLs" which I have unchecked.  Shouldn't the URLs in the XML file be the same as the normal sitemap?

Sitemap is http://forums.photoartsforum.com/index.php?action=sitemap , xml is http://forums.photoartsforum.com/index.php?action=sitemap;xml
Do this... check that box, save your settings, then uncheck the box, then save your settings again and see what happens.

Edit, I think I know the issue, and its rare... but on line 108 of Sitemap.template.php, change
         if ($modSettings['queryless_urls']==0)

to
         if (empty($modSettings['queryless_urls']) || $string == $scripturl)
« Last Edit: May 22, 2007, 03:39:31 PM by Matt @ ARTcom »
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...
                     

Offline Nutter

  • Semi-Newbie
  • *
  • Posts: 17
    • Forums, Blogs, Wikis
Re: SMF Sitemap
« Reply #24 on: May 22, 2007, 03:30:46 PM »
Quote
Do this... check that box, save your settings, then uncheck the box, then save your settings again and see what happens.
That seems to have fixed it.  Do you mind sharing the cause?  Call it a morbid curiosity  :D
- Ryan [nofollow]

Offline SlammedDime

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,280
  • School of Air Ride
    • matt.zuba on Facebook
    • @mattzuba on Twitter
    • ZubaFitness
Re: SMF Sitemap
« Reply #25 on: May 22, 2007, 03:39:07 PM »
Quote
Do this... check that box, save your settings, then uncheck the box, then save your settings again and see what happens.
That seems to have fixed it.  Do you mind sharing the cause?  Call it a morbid curiosity  :D
Beats me.... all I can figure was that the queryless_url setting was improperly set to some strange value, which caused error in this mod, but allowed your board to still function properly.  Editing Sitemap.template.php as I suggested above would clear it up alltogether, as that is the similar code that is used in the SMF source files.
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...
                     

Offline Hadi

  • Jr. Member
  • **
  • Posts: 133
    • Seeking Truth!!
Re: SMF Sitemap
« Reply #26 on: June 01, 2007, 10:58:05 AM »
tried the more...but i keep receive the following msg

An Error Has Occurred!
Unable to load the 'main' template.


what did i do wrong?


Offline SlammedDime

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,280
  • School of Air Ride
    • matt.zuba on Facebook
    • @mattzuba on Twitter
    • ZubaFitness
Re: SMF Sitemap
« Reply #27 on: June 01, 2007, 02:12:14 PM »
Make sure the file Sitemap.template.php made it into your default theme directory.
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...
                     

Offline wicked1

  • Semi-Newbie
  • *
  • Posts: 36
  • Gender: Female
Re: SMF Sitemap
« Reply #28 on: June 04, 2007, 04:56:19 AM »
i just installed it and it works just fine on my site. This is a great mod :)
I even got it to work on a custom theme and put it into the main menu. I am also glad that it doesn't show "hidden" boards.

I just have two questions:

1. would it be possible to make it so it only shows the main boards in the sitemap? Like have it minimize the sub-forums until they click the arrow to expand? I have a rather large board and the sitemap seems to go on forever lol
2. i know you mentioned it before, but i would like to make it so that xml is admin-only. Can you explain how to do that please?

thank you so much!

Offline SlammedDime

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,280
  • School of Air Ride
    • matt.zuba on Facebook
    • @mattzuba on Twitter
    • ZubaFitness
Re: SMF Sitemap
« Reply #29 on: June 04, 2007, 06:29:42 AM »
In the next release, when I have some free time to code more, I'll add some settings in the admin panel for the sitemap.  I'll add in an option for collapsible sub-boards, and I'll also add in an option for the XML link to be shown to only admins or everyone, along with options like excluding additional boards, and maybe some other user suggestions?

As for making it admin viewable only for the time being...

Code: (find) [Select]
global $scripturl, $modSettings, $txt;
Code: (replace) [Select]
global $scripturl, $modSettings, $txt, $context;
Code: (find) [Select]
echo '</li>
<li>', getXMLLink(), '</li>';
Code: (replace) [Select]
echo '</li>';
if($context['user']['is_admin'])
echo '
<li>', getXMLLink(), '</li>';
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...
                     

Offline wicked1

  • Semi-Newbie
  • *
  • Posts: 36
  • Gender: Female
Re: SMF Sitemap
« Reply #30 on: June 04, 2007, 07:48:09 AM »
thank you for such a quick response :)
i'm looking forward to the next release, i can't think of any other suggestions at this point.
And that worked! So now the xml for my sitemap is admin only :)
thanks again!

Offline Hadi

  • Jr. Member
  • **
  • Posts: 133
    • Seeking Truth!!
Re: SMF Sitemap
« Reply #31 on: June 04, 2007, 09:49:57 AM »
Make sure the file Sitemap.template.php made it into your default theme directory.

Its there....but the size is only Zero B

Offline SlammedDime

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,280
  • School of Air Ride
    • matt.zuba on Facebook
    • @mattzuba on Twitter
    • ZubaFitness
Re: SMF Sitemap
« Reply #32 on: June 04, 2007, 03:06:05 PM »
Download another copy of the mod and manually upload that file to your default theme directory.
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...
                     

Offline romeoyankee

  • Semi-Newbie
  • *
  • Posts: 22
Re: SMF Sitemap
« Reply #33 on: June 22, 2007, 11:16:36 AM »
hey guys.. quick question for you in regards to uploading the sitemap to google.

So i already have my account set up with google under the domain www.cyow.ca [nofollow]

My forums are in www.cyow.ca/forums/ [nofollow]

Is there a way to just upload the link to the sitemap file??? 

When I try and add this http://www.cyow.ca/forums/index.php?action=sitemap;xml [nofollow] to google it tells me that it isnt a valid site..

It says "The Sitemap must be located at http://www.cyow.ca/ [nofollow]. To add a Sitemap at http://www.cyow.ca/forums/ [nofollow], first add that site to your account and then click the Add a Sitemap link beside it.


How do I get the sitemap file uploaded to google?  Do I have to save the link as sitemap2.xml (i have a sitemap file for the rest of my site as well) and then upload it to my server and then give that to google? 

Let me know!

Offline SlammedDime

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,280
  • School of Air Ride
    • matt.zuba on Facebook
    • @mattzuba on Twitter
    • ZubaFitness
Re: SMF Sitemap
« Reply #34 on: June 22, 2007, 05:20:30 PM »
I'm sure it wouldn't be too difficult to use Apache's mod_rewrite and put a .htaccess file in your root directory that would point at that file.  Let me play around and see if I can come up with something.
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...
                     

Offline SlammedDime

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,280
  • School of Air Ride
    • matt.zuba on Facebook
    • @mattzuba on Twitter
    • ZubaFitness
Re: SMF Sitemap
« Reply #35 on: June 22, 2007, 05:29:12 PM »
put the following in a .htaccess file in your root directory and see if it works for you... (or add to one that may already be there)

Code: [Select]
RewriteEngine on
RewriteRule ^sitemap2.xml$ /forums/index.php?action=sitemap;xml

Then navigate to http://www.cyow.ca/sitemap2.xml and you should see the same thing as if you went to http://www.cyow.ca/forums/index.php?action=sitemap;xml.  If it does work, then you can simply submit http://www.cyow.ca/sitemap2.xml to google as well and you should be set.
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...
                     

Offline romeoyankee

  • Semi-Newbie
  • *
  • Posts: 22
Re: SMF Sitemap
« Reply #36 on: June 23, 2007, 03:50:34 PM »
thanks alot for a fast AND correct answer!!! 

I havent worked with htaccess alot and dont really know how to.  That worked perfectly!

thanks man

Offline Garry1953

  • Jr. Member
  • **
  • Posts: 118
    • Artists Online Australia Art Forum
Re: SMF Sitemap
« Reply #37 on: June 24, 2007, 05:44:07 PM »
Just added this mod to my forum, works perfectly, thanks.

Offline amirali.b

  • Semi-Newbie
  • *
  • Posts: 35
Re: SMF Sitemap
« Reply #38 on: June 25, 2007, 02:24:35 AM »
HI
I whant to install this mod manually for my costum theme
<file name="$boarddir/index.php">
I dont have boarddir !! which index.php file?

Offline SlammedDime

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,280
  • School of Air Ride
    • matt.zuba on Facebook
    • @mattzuba on Twitter
    • ZubaFitness
Re: SMF Sitemap
« Reply #39 on: June 25, 2007, 03:47:53 AM »
If you are installing on a custom theme, you do not need to worry about that line.... only only need to worry about the install instructions that have $themedir in them.
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...