Improving Joomla-SMF modules

Started by kai920, October 03, 2007, 08:23:53 AM

Previous topic - Next topic

rummie

are the 'bad' links clickable and resolve to the correct post/topic? if so, you may not want to change them otherwise Google may get confused and think you have created duplicate content since you know have a different URL pointing to the same data?

#new should be better than  ;topicseen#new"  but it may not be worth the trouble to change it, especially if it works

Orstio

Quote from: kai920 on October 18, 2007, 02:09:21 PM
OK some more progress made, but I have some questions:

1) I added a global $mosConfig_sef to the top of the smf_recentTopics.php file. Is this an acceptable practice?

2) Is ";topicseen#new" required or is just "#new" enough for appending to the end of the URL?  I noticed the forums here only use #new.

My bridge currently sends notification emails with what appears to be an incorrect "/topic,1761.new/topicseen,topicseen#new". Which is the correct URL?



1)  Absolutely fine.  There is no reason you can't global any of the $mosConfig variables.

2) The "topicseen" in the URL is to tell SMF to remove the "new" icon from the topic after you have clicked it.  Don't expect your 1.1.4 forum to behave exactly the same as this 2.0 beta forum. ;)

Quoteare the 'bad' links clickable and resolve to the correct post/topic? if so, you may not want to change them otherwise Google may get confused and think you have created duplicate content since you know have a different URL pointing to the same data?

I'm wondering how the Googlebot is going to receive a notification email?

kai920

Quote from: rummie on October 18, 2007, 05:26:35 PM
are the 'bad' links clickable and resolve to the correct post/topic? if so, you may not want to change them otherwise Google may get confused and think you have created duplicate content since you know have a different URL pointing to the same data?

#new should be better than  ;topicseen#new"  but it may not be worth the trouble to change it, especially if it works

If you are talking about the recent posts module, then yes the "bad" links on the module were clickable and did resolve to the post.

Orstio, what should then be the ideal SEF URL with the topicseen parameter for recent posts in 1.1.4?

/topic,1761.msg6718/topicseen,#new
or
/topic,1761.new/topicseen,topicseen#new
or
something else?  If I am correct ';topicseen#new' is not SEF with the semicolon in there.

kai920

#23
Quote from: Orstio on October 18, 2007, 06:46:38 PM
2) The "topicseen" in the URL is to tell SMF to remove the "new" icon from the topic after you have clicked it.  Don't expect your 1.1.4 forum to behave exactly the same as this 2.0 beta forum. ;)

I used sefReltoAbs on a non-SEF URL that had ;topicseen#new appended, and the result was /topicseen,topicseen#new

So is the latter the correct and "official" SEF URL, like in the notification email?



edit - I clicked on an URL without the topicseen inside my board index. (http://localhost/component/option,com_smf/Itemid,71/topic,1761.msg6594#new) and it made the "new icon" disappear. So is topicseen really needed?

kai920

Sorry, another question about the URLs.

This is not a standard bridged SMF URL:  /index.php?option=com_smf&Itemid=71&?[/b]board=1.0.

It should be /index.php?option=com_smf&Itemid=71&[/b]board=1.0 correct?

I'm getting a bit confused about the role of "&" and "?"s in Joomla and SMF URLs.

rummie

Quote from: kai920 on October 19, 2007, 04:17:19 AM
Sorry, another question about the URLs.

This is not a standard bridged SMF URL:  /index.php?option=com_smf&Itemid=71&?[/b]board=1.0.

It should be /index.php?option=com_smf&Itemid=71&[/b]board=1.0 correct?

I'm getting a bit confused about the role of "&" and "?"s in Joomla and SMF URLs.


I believe the ? separates the url resource from the parameter list and is required.


the & separates the different parameters themselves

i.e. index.php?oneparm=1&anotherparam=2

kai920

so the ? is for SMF-only URLs..

the & is for Joomla URLs.

correct?

Kindred

no... the ? is for the first parameter
index.php?param

the & separated parameters in the list
index.php?pama1&param2

this is true regardless of SMF or Joomla.

the &? is incorrect...
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

kai920

Quote from: Kindred on October 19, 2007, 08:25:45 AM
no... the ? is for the first parameter
index.php?param

the & separated parameters in the list
index.php?pama1&param2

this is true regardless of SMF or Joomla.

the &? is incorrect...

OK... since it's a Joomla module, the only place where a ? would exist is index.php?option=com_smf........ right?

So I can safely take out any other ?s in the code for example ?topic or ?board... ???

kai920

Regarding the "new" icon... should that link generated be the same as the post URL?

On the text URL I'm getting
http://localhost/component/option,com_smf/Itemid,71/topic,1746.msg6711/topicseen,topicseen#new

versus new icon
http://localhost/component/option,com_smf/Itemid,71/topic,1746.msg6594/topicseen,topicseen#new


I also need to know about topicseen:
Quote from: kai920 on October 19, 2007, 02:44:03 AM
I used sefReltoAbs on a non-SEF URL that had ;topicseen#new appended, and the result was /topicseen,topicseen#new

So is the latter the correct and "official" SEF URL, like in the notification email?



edit - I clicked on an URL without the topicseen inside my board index. (http://localhost/component/option,com_smf/Itemid,71/topic,1761.msg6594#new) and it made the "new icon" disappear. So is topicseen really needed?


Orstio

Yes, it will need to be topicseen,topicseen because Joomla will omit the "topicseen" from the URL before it gets to SMF if there is no value.

kai920

1) OK, but the ;topicseen really is necessary? You said "The "topicseen" in the URL is to tell SMF to remove the "new" icon from the topic after you have clicked it"  but it seems that just the #new also accomplishes the same thing - or am I mistaken?

2) Should the links of the new icon and text link really be different?

Orstio

1) No.  The #new is a HTML reference to a page anchor.  It causes the browser to move the page to that anchor.

2)  Yes.  The "New" icon takes you to the newest post.  The text link takes you to the topic.


kai920

Quote from: Orstio on October 19, 2007, 09:55:30 PM
1) No.  The #new is a HTML reference to a page anchor.  It causes the browser to move the page to that anchor.

Right, but after I read the new message on the #new anchor, will the new icon not disappear automatically? It seems to do that. ???

Quote
2)  Yes.  The "New" icon takes you to the newest post.  The text link takes you to the topic.
So the text link should take me to the first post of the topic? can you explain why the different topic,1746.msgxxxx?


On the text URL I'm getting
http://localhost/component/option,com_smf/Itemid,71/topic,1746.msg6711/topicseen,topicseen#new

versus new icon
http://localhost/component/option,com_smf/Itemid,71/topic,1746.msg6594/topicseen,topicseen#new

Orstio

The text link should be giving you just a link to the topic, not to the first new post.  It should not have a #new on the end.

kai920

Quote from: Orstio on October 20, 2007, 07:50:40 AM
The text link should be giving you just a link to the topic, not to the first new post.  It should not have a #new on the end.

OK. On the board index I see what you mean:
the text link is http://localhost/component/option,com_smf/Itemid,71/topic,1746.0
and the new icon is http://localhost/component/option,com_smf/Itemid,71/topic,1746.msg6594#new

1) Sorry, I'm still not understanding why the "topicseen" is needed as it's not present in the above URLs.

2) On the recent posts module the above behavior is (currently) not duplicated.

text link:
http://localhost/component/option,com_smf/Itemid,71/topic,1746.msg6711/topicseen,topicseen#new

Not sure where that msg6711 is coming from, but it should just be 0.

Would it be better to just make both text link and new icon in the recent posts module point to the newest post, since it is a "recent posts" module?

Orstio

The "new" icon, and the "topicseen" in the URL should only be visible for topics that have been updated and you have not viewed.

All of the code you need to look at is in SSI.php.  Everything in the module should reflect exactly what SSI.php would output.

kai920

#37
I see, so the topicseen and new icon always go together?

Is there something wrong with this URL, if msg 6594 is NOT part of topic 1746? http://localhost/component/option,com_smf/Itemid,71/topic,1746.msg6594#new

kai920

#38
Orstio, I emailed you a php file. Did you get it?

I used it on my live server but interesting it does NOT convert the links to SEF, whereas on localhost it does.
Nevermind, figured out it has to do with SEF Advance.

kai920

I tried to force SEF output by using sefReltoAbs (without checking for $mosConfig_sef) but the URL still comes out non-SEF. What would be possible reasons for this?

Advertisement: