TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,973
  • Latest: NonStop
Stats
  • Total Posts: 196,219
  • Total Topics: 21,352
  • Online today: 556
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 1
  • Guests: 193
  • Total: 194
  • Itchdog

Language Specific Frontpage

Started by Kordanor, June 20, 2009, 03:02:18 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Kordanor

Heya,

I have got 2 languages installed in the board and I already managed to include specific panels dependent on the language, so that newest articles are just shown from specific language boards.

But where I can't find a solution is the main window on the frontpage. Is it possible to show just posts of specific threads there dependend on the language selection?

G6Cad

We need to know more about your setup to answer that question.

Please read the Posting Guidelines.html and uppdate your first post with the info we ask for in the posting guide.

Kordanor

I don't really see a point in that as it is a general functionallity question but there you go:

Link to my site: http://ndnw.piranho.de/forum/index.php
(which wont work most probably as I am editing in it all the time)
SMF version: 1.19
TP version: v1.0 beta 4
Theme name and version: default...still modifying it myself
Browser Name and Version: IE 6.0 FF 3.0.11 Opera 9.64
Mods installed: None
Related Error messages: None

G6Cad

With info we need more of i mean what you posted so we can see what you have so far.
And with more info i mean more info on your settings, what you have tried so far, if you are using blocks, or articles, or single pages etc.

More or less, what is your setup and what have you done so far with the settings.

Kordanor

Well, maybe I just put my question not straight enough.

Is it possible without editing within the code to implement an alternative/additional frontpage which is getting other boards to display as news?

Lets say:

German Frontpage
getting news from boards 5,6,7 (which are german)

English Frontpage
getting news from boards 8,9,10 (which are english)

I could find enable/disable language options for the additional blocks and panels but nothing on the main "content" window.

If you say that there is no easy solution and I have to digg in the code, thats an okish anwer for me too, at least I know what to do then. :)

G6Cad

AH!, now i see what you mean, i will have to let the coders answer this one as i dont know ( interested in the answers my self though )  ;)

Zetan

Take a look in the Block Code Snippets board. Theres a snipet to show recent posts from boards, X, Y , Z. Then use it again for another article, show boards A, B, C.

It uses the ssi_recentTopics() and has the topics in an array.

http://www.tinyportal.net/index.php/topic,1234.0.html

Try changing

ssi_recentTopics

to

ssi_boardNews

It might just work.. I haven't tried it though.

Zetan

Actually, all you should need is this:

Code (PHP Article) Select


$result=ssi_boardNews(10,array(1,3,4),'return');



let me know if it works, I may just use it myself.

Zetan

Hmm.. after some testing, it wasn't that easy :P
have a look at this topic at SMF:

http://www.simplemachines.org/community/index.php?topic=163375.0



for TP php articles or blocks, the php tags are not needed

Code (php open tag) Select


<?php




Code (php close tag) Select


?>


IchBin

There is no way to do this without modifying the code for articles. The only work around I would try is only using blocks on your frontpage. You can then control blocks with languages. And inside a blocks settigns you can show an article, and then select the language you want the block to show for.

Other than that, you would have to use some custom PHP code checking for a users language in the article.

This website is proudly hosted on Crocweb Cloud Website Hosting.