Link to my site: http://www.tropicalfishforums.co.uk
SMF version: SMF ver. RC5
TP version: TP ver. TinyPortal10RC1
Default Forum Language: English
Theme name and version: Default
Browser Name and Version: Firefox?
Mods installed: Not Applicable
Related Error messages: None
When adding large articles they end up getting chopped, how do I increase word count?
How many characters is it allowing? You can see this in any good text editor like notepad++. TP's current table should allow over a million characters which I believe is a field type text in the database. If your upgrade didn't go properly you still might be on the old version of the table that only allowed about 65K of text.
40,646 according to notepad ++
I hate to go off topic but I have to ask how did you manage to make your forums quite popular. I see you have a reasonable amount of users online. Some tips on how you did this would be real nice :)
Quite simple, provide something which is required, be friendly and kick out any idiots that appear as soon as possible.
You're going to have to look at the smf_tp_articles table in your database. Look at the body row of that table and see what the column "type" is. If it is text, edit the row and change it to longtext.
That did it IchBin, http://www.tropicalfishforums.co.uk/index.php?page=diyco2
One more problem.
I would like to change the order of the articles in the Article Block, I have saved it time and time again but no go.
What type of article block?
Articles in a category.
In TPortal.php find this line on about #2149
AND art.approved=1", __FILE__, __LINE__);
Change to this:
AND art.approved=1 ORDER BY art.date", __FILE__, __LINE__);
That will order them by date.
Any chance to do it alphabetically?
Change art.date to art.subject
Thank you sir but it is still the same.
That's because you have put a dash at the beginning of your titles.
Did that to give the titles some sort of separation, without the dashes it does not look good.
EDIT.
Removed all Hyphens and still the same as before.
Then you either didn't make the changes properly, or the file didn't get changed some how. The changes worked on my install. If they don't work for yours, I don't know what to tell you really.
Weird, it was not there, edited it 3 times and saved before it worked, must be my ftp client.
In the stats block it shows users online, is there any way to make this autofit instead of scrolling?
TPsubs.template.php
Find this line:
<div style="max-height: 23em; overflow: auto;">';
Remove max-height or change it to a greater value.
Instantly better, thanks mate.
Sure thing. Glad to help!
Quote from: IchBin on February 16, 2011, 11:26:08 PM
Change art.date to art.subject
Another problem, it seems that regardless of what you do in the articles admin the order does not change, image attached.
It's doing what most article systems do that I've seen. Lists the articles in the order they were created. If you want them different, it's just a matter of tracking down the query like I did for the last one and changing it.
It would be much appreciated if you would keep your different questions in different topics. This will help keep topics on the subject and make things easier to find in a search as well. Thanks.
QuoteIf you want them different, it's just a matter of tracking down the query like I did for the last one and changing it.
I would not have clue where to start looking, if it does list the articles as they are written how do you change things when there is a new article added at a later date, not really much point in having the facility in admin if it does not work.
Don't get me wrong, there should be some flexibility on how one could choose to display the articles. It's just not something I can add in right now. The only thing I'm trying to do is to get TP as stable as possible so we can reach our first ever "Official/Stable/Final" release. :)
I'll see if I can't track down the change for you. It might be a day or two because I had an ID10T moment and locked myself out of my server today... so I don't have access to my test files and sites etc. If you don't hear from me in the next couple days, please bump the topic and remind me.
Give me a clue and I will have search through the code.
Actually, I just opened the file after downloading it again and I think I found it.
In TPortal.php find this on about line #820
// should we supply links to articles in same category?
if(in_array('category', $context['TPortal']['article']['visual_options']))
{
$request = tp_query("SELECT id, subject, shortname
FROM " . $tp_prefix . "articles
WHERE category=" . $context['TPortal']['article']['category'] . "
AND off=0
AND approved=1", __FILE__, __LINE__);
Just change the last line to be this instead and see if it works.
AND approved=1 ORDER BY subject", __FILE__, __LINE__);
That worked, nice find.
Quote from: IchBinâ,,¢ on February 22, 2011, 05:49:34 PM
Actually, I just opened the file after downloading it again and I think I found it.
In TPortal.php find this on about line #820
// should we supply links to articles in same category?
if(in_array('category', $context['TPortal']['article']['visual_options']))
{
$request = tp_query("SELECT id, subject, shortname
FROM " . $tp_prefix . "articles
WHERE category=" . $context['TPortal']['article']['category'] . "
AND off=0
AND approved=1", __FILE__, __LINE__);
Just change the last line to be this instead and see if it works.
AND approved=1 ORDER BY subject", __FILE__, __LINE__);
The fix failed this time, there is no sign of ", __FILE__, __LINE__) in TPortal.php
Did you upgrade to SMF2 or something? The fix I posted was for TP install on SMF1.x. If there is no sign of ,__FILE__,__LINE__) it would be because you are using the files that are meant for SMF2.
That explains it, I am using SMF 2.0.2 ::)
Quote from: IchBin™ on February 22, 2011, 05:49:34 PM
Actually, I just opened the file after downloading it again and I think I found it.
In TPortal.php find this on about line #820
// should we supply links to articles in same category?
if(in_array('category', $context['TPortal']['article']['visual_options']))
{
$request = tp_query("SELECT id, subject, shortname
FROM " . $tp_prefix . "articles
WHERE category=" . $context['TPortal']['article']['category'] . "
AND off=0
AND approved=1", __FILE__, __LINE__);
Just change the last line to be this instead and see if it works.
AND approved=1 ORDER BY subject", __FILE__, __LINE__);
Just a heads up that this was not included in the latest version. ???
I didn't plan on changing it for everyone. You are one of maybe just a couple of people that wanted it listed this way. I'd much rather just add a display option down the road.