Jump to content

5.2.4 Removes index.php if last in url


Dirty Butter

Recommended Posts

/classes/seo.class.php

* When converting a URL to an SEO path, removes 'index.php'

  if last chars in URL.

 

I just created my first sitemap with 5.2.4, and the homepage still has the index.php ending. I understood that 5.2.4 would prevent that from happening.

 

On testing in FF and IE by putting the full url including index.php at the end - nothing is stripped.

 

Also, I have custom 404 type pages created as documents that show up in the sitemap, too. Is there any way to keep them from showing up there?

Link to comment
Share on other sites

That change in the code belongs to the SEOable() function. That function is called only by the currentPage() function and the addBreadcrumb function.

 

The sitemap file has three regular links at the start:

/index.php

/index.php?_a=saleitems

/index.php?_a=certificates

 

Which is odd because saleitems and certificates can certainly be made into friendly URLs.

 

currentPage() and addBreadcrumb are used when creating links that are placed in web pages and when needing to have the browser re-request a page after processing the data submitted by forms.

 

The documents: are they enabled? If so, are they showing in the docs section of the web page? If not, what did you do to keep them from showing?

 

 

Link to comment
Share on other sites

The documents: are they enabled? If so, are they showing in the docs section of the web page? If not, what did you do to keep them from showing?

 

All the 404 type documents are hidden  (as well as some other documents that are linked to from the hidden document "Do YOU Think Plush Friends Are Important?" I have that document hard coded into main.php.

That change in the code belongs to the SEOable() function. That function is called only by the currentPage() function and the addBreadcrumb function.

currentPage() and addBreadcrumb are used when creating links that are placed in web pages and when needing to have the browser re-request a page after processing the data submitted by forms.

 

I couldn't find any link that wrote home without the index part, even in the Breadcrumb.

Link to comment
Share on other sites

"All the 404 type documents are hidden."

 

Status: green check

There is no Hidden column unless you have a mod. If that's the case, then it's the mod's job to adjust the query that inhibits hidden docs from getting into the sitemap.

 

 

"...even in the Breadcrumb."

 

I can double-check that.

Link to comment
Share on other sites

Ah!, so there is. (That Yes/No could easily be put in the table.)

I will assume it is the 'navigation_link' column in the CC_documents table.

In CC524, /classes/seo.class.php, line 656, change just this part of the statement to this:

array('doc_parent_id' => '0', 'doc_status' => 1,'navigation_link'=>1)),
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...