News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

TinyPortal

Started by lurkalot, February 12, 2005, 04:43:00 AM

Previous topic - Next topic

Biology Forums

#1400
Here's the issue. I don't want the block to appear in the board index, or anywhere else. I only want it to appear when the user is viewing the list of topics inside a board (the message index). However, when they click a topic, and go into a single thread, that block no longer appears.

EDIT: I Think I got it to work: Click Board Index and Display on all boards

DarkAngel612

yes check board index and it is seen ONLY on the main board page that lists all boards on your forum

Display on all boards will show it on each individual board they visit I think

I have mine set for some left blocks to be seen even in some areas like profile or certain threads like our market threads

play around with the controls using a window for the actual settings and another tab or window for the page you are trying to get it to show on. Then you will be able to set it up just the way you hope to do
Fantasy Attic ::  Fantasies Realm Market :: SMF 2.1.4 with various mods and TinyPortal

Biology Forums

Quote from: shuban on June 17, 2011, 05:37:39 PM
Here's the issue. I don't want the block to appear in the board index, or anywhere else. I only want it to appear when the user is viewing the list of topics inside a board (the message index). However, when they click a topic, and go into a single thread, that block no longer appears.

EDIT: I Think I got it to work: Click Board Index and Display on all boards

I take it back, it didn't work! Please help, honestly, if this feature isn't available, I'd like to know from the developer. I only want a block display in the message index of every board, not in topic display, or in post display.

lurkalot

#1403
Try. 

TP admin / Panels.  on each panel for example   Hide left panel when in forum? Yes / No. 

Do this for each panel as required.

Biology Forums

Quote from: lurkalot on June 18, 2011, 10:05:40 AM
Try. 

TP admin / Panels.  on each panel for example   Hide left panel when in forum? Yes / No. 

Do this for each panel as required.

Didn't work... For some strange reason, it works on an older version of Firefox, but not the newer one. However, I still need assistance with this question:

I only want a block display in the message index of every board, not in topic display, or in post display.

I really need this to work :-\ I'm starting to lose faith in this awesome mod :'(

bloc

That would be more difficult, as (if its not changed in later TP versions) the options were only on boards specified(only the message-index or insidethe board(s)). I don't recall an option for messageindex of every board.

You could semi-do it though, by adding a PHP block that check that and exit if doesn't. That means it will show the blocktitle and an empty content(depending on whether you add something else in case its not the correct spot)

That would be something like:

if(isset($_GET['board']) && !isset($_GET['action']) && !isset($_GET['topic']))
{
    // place your code here
}
else
{
   echo 'test'; // A dummy message for every other place, possibly another content
}

Biology Forums

#1406
Quote from: Bloc on June 19, 2011, 09:49:01 AM
That would be more difficult, as (if its not changed in later TP versions) the options were only on boards specified(only the message-index or insidethe board(s)). I don't recall an option for messageindex of every board.

You could semi-do it though, by adding a PHP block that check that and exit if doesn't. That means it will show the blocktitle and an empty content(depending on whether you add something else in case its not the correct spot)

That would be something like:

if(isset($_GET['board']) && !isset($_GET['action']) && !isset($_GET['topic']))
{
    // place your code here
}
else
{
   echo 'test'; // A dummy message for every other place, possibly another content
}


Thank you, Bloc, I will test it and let you know.

Golden, it worked!

Biology Forums

I know I may be asking for too much, but is it possible to program this mod so that if an embedded image (in a post) exceeds 500 px (width), the right panel automatically collapses when the topic is loaded?

bloc

That would be hard, as it then must actually test if any image in the post are over a certain width - it would drive the resouce usage up high with all the the file-checking(since it would need to do it on every post every time.)

I would say a better way is to set the CSS so that the image is scaled down when its over 500px, or just when the space is lower than that. "max-width: 500px;" on the ".post img" tag should solve that, at least on modern browsers.

Biology Forums

Quote from: Bloc on June 19, 2011, 04:09:39 PM
That would be hard, as it then must actually test if any image in the post are over a certain width - it would drive the resouce usage up high with all the the file-checking(since it would need to do it on every post every time.)

I would say a better way is to set the CSS so that the image is scaled down when its over 500px, or just when the space is lower than that. "max-width: 500px;" on the ".post img" tag should solve that, at least on modern browsers.

I will probably end up doing that then, thanks.

Farmacija

I have  to ask in here too for faster response:

Trouble with installation of tp 1 rc2 -> http://www.tinyportal.net/index.php?topic=34113.0
www.farmaceuti.com
www.farmaceuti.com/tekstovi

Alex' Manson

errors in the error log, everything works fine.. but this.. idk.


http://xrevolution.helali.tk/index.php?action=admin;area=logs;sa=errorlog;desc2: strpos() [<a href='function.strpos'>function.strpos</a>]: Empty delimiterFile: /home/vol1/xtreemhost.com/xth_7770219/xrevolution.helali.tk/htdocs/Sources/TPSubs.php
Line: 3077

Kindred

hmmm....

go to profile - select tinyportal and then select articles
Fatal error: Function name must be a string in /....../Sources/TPmodules.php on line 1120

it's this bit....

          if(isset($wysid))
            $smcFunc['db_query']('', '
              UPDATE {db_prefix}tp_data
              SET value = {int:val}
              WHERE id = {int:dataid}',
              array('val' => $value, 'dataid' => $wysid)
            );
Сл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."

Alex' Manson

#1413
didn't understand you, it has something to do with strpos.
because it shows two lines (3097 and 3077)
and they both contain strpos.

help?

Alex' Manson

#1414

Fixed it myself.

IchBin™

Quote from: Sisko Punk on June 21, 2011, 10:09:36 PM

Fixed it myself.
What was the fix? In case I need to put one in for the problem...


Quote from: Kindred on June 21, 2011, 09:14:23 PM
hmmm....

go to profile - select tinyportal and then select articles
Fatal error: Function name must be a string in /....../Sources/TPmodules.php on line 1120

it's this bit....

          if(isset($wysid))
            $smcFunc['db_query']('', '
              UPDATE {db_prefix}tp_data
              SET value = {int:val}
              WHERE id = {int:dataid}',
              array('val' => $value, 'dataid' => $wysid)
            );


It looks like you posted the wrong code from lines 1020 instead of 1120? I've had some bugs come through from all the database conversion queries I changed. IIRC, for that error I left out the $smcFunc global at the top of that function.

Quotefunction tp_profile_articles($memID)
{
   global $txt, $user_profile, $context, $db_prefix, $settings, $scripturl, $smcFunc;
IchBin™        TinyPortal

Alex' Manson

Quote from: IchBin™ on June 22, 2011, 11:01:51 AM
Quote from: Sisko Punk on June 21, 2011, 10:09:36 PM

Fixed it myself.
What was the fix? In case I need to put one in for the problem...


Quote from: Kindred on June 21, 2011, 09:14:23 PM
hmmm....

go to profile - select tinyportal and then select articles
Fatal error: Function name must be a string in /....../Sources/TPmodules.php on line 1120

it's this bit....

          if(isset($wysid))
            $smcFunc['db_query']('', '
              UPDATE {db_prefix}tp_data
              SET value = {int:val}
              WHERE id = {int:dataid}',
              array('val' => $value, 'dataid' => $wysid)
            );


It looks like you posted the wrong code from lines 1020 instead of 1120? I've had some bugs come through from all the database conversion queries I changed. IIRC, for that error I left out the $smcFunc global at the top of that function.

Quotefunction tp_profile_articles($memID)
{
   global $txt, $user_profile, $context, $db_prefix, $settings, $scripturl, $smcFunc;

i removed the original copyright and reposted it in index.template.php
because the original one gets on top of the smf's copyright.
so there was an error in the code know after i altered the copyright.
after all, i removed the whole copyright checks etc, and reputted it manually in index.template.php.

so, it's an issue in My part.

Kindred

#1417
ichBin, again, you are correct (that's what I get for trying to debug after 8 hours of rel work and another 4 of code-tweaking.)

Ok, fixed that error, now this one
go to profile - select tinyportal and then select articles

The database value you're trying to insert does not exist: sorting
Сл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."

IchBin™

Yeah I think I've fixed that one too. I think I put sorting instead of sort. Since you didn't give me a line number, I'll have to sort through the code to find the problem again...

Sources/TPmodules.php
Code (find) Select
ORDER BY art.{raw:sorting} DESC LIMIT {int:start}, 10',

Code (replace) Select
ORDER BY art.{raw:sort} DESC LIMIT {int:start}, 10',



IchBin™        TinyPortal

Kindred

yup, that was it!   YAY!

now to figure out how to get all this crap into a useable set of menus and dropdowns.
Сл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."

Advertisement: