Skip to main content
[ADDON] SimplePortal Started by Spuds · · Read 348370 times 0 Members and 4 Guests are viewing this topic. previous topic - next topic

Re: [ADDON] SimplePortal

Reply #30

Quote from: Spuds – Found one mistake that would cause double blocks outside of the portal page and fixed that.  It should fix issue you reported, so get the latest from the repo and let us know :D

Everything is fine now... good install and the blocks are no longer doubled...

So happy to have stumbled across ElkArte and to find SimplePortal here also... one happy camper...
<( Smasher )>

ElkArte 1.0 RC 2 | SimplePortal 2.4

Re: [ADDON] SimplePortal

Reply #31

I was looking around in SP files and I think that I found fix for wrong URL and title in portal menu tab, here's my menu code:
Code: [Select]



//edit:
removed $scripturl, because now it is not used in my version

//edit2

doesn't work correctly with integration mode :|

//edit3
Now it works for me fine :D

Is someone needs solution for now here's button code:
Code: [Select]
function sp_integrate_menu_buttons(&$buttons)
{
global $txt, $scripturl, $modSettings, $context;

require_once(SUBSDIR . '/Portal.subs.php');
loadLanguage('SPortal', sp_languageSelect('SPortal'));

if ($modSettings['sp_portal_mode'] == 1)
$sportalurl = $scripturl;
elseif ($modSettings['sp_portal_mode'] == 3)
$sportalurl = $modSettings['sp_standalone_url'];
else
$sportalurl = '';

// Define the new menu item(s)
$buttons = elk_array_insert($buttons, 'home', array(
'portal' => array(
'title' => empty($txt['sp-portal']) ? 'Portal' : $txt['sp-portal'],
'data-icon' => '',
'href' => $sportalurl,
'show' => in_array($modSettings['sp_portal_mode'], array(1, 3)) && empty($context['disable_sp']),
'sub_buttons' => array(),
),
), 'after');
}

To move button to first position change after to before :)
Last Edit: August 10, 2014, 02:46:52 pm by phantom

 

Re: [ADDON] SimplePortal

Reply #32

Not sure if this is related to settings on my computer or SimplePortal...
 
New Custom PHP Block >> Make an Error In PHP Code >> Add Block

The next screen you see is an error screen stating you had invalid code. This screen has a back button but when you click on it you get a "Document Expired" screen. Again I am not sure if this has to do with settings on my computer or not....
<( Smasher )>

ElkArte 1.0 RC 2 | SimplePortal 2.4

Re: [ADDON] SimplePortal

Reply #33

Quote//edit3
Now it works for me fine :D
Missed your edit, thanks for the debugging :)

QuoteNot sure if this is related to settings on my computer or SimplePortal...
Its kind of a generic problem, not just the portal really.   The back button in that form is pretty much like hitting back on your browser, which may or may not work for various reasons.  I'll take a look and see if I can change the fatal error and redirect back to the edit page with the block but thats not going to be easy I feel.

Re: [ADDON] SimplePortal

Reply #34

QuoteNot sure if this is related to settings on my computer or SimplePortal...
Its kind of a generic problem, not just the portal really.   The back button in that form is pretty much like hitting back on your browser, which may or may not work for various reasons.  I'll take a look and see if I can change the fatal error and redirect back to the edit page with the block but thats not going to be easy I feel.
[/quote]

Was not really a big issue for me... just something I came across and thought I would share...
<( Smasher )>

ElkArte 1.0 RC 2 | SimplePortal 2.4

Re: [ADDON] SimplePortal

Reply #35

Quite OT
Quote from: Spuds – The back button in that form is pretty much like hitting back on your browser, which may or may not work for various reasons.
It may be a 1.1 goal to "deprecate"[1]the "fatal_lang_error" function. I think fatal errors should be for very, very serious matters like database errors, not for errors in saving settings, in that case I'd prefer to be able to send the user back to the settings page highlighting the problem/s and giving hint on how to solve it.
In the sense to use it only when really necessary
Bugs creator.
Features destroyer.
Template killer.

Re: [ADDON] SimplePortal

Reply #36

Can't argue with that ... its a bit silly that a form input mistake is fatal ... db or permissions I can see, but a form is another matter.

Re: [ADDON] SimplePortal

Reply #37

Ok, I think I know why you are adding another forum button...

In English version forum homepage has title Community. SP adds Forum button and it's fine.
In Polish (and I guess in many others languages) Community is translated as Forum, as result after installing SP we have two Forum buttons.

And BTW, in latest commit there is broken, you added code that adds variable $sportal, but it's not changed in button href parameter :)

Re: [ADDON] SimplePortal

Reply #38

Thanks, I'll get that fixed  ;D

Re: [ADDON] SimplePortal

Reply #39

Download link is broken.

Re: [ADDON] SimplePortal

Reply #40

Woops ! ... I need to pack up the latest and update the link  :-[  Will do soon!

Re: [ADDON] SimplePortal

Reply #41

I have some questions about the simple portal; I am used to have it together with SMF, and (nearly) everything is working proper.

But it seems not to work well with Elkarte. At the moment I have not installed the portal, before I had a lot of problems with the portal, the shoutbox did not work proper, I could not collapse blocks in portal etc. etc. Maybe some of this mistakes have only depended on my not updated host.

But a member in the german support forum has installed the portal together with Elkarte, his host is up-to-date, he also made the update of Elkarte; I am still using RC2. He has still some of the same problems.

He told me, that by using the block "recent topics/recent posts", the posts are still not in correct order by time. I had noticed this as well before. Fixed Topics are shown there now, always at the top (they were not shown there in SMF at all). The other recent topics are displayd in the wrong order, always the oldest on the top . New Topics are shown on the bottom, (but they should be shown on the top) ore somewhere between. If the maximal numbers of posts is reached, then newer topics will not be displayed at all.

I think, this is a bug.

My second question ist about the version of Simple Portal. If you use it together with SMF, there is a newer one. This is confusing us a bit. Does this don't do any matter, because Simple Portal is a complete other thing, if you use it together with ElkArte?

Re: [ADDON] SimplePortal

Reply #42

Hi Ruth :)
Yes, I have the problem with the recent topics on the portal page.
Nearly all topics are listed in a wrong order, see the screenshot (Heute = today, Gestern = yesterday).
There’s no chronological order. Neither from new to old nor from old to new. I myself would prefer an order from new (top) down to old (bottom).
Would someone please check where the error is?

- Lars

Re: [ADDON] SimplePortal

Reply #43

Quote from: Lars – Would someone please check where the error is?

- Lars
The listing comes from SSI.php, SimplePortal uses ssi_recentTopics function to get the data.

Looking at it the code, the date shown in the listing would be the date the topic was started.  The display order however is based on when the last post was made to the topic.  So a topic with the most recent posting is shown at top, although the date shown is date of the topic creation.  So I believe whats displayed is correct, although completely confusing !

Right now SSI does not return the last update date, only the start date ... I think that should be added in 1.01, until then in SimplePortal we could hide the date to avoid the confusion?

Quote from: Ruth – But it seems not to work well with Elkarte. At the moment I have not installed the portal, before I had a lot of problems with the portal, the shoutbox did not work proper, I could not collapse blocks in portal etc. etc.
I'd ask that you be sure and install the latest code.  SP for ElkArte is still beta level so updates are continually being made.  I know I addressed those two issues some time ago.  I just did a fresh install and those functions appear to be working properly.
Quote from: Ruth – Fixed Topics are shown there now, always at the top (they were not shown there in SMF at all). The other recent topics are displayd in the wrong order, always the oldest on the top . New Topics are shown on the bottom, (but they should be shown on the top) ore somewhere between. If the maximal numbers of posts is reached, then newer topics will not be displayed at all.

I think, this is a bug.

I think this is what Lars stated as well, so I hope my above explanation explains it or are there other areas in question as well.

Quote from: Ruth – My second question ist about the version of Simple Portal. If you use it together with SMF, there is a newer one. This is confusing us a bit. Does this don't do any matter, because Simple Portal is a complete other thing, if you use it together with ElkArte?
SP for ElkArte is based on the SimplePortal 2.4 line which is still under development and yet to be released. 

The official released and stable version of SimplePortal is 2.3.x line.  There are new features that were added in 2.4 as well as some ElkArte specific features (just some D&D around the UI since the functions were available in Elk).  I've tried to keep on top of 2.3 fixes as well as 2.4 updates along with changes made to best integrate with ElkArte but there are bugs, most of them mine !

Re: [ADDON] SimplePortal

Reply #44

Thank you very much for your explanations, Spuds!

Quote from: Spuds – I'd ask that you be sure and install the latest code. 

Yes, I will do this...

Today I talked to my hoster, the server was always at PHP 5.3.1.6., when Elkarte was installed first - not a lower version as a did believe. So maybe the errors in my forum, that happend with ElkArte (and together with or without Simple Portal)  were just because there was first RC1, then  RC2...all mixed up. (Huh...difficult to write this in English für me...I think , no one will understand, what I am trying to say) ::)


Quote from: Spuds – The listing comes from SSI.php, SimplePortal uses ssi_recentTopics function to get the data.

Looking at it the code, the date shown in the listing would be the date the topic was started.  The display order however is based on when the last post was made to the topic.  So a topic with the most recent posting is shown at top, although the date shown is date of the topic creation.  So I believe whats displayed is correct, although completely confusing !

Right now SSI does not return the last update date, only the start date ... I think that should be added in 1.01, until then in SimplePortal we could hide the date to avoid the confusion?

I see! This block was always mad, I remember now! This block is quite confusing if you choose "recent topics". "Recent posts" was always working better.

With SMF/Simple Portal I use a "selfmade Script" (not by me)  ;)  in a PHP-block, which is based on "recent posts" (not on "recent topics") and it workes fine, the way I would like to work the block "recent topics". It shows the icon of the topic , the topic name, the board, etc. and  all the topics are in correct order. I would like to have something like this again, changed for ElkArte.

Lars, are the posts in your portal in the correct order by time, if you choose "recent posts" in this block?