collapse

* Simple Portal Archived Forum

This is an Archive Forum.

The content in this forum may be out-of-date or have been superseded by newer information, and links in forum pages to other sites may not work.
This forum contains archives for future reference.

Visit our thread at Simple Machines Forum for current support.

SMF 2.1 users: EhPortal is a ported version of Simple Portal specifically designed for the SMF 2.1 branch.
Please visit web-develop.ca to download EhPortal and for its support.

* User Info

 
 
Welcome, Guest. Please login or register.

* Who's Online

  • Dot Guests: 248
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.

* Shoutbox

Refresh History
  • Shoutbox is not for support!
  • {OCS}MasterSeal: Yup, Still adore SP
    April 21, 2019, 07:08:06 PM
  • {OCS}MasterSeal: STILL love SP :)
    November 24, 2018, 05:05:50 AM
  • ♦ Ninja ZX-10RR ♦: <3 aegersz
    September 13, 2018, 03:36:09 PM
  • aegersz: I STILL <3 LOVE SimplePortal
    September 13, 2018, 07:11:39 AM
  • aegersz: o LOVE you guys - Simple Portal rocks !
    May 09, 2018, 05:18:59 AM
  • Chen Zhen: our apologies for the site being down.. please read server issues topic
    March 22, 2018, 05:32:38 AM
  • {OCS}MasterSeal: LOL PLEASE forget I just posted that. I found the answer in my own dang post back in 2015. lol sorry!
    July 04, 2017, 10:47:55 PM
  • {OCS}MasterSeal: I know this SB isnt' for support, but I just have a general question. Who would I contact to find out where SP stores its block info? Is it DB driven or files? I searched the site but came up with nothing. probably my fault any insight is appreciated.
    July 04, 2017, 10:43:36 PM
  • ♦ Ninja ZX-10RR ♦: Excuse me but what does Simpleportal have to deal with that?
    February 05, 2017, 08:21:14 PM
  • WhiteEagle: of course IMHO that site appears to be dead :(
    February 04, 2017, 01:08:05 PM
  • WhiteEagle: If I can get that, then I'll use it for that site...
    February 04, 2017, 01:07:35 PM
  • WhiteEagle: decided to not use SMF for any projects, unless I can get a copy of the premium version of the fanfiction archive plugin
    February 04, 2017, 01:06:54 PM
  • expertdecisions: cloudflare
    January 28, 2017, 08:01:47 AM
  • aegersz: SM release 2.0.13 !
    January 12, 2017, 06:00:13 AM
  • raffo: Tks Emanuele, even if I didn't understand the fix :D
    November 07, 2016, 02:01:20 AM
  • emanuele: [link]
    November 01, 2016, 12:43:50 PM
  • emanuele: raffo: the English support board is a good place. ;)
    November 01, 2016, 12:43:38 PM
  • raffo: Where can I find the fix for the shoutbox?
    November 01, 2016, 05:06:09 AM
  • {OCS}MasterSeal: To the SP team, I make a point to come here and thank you as much as possible for your work.  so again, THANK YOU!
    October 28, 2016, 10:38:05 AM
  • emanuele: That's indeed funny, the limit is present only in the patch and not the full install.
    October 22, 2016, 06:14:58 PM

* Recent Posts

Adding Forums Button to Nav bar by jirapon
[August 01, 2019, 09:07:12 AM]


Re: Board Icons by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 04:03:41 PM]


MOVED: Czech translation???? by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 03:04:51 PM]


Board Icons by jirapon
[July 30, 2019, 07:28:44 AM]


Re: Thankyou Simpleportal, by ♦ Ninja ZX-10RR ♦
[July 29, 2019, 09:41:29 AM]

Blocks speak! Do you have an interest in getting more blocks - or even making your own? The Blocks Board is for you!

Author Topic: Incorrect pagination in articles  (Read 26352 times)

0 Members and 2 Guests are viewing this topic.

Offline ramzesito

  • Semi Newbie
  • *
  • Posts: 23
  • Gender: Male
  • SMF Version: 2.0.11
  • SP Version: 2.3.6
Incorrect pagination in articles
« on: January 25, 2016, 02:47:21 AM »
Hello,
help to solve my problem, please:

I have some articles on my portal (www.sportgen.ru),
Maximum Articles Per Page set to 4,

I noticed if Author is not me (Ramzesito), second admin is Malex, then folowing articles after his article on curernt page are not displayed  :(
error log is empty

thank you
sportgen.ru - cycling, running and skiing in Obninsk and Kaluga region (Russia)

Offline emanuele

  • Developer
  • *
  • Posts: 293
Re: Incorrect pagination in articles
« Reply #1 on: January 25, 2016, 06:08:39 PM »
Which one is the articles block?
Is the one with the title "Сертификаты на Обнинских(Калужских) гонках"?

Offline ramzesito

  • Semi Newbie
  • *
  • Posts: 23
  • Gender: Male
  • SMF Version: 2.0.11
  • SP Version: 2.3.6
Re: Incorrect pagination in articles
« Reply #2 on: January 26, 2016, 02:36:54 AM »
Which one is the articles block?
Is the one with the title "Сертификаты на Обнинских(Калужских) гонках"?

yes , it is a first article, but there are 3 more after it, but they are invisible (approved),
page2 shows 5,6,7,8 articles and so on...
« Last Edit: January 26, 2016, 02:40:11 AM by ramzesito »
sportgen.ru - cycling, running and skiing in Obninsk and Kaluga region (Russia)

Offline emanuele

  • Developer
  • *
  • Posts: 293
Re: Incorrect pagination in articles
« Reply #3 on: January 26, 2016, 04:07:14 PM »
Would you mind taking a screenshot (in English please) of the configuration page of the block?

Offline ramzesito

  • Semi Newbie
  • *
  • Posts: 23
  • Gender: Male
  • SMF Version: 2.0.11
  • SP Version: 2.3.6
Re: Incorrect pagination in articles
« Reply #4 on: January 27, 2016, 04:09:49 AM »
here are (see attach)
sportgen.ru - cycling, running and skiing in Obninsk and Kaluga region (Russia)

Offline Burke Knight

  • Sr. Member
  • ****
  • Posts: 394
  • Gender: Male
  • I tell it how I see it. Don't like it? Hit Alt+F4
    • BurkeKnight Enterprises
  • SMF Version: None
  • SP Version: None
  • Elkarte Version: None
Re: Incorrect pagination in articles
« Reply #5 on: January 27, 2016, 07:20:32 AM »
I think he meant the configuration of the article block.
But what you posted, is also good info, too. :)

Offline emanuele

  • Developer
  • *
  • Posts: 293
Re: Incorrect pagination in articles
« Reply #6 on: January 28, 2016, 02:22:31 AM »
Yep, the configuration of the block.

Offline ramzesito

  • Semi Newbie
  • *
  • Posts: 23
  • Gender: Male
  • SMF Version: 2.0.11
  • SP Version: 2.3.6
Re: Incorrect pagination in articles
« Reply #7 on: January 28, 2016, 02:06:26 PM »
Sorry, I don't understand,
there are such type of blocks in config: Header, Left, Right, Top, Bottom, Footer.
Articles is absent  :o
To create an article I click in the topic - Add as article...
sportgen.ru - cycling, running and skiing in Obninsk and Kaluga region (Russia)

Offline emanuele

  • Developer
  • *
  • Posts: 293
Re: Incorrect pagination in articles
« Reply #8 on: January 29, 2016, 04:47:42 AM »
The one that you created and that is causing problems, go to modify that block:
* go to the list of blocks you have (admin > simple portal > blocks)
* find the block that is causing problems,
* click on the icon
* and take a screenshot of the page.

Offline ramzesito

  • Semi Newbie
  • *
  • Posts: 23
  • Gender: Male
  • SMF Version: 2.0.11
  • SP Version: 2.3.6
Re: Incorrect pagination in articles
« Reply #9 on: January 29, 2016, 12:59:56 PM »
emanuele, are you SP developer?
are you sure that ArticleBlock is exist?
I can't find it,
I see just Header, Left, Right, Top, Bottom, Footer blocks

Burke Knight, am I not right?
sportgen.ru - cycling, running and skiing in Obninsk and Kaluga region (Russia)

Offline Burke Knight

  • Sr. Member
  • ****
  • Posts: 394
  • Gender: Male
  • I tell it how I see it. Don't like it? Hit Alt+F4
    • BurkeKnight Enterprises
  • SMF Version: None
  • SP Version: None
  • Elkarte Version: None
Re: Incorrect pagination in articles
« Reply #10 on: January 29, 2016, 09:54:04 PM »
No, you are not.
You have a block set up, so in the listing of blocks, you should be able to find the one with the name of your articles block.
Looks like it is either under the Top blocks section, or maybe at top of the Bottom blocks section.
I am unable to determine which.

Offline ramzesito

  • Semi Newbie
  • *
  • Posts: 23
  • Gender: Male
  • SMF Version: 2.0.11
  • SP Version: 2.3.6
Re: Incorrect pagination in articles
« Reply #11 on: January 30, 2016, 01:56:34 PM »
is it?
sportgen.ru - cycling, running and skiing in Obninsk and Kaluga region (Russia)

Offline Burke Knight

  • Sr. Member
  • ****
  • Posts: 394
  • Gender: Male
  • I tell it how I see it. Don't like it? Hit Alt+F4
    • BurkeKnight Enterprises
  • SMF Version: None
  • SP Version: None
  • Elkarte Version: None
Re: Incorrect pagination in articles
« Reply #12 on: January 30, 2016, 06:09:41 PM »
I do not see an articles block listed in there.
A Board news is, but deactivated.
Looks like your articles block, is done maybe as a custom BBC block, but not sure, maybe the one named News For Portal Only.
Unsure if that is it, since not know your language, or all the blocks there.

Offline emanuele

  • Developer
  • *
  • Posts: 293
Re: Incorrect pagination in articles
« Reply #13 on: January 31, 2016, 05:30:43 AM »
are you sure that ArticleBlock is exist?
I mentioned "articles" because you wrote articles in your first message.
I cannot know if you found some "article" block around the forum here, or at sm.org, or somewhere on the internet.

That's why I asked you for the picture of "The [block] that is causing problems".
Judging from the look of it, it may be the "Board News", even though it looks disabled.

I need to see the configuration of this particular block that is not working the way you want.
Maybe [SiNaN], knowing SP much better than me could give you an answer without that information, but I don't know what suggest you without... :(

Offline ramzesito

  • Semi Newbie
  • *
  • Posts: 23
  • Gender: Male
  • SMF Version: 2.0.11
  • SP Version: 2.3.6
Re: Incorrect pagination in articles
« Reply #14 on: February 01, 2016, 08:03:18 AM »
Dear colleagues,
I tested a second forum and portal (the same versions)
http://www.sportgen.ru/forumtest/

I deactivated all central blocks, as you can see in attach
and as you can see , that portal shows articles anyway

So, I see, that Articles shown are not depend on any block in configuration  :0

May be, we need to consult some more advanced user (or admin) of Simple Portal?
sportgen.ru - cycling, running and skiing in Obninsk and Kaluga region (Russia)

Offline Burke Knight

  • Sr. Member
  • ****
  • Posts: 394
  • Gender: Male
  • I tell it how I see it. Don't like it? Hit Alt+F4
    • BurkeKnight Enterprises
  • SMF Version: None
  • SP Version: None
  • Elkarte Version: None
Re: Incorrect pagination in articles
« Reply #15 on: February 01, 2016, 12:04:42 PM »
You do not get more "advanced" than a developer, answering your questions, like Emanuele is. XD

Please, post all from the Articles settings page, then.
Seems we were under the impression that the articles section was done as a block, as is usually how people set it up.

Offline emanuele

  • Developer
  • *
  • Posts: 293
Re: Incorrect pagination in articles
« Reply #16 on: February 01, 2016, 04:30:07 PM »
Well, even though I'm a developer I don't know for sure all the SP internals.
So other may very well know much more than I do. ;)

Offline ramzesito

  • Semi Newbie
  • *
  • Posts: 23
  • Gender: Male
  • SMF Version: 2.0.11
  • SP Version: 2.3.6
Re: Incorrect pagination in articles
« Reply #17 on: February 03, 2016, 01:03:39 AM »
Well, even though I'm a developer I don't know for sure all the SP internals.

Emanuele,
so, who is the super man, who are coding SP internals by his own hands?
Who can explain how *.php file is working and processing data from SQL database?

Now I see just administration support, not programming  :(
sportgen.ru - cycling, running and skiing in Obninsk and Kaluga region (Russia)

Offline ♦ Ninja ZX-10RR ♦

  • Spammer Hammer
  • Support
  • *
  • Posts: 1193
  • Gender: Male
  • Sniper Legends
    • Virtual Interactive Games Entertainment™
  • SMF Version: 2.0.13
  • SP Version: 2.3.6
  • Elkarte Version: 1.0.6
Re: Incorrect pagination in articles
« Reply #18 on: February 03, 2016, 02:02:56 AM »
Can we please stay on topic? It derailed from trying to describe and solve the problem to who is doing what about SimplePortal. Kindly try to describe what is the problem as per the requests above.

As for the off-topic, emanuele knows the code pretty well, he is just being humile, he always is. However, the main coder is [SiNaN], who hasn't been on for a while.
Have you tried SimplePortal Documentation before asking? ;)
F.A.Q.  English Support  |  Blocks Support
Fancy Feature idea ?!  |  Blocks Requests
Themes & Graphics

? My job! ?No PMs for support unless it's a paid request. Thank you! :)#OpIsis

Offline ramzesito

  • Semi Newbie
  • *
  • Posts: 23
  • Gender: Male
  • SMF Version: 2.0.11
  • SP Version: 2.3.6
Re: Incorrect pagination in articles
« Reply #19 on: February 03, 2016, 02:17:28 PM »
Ninja,
my problem was described at first post:

Not all articles displayed on pages (must be 4 per page),
now it may be 1, 2, 3, or 4...
I noticed that articles disappear after article by author Malex only

I have been told to check an ArticleBlock config, but it is not exist in my SP version (2.3.6),

I am ready to check a php-code step-by-step to reveal a bug

help me, please

sportgen.ru - cycling, running and skiing in Obninsk and Kaluga region (Russia)

Offline Burke Knight

  • Sr. Member
  • ****
  • Posts: 394
  • Gender: Male
  • I tell it how I see it. Don't like it? Hit Alt+F4
    • BurkeKnight Enterprises
  • SMF Version: None
  • SP Version: None
  • Elkarte Version: None
Re: Incorrect pagination in articles
« Reply #20 on: February 03, 2016, 03:58:31 PM »
Please, post all from the Articles settings page, then.
Seems we were under the impression that the articles section was done as a block, as is usually how people set it up.

Offline emanuele

  • Developer
  • *
  • Posts: 293
Re: Incorrect pagination in articles
« Reply #21 on: February 04, 2016, 12:46:03 PM »
So much for not knowing articles are displayed in the home page when "enable articles" is checked.

What we know up until now is that when the article are shown on the portal page, some may be missing (see the OP).

Why articles do not show up?
I have close to no idea.

But, looking carefully (see the attachment) in some articles malex is colored in red (admin groun), in others is not.
So a question arises: could it be you did some change somewhere in the past to the way articles are picked and shown?
Do you have other mods installed?

Offline [SiNaN]

  • Mr. SimplePortal
  • Developer
  • *
  • Posts: 6782
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Incorrect pagination in articles
« Reply #22 on: February 04, 2016, 05:07:17 PM »
This looks quite curious indeed. I don't see why something like this should ever happen unless some other mod or modification is doing something unusual, but you never know!

In addition to emanuele's questions; please attach the following files from your forum for starters: ./Sources/PortalArticles.php and ./Themes/default/PortalArticles.template.php
And slowly, you come to realize... It's all as it should be...

Offline ramzesito

  • Semi Newbie
  • *
  • Posts: 23
  • Gender: Male
  • SMF Version: 2.0.11
  • SP Version: 2.3.6
Re: Incorrect pagination in articles
« Reply #23 on: February 05, 2016, 04:32:36 PM »
In addition to emanuele's questions; please attach the following files from your forum for starters: ./Sources/PortalArticles.php and ./Themes/default/PortalArticles.template.php

SiNaN, thank you for forwarding me  :nervous-happy:

I carefully checked PortalArticles.php,
exactly the code:

Code: [Select]
$article_request = $smcFunc['db_query']('','
SELECT
a.id_article, a.id_category, a.id_message, a.approved, c.name as cname, c.picture, m.id_member,
IFNULL(mem.real_name, m.poster_name) AS poster_name, m.icon, m.subject, m.body, m.poster_time,
m.smileys_enabled, t.id_topic, t.num_replies, t.num_views, t.locked, b.id_board, b.name as bname,
mem.avatar, at.id_attach, at.attachment_type, at.filename
FROM {db_prefix}sp_articles AS a
INNER JOIN {db_prefix}sp_categories AS c ON (c.id_category = a.id_category)
INNER JOIN {db_prefix}messages AS m ON (m.id_msg = a.id_message)
INNER JOIN {db_prefix}topics AS t ON (t.id_first_msg = a.id_message)
INNER JOIN {db_prefix}boards AS b ON (b.id_board = m.id_board)
LEFT JOIN {db_prefix}members AS mem ON (mem.id_member = m.id_member)
LEFT JOIN {db_prefix}attachments AS at ON (at.id_member = mem.id_member)
WHERE {query_see_board}
AND a.approved = {int:approved}
AND publish = {int:publish}
ORDER BY a.id_message DESC' . (empty($modSettings['articleperpage']) ? '' : '
LIMIT {int:start}, {int:end}'),
array(
'approved' => 1,
'publish' => 1,
'start' => $context['start'],
'end' =>  $modSettings['articleperpage'],
)
);

I run it as test and saw dublicated rows for Malex...

Some time ago I changed Avatars folder on server for users,
The snag - Malex had 2 avatars in attachments table, see attach,
I don't know which bug is it in Articles, SMF or SP,
but after deletion a dublicate I got a right Article visualisation!  :nervous-happy:

I'm very glad!

Thank you all for help
« Last Edit: February 05, 2016, 04:37:26 PM by ramzesito »
sportgen.ru - cycling, running and skiing in Obninsk and Kaluga region (Russia)

Offline emanuele

  • Developer
  • *
  • Posts: 293
Re: Incorrect pagination in articles
« Reply #24 on: February 07, 2016, 03:59:45 PM »
Track when the second avatar was added may be rather tricky indeed.
Judging by the look of the name, the "old" avatar is pre-2.0 RC1-1, while the other is post.
Probably something happened and SMF was not able to drop the old one in favour of the new and things got messed up.

Offline mariakatosvich

  • Just Registered
  • Posts: 1
  • SMF Version: 1.1.2
  • SP Version: 2.0.4
  • Elkarte Version: 1.0.2
Re: Incorrect pagination in articles
« Reply #25 on: August 05, 2016, 07:13:25 AM »
yes , it is a first article, but there are 3 more after it, but they are invisible (approved),
page2 shows 5,6,7,8 articles and so on...