WebDev

EhPortal => EhPortal Support => Topic started by: bigguy on November 08, 2015, 09:30:13 PM

Title: ehportal help
Post by: bigguy on November 08, 2015, 09:30:13 PM
Any chance on gettin a bit of help with eh portal. ;)   8)
Title: Re: ehportal help
Post by: Chen Zhen on November 09, 2015, 05:59:09 PM
Yes of course.
What seems to be the issue?
Title: Re: ehportal help
Post by: bigguy on November 09, 2015, 06:22:44 PM
I have it installed and the portal does not show up. I'm using standalone. Plus I keep getting these errors popping up:

Use of undefined constant WIRELESS - assumed 'WIRELESS'

I have solved this error. In two places in subs-portal.php I think it is called. Two lines have WIRELESS instead of 'wireless' line 705 and one in the 22 something range I think it is.
Title: Re: ehportal help
Post by: bigguy on November 09, 2015, 06:46:23 PM
Sorry I have to say. I thought I installed it but it won't let me. The error I posted above could be from SMF 2.1. So the reason it is not installed is because of this error DURING install:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(255) NOT NULL default ''' at line 2
Title: Re: ehportal help
Post by: bigguy on November 09, 2015, 07:01:10 PM
Line 524 of install.php seems to be giving the error if that helps. Sorry, been off the computer all summer and may have forgot how to post, lol.
Title: Re: ehportal help
Post by: bigguy on November 09, 2015, 10:42:46 PM
So it is installed but that mysql error is right. After fixing the wireless error, shown in an above edited post here  (http://web-develop.ca/index.php?topic=163.msg1147#msg1147) the portal will still not show
Title: Re: ehportal help
Post by: Chen Zhen on November 09, 2015, 11:03:56 PM
My apologies for not responding sooner.
Did you by any chance change any path allocation or perhaps start with a fresh standalone file?
The PortalStandalone.php file should be placed in the parent directory and renamed to index.php.
Then you need to adjust the path variable within that file itself and also go to the portal's admin settings & set the path to the file in the parent directory.
Did you do this procedure?
Title: Re: ehportal help
Post by: bigguy on November 09, 2015, 11:35:00 PM
I'm sorry as well for how messed up my posts are, lol. I tried to install it and because I saw nothing happen and got the mysql error I thought it did not install. It did install. but the portal will not show. I have the forum in a folder off the public_html directory called community. I have renamed the portalstandalone.php file to index.php and set the path in that file to 'public_html/community'. I have also set the url in the admin panel. As posted above I did get rid of the error I was having. Right now though I think maybe the mysql error I got could have something to do with the portal not showing but I am not sure. I hope that clears things up a tad bit more. :)
Title: Re: ehportal help
Post by: Chen Zhen on November 10, 2015, 12:38:08 AM
I do not know what is causing your db error.
I have installed EhPortal on the latest GitHub version of SMF 2.1 and have determined that you are correct in pointing out an issue with wireless detection.
The browser detection is sent to $context['browser'] and can detect if the user is using a mobile device.
I will attach a temporary install package to this post that should work for you although it is not an actual release as I have detected some other issues with the standalone mode that must be fixed.
Thank you for the report.
Title: Re: ehportal help
Post by: bigguy on November 10, 2015, 06:22:08 AM
I'll give that a shot, thanks.
Title: Re: ehportal help
Post by: bigguy on November 10, 2015, 06:34:17 AM
That's not working out either:

Unknown column 'spb.permission_set' in 'field list'
File: /home/bigguy/public_html/community/Sources/Subs-Portal.php
Line: 386
Title: Re: ehportal help
Post by: Chen Zhen on November 10, 2015, 06:54:04 PM

The installation is still showing issues with standalone mode when I test it although I can not duplicate any actual database errors.
This is testing on a local installation using standalone mode.
I will have to set up a live installation using a sub directory with standalone to see if I can duplicate what you are witnessing.
Perhaps later tonight I will have time to look this over.

Title: Re: ehportal help
Post by: bigguy on November 10, 2015, 07:07:55 PM
That sounds great sir. My site is not open yet so it's not hurting anything right now. I will be glad when this is sorted though. When you have time. :)
Title: Re: ehportal help
Post by: Chen Zhen on November 11, 2015, 04:37:53 PM
Just for reference this is the edits the dev team performed that removed the WIRELESS constant.
ref. https://github.com/SimpleMachines/SMF2.1/commit/8c3de44aff61f5003cc09efc3dcaef8005018f43

I am leaning toward some other recent changes are causing the use of the SSI.php file to not set some of the globals properly.
This can possibly be an error/bug within the SMF 2.1.X branch that was overlooked or perhaps I am doing something wrong with the portal setup to cause it.
Title: Re: ehportal help
Post by: bigguy on November 11, 2015, 06:31:57 PM
Did you set up a live site to see if you could see the database errors.
Title: Re: ehportal help
Post by: bigguy on November 11, 2015, 08:17:10 PM
I can not find this in phpmyadmin:

smf_spb_permission_set

should it not be there. ??

I ask because I get this error now after upgrading SMF and trying to re-install ehportal:

Unknown column 'spb.permission_set' in 'field list'
File: /home/***/public_html/community/Sources/Subs-Portal.php
Line: 386
Title: Re: ehportal help
Post by: Chen Zhen on November 11, 2015, 11:43:16 PM


Attached is another beta version where I used a different approach for standalone mode.
It still needs some work & testing but so far for me it functions adequately.
Try uninstalling and deleting what you have and use the atached file.

That column should exist within the sp_blocks table & is called permission_set.
The mod should indeed create that column during installation if it does not exist.
If you upgraded SMF and then attempted to reinstall EhPortal then the column should still exist from the prior installation.

Title: Re: ehportal help
Post by: Chen Zhen on November 12, 2015, 12:30:05 AM
It's a different standalone file therefore make sure you replace the old one with the newer after installation.
Title: Re: ehportal help
Post by: bigguy on November 12, 2015, 08:07:21 AM
Tried to install again and I get the same error about spb_permission. I looked in phpmyadmin and it is not there or being created during install. So I have the same error as above and am not able to do anything unless I reload SMF files.
Title: Re: ehportal help
Post by: Chen Zhen on November 12, 2015, 06:45:43 PM

I made a slight change to the install file.
The routine was originally written by Sinan whereas I can rewrite the entire install.php file to the way I perform what is done there if need be.
First let us try it with the small modification I made to the file.
I tested this by purposely deleting the column that is flagging an error for you and it does add the column anew for me.
Please test the attachment.
Title: Re: ehportal help
Post by: bigguy on November 12, 2015, 08:36:04 PM
It installs clean, takes care of all existing errors in the error log. I have it in standalone using the file from the zip, renamed to index.php and I still get wrong forum directory error.
Title: Re: ehportal help
Post by: bigguy on November 12, 2015, 08:47:23 PM
The url, if ya wanna check it out is:

www.whatsurbeef.ca
Title: Re: ehportal help
Post by: bigguy on November 12, 2015, 08:58:11 PM
So the portal installed. I had the wrong value set for the forum_dir. There are no errors in the error logs and the site runs good. All blocks are enabled but nothing shows either in the forum or the portal. Any ideas. ??
Title: Re: ehportal help
Post by: Chen Zhen on November 12, 2015, 09:41:53 PM

It's a permission issue with the blocks because that block db column was omitted somehow.
Due to that circumstance you must now set the permission values on all blocks.
I had to do the same thing on the test forum where I erased that db column on purpose.

As to how your block permission column got erased in the first place is a mystery atm.
Perhaps you were messing with phpmyadmin at some point and did this in error or maybe some sort of manual changes to a db query at some point?
No matter... adjust the block permissions and it will work.


Title: Re: ehportal help
Post by: bigguy on November 12, 2015, 09:53:16 PM
That was it. I'll change things around later tonight then. I was in phpmyadmin but made no changes at all. I was just lookin around. It's great we got it this far. Thank you for the help my friend. :)
Title: Re: ehportal help
Post by: Chen Zhen on November 12, 2015, 10:01:36 PM

No problem and thank you for pointing out the issues.

Currently the SMF 2.1.X being in beta will go through a lot of changes so we'll just have to put up with compatibility glitches that have to be fixed as this occurs.
I was not able to get the session straightened out while using the home page from a parent url via SSI.php due to some recent changes in SMF 2.1.
What I did was have it use and redirect to ..?action=portal for the home page and then use javascript to change the text of the url.
I am going to change my method from pushState to replaceState prior to releasing a new version and wouldn't mind if you can test it when I attach another copy in this thread shortly.

Keep in mind that only recent browsers will support this method otherwise older browsers will show ..?action=portal.
ref. http://caniuse.com/#feat=history

Title: Re: ehportal help
Post by: Chen Zhen on November 12, 2015, 10:24:10 PM

Here is the package with the changes..
Title: Re: ehportal help
Post by: bigguy on November 12, 2015, 10:47:21 PM
Did you notice the problem with the footer. ??
Title: Re: ehportal help
Post by: bigguy on November 12, 2015, 10:50:38 PM
Clean uninstall of last version and clean install of that one. It fixed the url issue as well. Footer still needs changed. ;)
Title: Re: ehportal help
Post by: Chen Zhen on November 12, 2015, 11:00:44 PM
No I did not look at the footer until you mentioned it.
It is because they changed the text within it and I probably have the text search value hard coded..
I am going to implement a way of detecting the approriate SMF footer text so that it can find it when there are changes.
Thanks again.
Title: Re: ehportal help
Post by: bigguy on November 12, 2015, 11:05:27 PM
Eh, not a problem at all. ;) Just glad to help out. :)
Title: Re: ehportal help
Post by: Chen Zhen on November 12, 2015, 11:16:09 PM

Within the portal settings you can change the standalone url to not include index.php if you decide you do not want that to appear.
You can just enter the url that the standalone file is located in and it should use the index.php file by default but will not show it in the url.
That option is up to you.
Title: Re: ehportal help
Post by: bigguy on November 12, 2015, 11:34:26 PM
Changed it...I like it. :) K, gotta work in the mornin. Seeya tomorrow. Thanks again.
Title: Re: ehportal help
Post by: bigguy on November 13, 2015, 07:15:33 PM
Been tryin to change the damn footer alnight to get it to line up with SMF's....could you tell me where I might find it, lol.


/me pulls a bit more hair out.
Title: Re: ehportal help
Post by: Chen Zhen on November 13, 2015, 09:10:33 PM

Newer version released in the downloads:
http://web-develop.ca/index.php?action=downloads;sa=view;down=3

I included you in the beta tester list for the mod since that is what you have been doing.
If you want your name removed from it just let me know.
Title: Re: ehportal help
Post by: bigguy on November 13, 2015, 09:27:47 PM
Well, thank you very much. That was very cool of you man. You can leave it there if ya like. :) I'll install this new version either tonight or tomorrow....probably tonight, lol. There's somethin about buildin a new site, ya gotta love it. Thanks again guys for sure.
Title: Re: ehportal help
Post by: bigguy on November 13, 2015, 09:31:40 PM
Lmao....just uninstalled and reinstalled that quick. Not one error, lol. copyright looks great. I'll check things out now. :) That's awesome.


You have an error in your redirect text. It shows only html or php
Title: Re: ehportal help
Post by: Chen Zhen on November 13, 2015, 09:43:30 PM
It's something that was changed in the install routine of SMF itself that does not allow html tags.
The devs also did this in one of the more recent releases of the SMF 2.0.X branch.
I will change it to bbcode to see if it works else I will ask the SMF devs if this is done purposely.
I also noticed the install template has a width issue when uninstalling mods which imo could be a SMF 2.1 bug.
Title: Re: ehportal help
Post by: bigguy on November 13, 2015, 10:07:54 PM
I'll keep my eye out for, well, anything I notice and report back. I think html for use in spots like that was taken out of a lot of places. This could be any error though, not sure. You used to be able to use it in board titles and catagories and such. I don't think in 2.1 you can do any of that which could have effected redirect text as well I guess.
Title: Re: ehportal help
Post by: Chen Zhen on November 13, 2015, 10:11:02 PM

It should at least allow bbcode but it does not.
I am going to look over some past posts & documentation about this subject prior to asking about it.
Title: Re: ehportal help
Post by: Chen Zhen on November 14, 2015, 07:28:08 PM

Perhaps they have security in mind for not allowing HTML tags wthin the package parser.
BBCode is more controlled although it is a little restrictive at least it will add a bit more flexability for the display text.
I have submitted a pull request concerning this matter:
ref. https://github.com/SimpleMachines/SMF2.1/pull/3127
We will see if they accept it or not.
Title: Re: ehportal help
Post by: bigguy on November 15, 2015, 08:28:24 PM
I think it's a good idea and I don't see why they wouldn't allow bbc.

One more thing I noticed. The news fader on the portal does not do quotes well "" . This is from my portal, it is supposed to say "Site News"

Check out the "Site News" board for more info on whats going on with the site.
Title: Re: ehportal help
Post by: Chen Zhen on November 15, 2015, 11:44:16 PM

Thanks for the report.
I fixed the news fader text with a silent update in the download section.
http://web-develop.ca/index.php?action=downloads;sa=view;down=3
Title: Re: ehportal help
Post by: bigguy on November 16, 2015, 12:06:19 AM
Cool, glad that's fixed. I will update soon...maybe tomorrow. Vodka is going down nice tonight, lol. ;)
Title: Re: ehportal help
Post by: Chen Zhen on November 17, 2015, 07:28:24 PM

Did this work for you?
It works when I test it but I noticed you changed the quotes to: ...
Title: Re: ehportal help
Post by: bigguy on November 19, 2015, 11:35:08 PM
Quotes don't work still. Not sure why....no errors in the logs.
Title: Re: ehportal help
Post by: Chen Zhen on November 20, 2015, 11:56:10 AM
Try what is posted in the downloads once more.
It should work.. I tried it on 2 test sites with quotes in some news items.
If it does not work please report it and perhaps put in quotes the exact item you attempted for news that failed.
Bullets now work for news items if enabled (general block settings ~ News) & the amount of items is more than one.

Unfortunately applying 2 News blocks on 1 page causes malfuntions except in the last one displayed on the page.
Not that anyone would do this but I used block id's for the containers yet it still behaves this way.. working on that part for now.

Also the BBCode within redirect text at SMF 2.1 has been accepted therefore that display will show properly for the latest GitHub version.
Title: Re: ehportal help
Post by: bigguy on November 23, 2015, 06:35:31 PM
I will try it soon, possibly tonight. Just got home from work not to long ago.
Title: Re: ehportal help
Post by: Chen Zhen on November 23, 2015, 07:41:22 PM

You work in the Sifto mine right?
What do you do there, drive machinery?
Title: Re: ehportal help
Post by: GeorG on November 24, 2015, 07:07:34 AM
When you install the error:
Parse error: syntax error, unexpected '&&' (T_BOOLEAN_AND), expecting ')' in *\*\*\Sources\PortalBlocks.php on line 1623

Fix ../Sources/PortalBlocks.php

Code (find) Select
', (!empty($bullets && count($context['news_lines']) > 1) ? '
$("a").filter(function(){
var myId = this.id.match(/sp_news_nav_' . $id . '_*/);
return myId;
}).removeClass("sp-active").addClass("sp-inactive");
document.getElementById("sp_news_nav_' . $id . '_" + ct).className = "sp-active";
$("div#' . $blockId . '").css("padding-bottom", "1%");
' : ''), '


Code (replace) Select
', (!empty($bullets) && count($context['news_lines']) > 1) ? '
$("a").filter(function(){
var myId = this.id.match(/sp_news_nav_' . $id . '_*/);
return myId;
}).removeClass("sp-active").addClass("sp-inactive");
document.getElementById("sp_news_nav_' . $id . '_" + ct).className = "sp-active";
$("div#' . $blockId . '").css("padding-bottom", "1%");
' : '', '
Title: Re: ehportal help
Post by: bigguy on November 24, 2015, 06:20:29 PM
Quote from: Chen Zhen on November 23, 2015, 07:41:22 PM

You work in the Sifto mine right?
What do you do there, drive machinery?

No, but most of the people I know do. I was down there on a tour of the mine. I have a lot more pics that will be going up. I found it amazing that it was all solid salt....no rock anywhere down there....like no where man, lol. It's nuts down there. It's about as far down as the CN Tower is high. It goes about 4 kilometers out under lake Huron.
Title: Re: ehportal help
Post by: Chen Zhen on November 24, 2015, 06:49:56 PM
If I lived closer I would probably apply for a job.
I am getting laid off in about a year's time from a job I have had for 20 years!
T.O. is a little far from that mine though..  :-\

GeorG,

  Thanks for the report. I actually fixed it prior but must have forgotten to save the edited package & re-uploaded the wrong zip file in error.
It has now been fixed.
Title: Re: ehportal help
Post by: bigguy on November 24, 2015, 10:34:10 PM
I tell ya, it would be a great job. A lot of salt floatin around in the air though. I mean after 2 hours down there you can really taste it on your lips. I have a bother-in-law that works there and so does my neigbhor. I will post more pics soon.

On to other things though. I created a page in ehportal and I got an error. Some undefined index for page_info on line 103 or something of subs-portal.php. Here is the code in that section and what I did to clear the error:

Original code:
    // Some variables for ease.
    $action = !empty($context['current_action']) ? $context['current_action'] : '';
    $sub_action = !empty($context['current_subaction']) ? $context['current_subaction'] : '';
    $board = !empty($context['current_board']) ? 'b' . $context['current_board'] : '';
    $topic = !empty($context['current_topic']) ? 't' . $context['current_topic'] : '';
    $page = !empty($_REQUEST['page']) ? 'p' . $page_info['id'] : '';
    $portal = (empty($action) && empty($sub_action) && empty($board) && empty($topic) && SMF != 'SSI' && $modSettings['sp_portal_mode'] == 1) || $action == 'portal' || !empty($context['standalone']) ? true : false;



I changed the one line from page to page_info

    // Some variables for ease.
    $action = !empty($context['current_action']) ? $context['current_action'] : '';
    $sub_action = !empty($context['current_subaction']) ? $context['current_subaction'] : '';
    $board = !empty($context['current_board']) ? 'b' . $context['current_board'] : '';
    $topic = !empty($context['current_topic']) ? 't' . $context['current_topic'] : '';
    $page = !empty($_REQUEST['page_info']) ? 'p' . $page_info['id'] : '';
    $portal = (empty($action) && empty($sub_action) && empty($board) && empty($topic) && SMF != 'SSI' && $modSettings['sp_portal_mode'] == 1) || $action == 'portal' || !empty($context['standalone']) ? true : false;


Title: Re: ehportal help
Post by: Chen Zhen on November 24, 2015, 10:56:53 PM
No that will not work properly.
The issue is that it needs to check if the $_REQUEST variable is empty first.
To do that it needs to be in brackets.

Like this...

// Some variables for ease.
$action = (!empty($context['current_action'])) ? $context['current_action'] : '';
$sub_action = (!empty($context['current_subaction'])) ? $context['current_subaction'] : '';
$board = (!empty($context['current_board'])) ? 'b' . $context['current_board'] : '';
$topic = (!empty($context['current_topic'])) ? 't' . $context['current_topic'] : '';
$page = (!empty($_REQUEST['page'])) ? 'p' . $page_info['id'] : '';
$portal = (empty($action) && empty($sub_action) && empty($board) && empty($topic) && SMF != 'SSI' && $modSettings['sp_portal_mode'] == 1) || $action == 'portal' || !empty($context['standalone']) ? true : false;


Also... your quotes within the news are not working because you have not updated to the latest on the download page.
All errors reported here have been adjusted as of this moment.

Thank you for the report.
Title: Re: ehportal help
Post by: bigguy on November 24, 2015, 11:03:29 PM
Awesome, ok I will update tomorrow for sure to the latest version. Nothing is throwing errors right now and the about page is working that I created so I will leave it alone til I update to the latest version.
Title: Re: ehportal help
Post by: Chen Zhen on November 24, 2015, 11:29:39 PM

Actually what I just posted was wrong and I should have taken a closer look prior to responding.
It's not the $_REQUEST variable that was throwing the error but rather the $page_info array because it is not defined at that point.
In fact it is not used at all in that specific function nor is the $page variable less that particular line.
You could just comment it out, delete it or assign the $page variable to the $_REQUEST['page'] value.



// Some variables for ease.
$action = !empty($context['current_action']) ? $context['current_action'] : '';
$sub_action = !empty($context['current_subaction']) ? $context['current_subaction'] : '';
$board = !empty($context['current_board']) ? 'b' . $context['current_board'] : '';
$topic = !empty($context['current_topic']) ? 't' . $context['current_topic'] : '';
$page = (!empty($_REQUEST['page'])) ? $_REQUEST['page'] : '';
$portal = (empty($action) && empty($sub_action) && empty($board) && empty($topic) && SMF != 'SSI' && $modSettings['sp_portal_mode'] == 1) || $action == 'portal' || !empty($context['standalone']) ? true : false;
Title: Re: ehportal help
Post by: bigguy on November 25, 2015, 04:57:21 PM
So what I did was fine then I guess. If there have been no further fixes then I will continue to hunt for bugs for now. I just downloaded the version that's in the downloads area.
Title: Re: ehportal help
Post by: Chen Zhen on November 25, 2015, 05:44:53 PM
After installing it anew please test quoted news items & then let me know if it works for you.
Thanks.
Title: Re: ehportal help
Post by: bigguy on November 25, 2015, 06:17:42 PM
I certainly will. :)
Title: Re: ehportal help
Post by: bigguy on December 03, 2015, 06:39:44 AM
I will probably be updating the site today seeing as I have no work today and not to much to do around the house so I have spare time....I hope. :)
Title: Re: ehportal help
Post by: Skhilled on December 05, 2015, 02:48:41 PM
Hopefully, I'll get a little extra time soon to help test this.

Hey bigguy!
Title: Re: ehportal help
Post by: bigguy on December 15, 2015, 04:35:02 PM
I will be testing soon. Was waiting for something else to be updated but I don't wanna wait any longer. Has there been any other changes in the package since I downloaded it that day. ??
Title: Re: ehportal help
Post by: bigguy on December 16, 2015, 07:00:31 PM
Ok, I have installed the latest version and am hunting for bugs as we speak...type...talk, lol whatever. :)
Title: Re: ehportal help
Post by: bigguy on December 16, 2015, 07:11:35 PM
See sqreenshot. The copyright is a bit off or something. It was perfect on the last version.
Title: Re: ehportal help
Post by: bigguy on December 16, 2015, 07:29:59 PM
When using articles on the front page if you choose a message icon for your post. It does not show for the article on the front page. I will leave it for now so you can see how it looks.
Title: Re: ehportal help
Post by: Chen Zhen on December 16, 2015, 11:56:09 PM

The copyright was already off with the last version you tested but you did not notice it.
It is the page load time that is off a bit.. I will have to test if it does that compared to the SMF copyright when EhPortal is not installed.

With SMF 2.1 they changed a lot of icons to png and some to sprites.
Keep in mind that within their main package they have an optional icons folder that needs to be copied to the default images directory.
However, this does not have anything to do with the ../images/post directory which you just pointed out.

For now, open the file: ../Sources/PortalArticles.php .. and replace the 2 occurences of .gif with .png
Title: Re: ehportal help
Post by: bigguy on December 17, 2015, 12:25:54 AM
I checked PortalArticles.php and the template file for errors and it never dawned on me that is was just the file extension. That works now, lol. As for the copyright. I'm pretty sure it was aligned perfect before. I could be wrong but it looked good. Page load for me is like 0.14 or something like that.
Title: Re: ehportal help
Post by: bigguy on December 17, 2015, 12:27:18 AM
One more thing...the news fader is to fat, lol. What I mean is it's height does not match the news fader on the forum.
Title: Re: ehportal help
Post by: Chen Zhen on December 24, 2015, 01:02:04 AM

My apologies for not responding sooner as it has been a very busy week for me.
I will adjust the default height for the news block.
Keep in mind that you can also manually adjust the body style in the block code settings.
This will allow you to set your own custom height if you wish.
Title: Re: ehportal help
Post by: bigguy on December 24, 2015, 11:43:55 AM
Hey we're all busy these days...this close to Christmas. :) No problem at all. Yeah I know I can but I figured this was a tiny bug of some sort so I wanted to post about it.
Title: Re: ehportal help
Post by: bigguy on January 03, 2016, 05:16:56 PM
I just tried to manually adjust the height and the text dissapears. So I guess it can not be done with that.
EhPortal 1.39.6 © 2024, WebDev