These forums have been archived and are now read-only.

The new forums are live and can be found at https://forums.eveonline.com/

EVE Technology Lab

 
  • Topic is locked indefinitely.
 

phpBB 3.x API Registration Mod v6+

Author
Cyerus
University of Caille
Gallente Federation
#61 - 2011-11-03 00:19:39 UTC
JustSharkbait wrote:
I got the files and all put in the right places, and things from that end are working fine. However, i cannot figure out what to do with the sql files in that folder.

Where do they go?

Or do i have to upload those to mysql database?


Import all the SQL files manually into your database.
Your webhost should have a tool similar to phpMyAdmin somewhere, which can help out greatly (import functionality).
Simon Victor
The Hornet's Nest
#62 - 2011-11-03 06:41:34 UTC  |  Edited by: Simon Victor
Cyerus wrote:
Desas wrote:
First of all Great job Cyerus !

Simon Victor wrote:


  • Ability for the Cron job to ignore multiple forum and TS3 groups (not just the default ones, and one "special" group) or actually have it so it won't remove them from certain groups if they have valid API info, but it won't add them automatically to those groups.



Yeah thats indeed a pretty annoying feature. I have a transition period from apiv1 to apiv2 on our forums atm . As soon ppls update their api details they get removed from other groups .. even the special ones leaving them behind in the standard group.





That's a bug. A special group is supposed to be like that; You have to manually join it, and it should not disappear when running the cronjob. I think this peace of code got lost somewhere in the transition, and I have to admit that I didn't check that.

Will deploy fix in v5.1

Also, I will make an install guide whenever I have the chance; probably this weekend, busy week =/



Awesome! I just want you to know that I've been ripping this mod apart looking at the code and such, and although I'm not any genius in the field of PHP I can tell that you've done a great job. I appreciate your work, and once I have ISK again I will certainly make a donation for your time :)

Thanks again!

And just a tip: For anyone having issues with avatars not downloading or showing up in threads, you will need to have the members who are having problems delete current (even if it says they have none) and re-download avatar. Took me awhile to figure that out. It was happening for the people who were already members of the forums with previous avatars. I tried to edit those members' avatars from the ACP, but that function didn't work for some reason so they have to do it themselves.

Cyerus wrote:
JustSharkbait wrote:
I got the files and all put in the right places, and things from that end are working fine. However, i cannot figure out what to do with the sql files in that folder.

Where do they go?

Or do i have to upload those to mysql database?


Import all the SQL files manually into your database.
Your webhost should have a tool similar to phpMyAdmin somewhere, which can help out greatly (import functionality).


I can help him out Cyerus. JustSharkbait, just send me a mail if you have any additional questions. I was a PHP newbie once (probably still am), but I can help you out. Let me know if you're having further issues.

Arguing with strangers on the internet is a sucker's game because they inevitably turn out to be, or are indistinguishable from, self-righteous sixteen-year-olds possessing infinite amounts of free time.

JustSharkbait
University of Caille
Gallente Federation
#63 - 2011-11-03 07:08:19 UTC  |  Edited by: JustSharkbait
Thanks for your help. I do have PHPmyadmin. I will upload the files. I will let you know if i have any further trouble.

Hoo Ha Ha!!

Simon Victor
The Hornet's Nest
#64 - 2011-11-03 09:11:24 UTC
Cyrerus, can you tell me real quick how to make the cron job ignore group id's? I just suspended it for now. I think it's important to run it, but it's just been too annoying with removing people from my own admin groups. Thanks!

Arguing with strangers on the internet is a sucker's game because they inevitably turn out to be, or are indistinguishable from, self-righteous sixteen-year-olds possessing infinite amounts of free time.

L0SER18q
My Little Pony Industries Inc.
RED.OverLord
#65 - 2011-11-03 10:32:37 UTC
Cyrerus, is it possible to relize next version in MODX format for easy update and installation?
Fredan
Doomheim
#66 - 2011-11-03 23:32:51 UTC
L0SER18q wrote:
Cyrerus, is it possible to relize next version in MODX format for easy update and installation?


IMO, it is better having the mod this way than in MODX, as as long as you do not want to install toons of mods to your board, you should be fine.....

Perhaps we could have this mod in the two variants or something like that?
L0SER18q
My Little Pony Industries Inc.
RED.OverLord
#67 - 2011-11-04 10:03:25 UTC  |  Edited by: L0SER18q
Fredan wrote:

IMO, it is better having the mod this way than in MODX, as as long as you do not want to install toons of mods to your board, you should be fine.....

Perhaps we could have this mod in the two variants or something like that?

Mods in MODX format automatically installed by AutoMod, imho it's simplest way. Why are any more variants?
Now impossible to install this mod if you already install any another mod, because installed mods would be broken. This distribution way only for fresh phpBB.
Fredan
Doomheim
#68 - 2011-11-04 15:24:36 UTC
L0SER18q wrote:
Fredan wrote:

IMO, it is better having the mod this way than in MODX, as as long as you do not want to install toons of mods to your board, you should be fine.....

Perhaps we could have this mod in the two variants or something like that?

Mods in MODX format automatically installed by AutoMod, imho it's simplest way. Why are any more variants?
Now impossible to install this mod if you already install any another mod, because installed mods would be broken. This distribution way only for fresh phpBB.


But then you are installing a file modifier script, which might be exploited opening security flaws which many admins do not want....
Noh Senz
Sebiestor Tribe
Minmatar Republic
#69 - 2011-11-05 15:29:28 UTC
Cyerus wrote:

1) Avatar resizing
It's not a bug, it's a feature. Let's assume you have the EVE Portrait Size selected to Medium (128x128), it will resize all Avatar pictures to 128x128. This is to ensure unity. The EVE Portraits are downloaded in 256x256 format, then resize to whatever you size you have set; this is to allow easy switching between sizes without having to redownload all the Portraits.

However, this feature can be disabled, but it requires some manual work.

  • Open pre_edit/includes/functions_display.php in notepad (I suggest Notepad++ if you don't mind installing it)
  • Scroll to the bottom, where you should see the following 5 lines:

Quote:
if ($config['eveapi_validation'] && $config['eveapi_portrait'])
{
$avatar_width = $config['eveapi_portrait_size'];
$avatar_height = $config['eveapi_portrait_size'];
}

  • Remove those 5 lines and save the file.
  • Upload the file and clear you forums cache.



Or force avatar's width to match config parameters, but keep original image ratio :
Quote:

if ($config['eveapi_validation'] && $config['eveapi_portrait'])
{
$avatar_ratio = $avatar_width / $avatar_height;
$avatar_width = $config['eveapi_portrait_size'];
$avatar_height = round($config['eveapi_portrait_size'] / $avatar_ratio);
}


Very good work by the way. I've selected your project amongst other similar components.
Too bad it has to be so intrusive into phpBB code though... oh well !
Cyerus
University of Caille
Gallente Federation
#70 - 2011-11-07 19:53:39 UTC  |  Edited by: Cyerus
v5.1 is released.

Here are the fixes:

  • Ignore errors from ini_set in eveapi_cron.php
  • AdminCP option to select if forum group should be set as default group
  • UserCP to hide TeamSpeak UID box whenever TeamSpeak 3 integration is disabled
  • AdminCP option to enable / disable avatar resizing to select EVE Portrait Size
  • Correctly ignoring "Special forumgroups" when running eveapi_cron.php
  • Extending "Special-groups" for both Forum and TeamSpeak to 5 each
  • Removing the ability to set default forumgroups (like Registered Users, Global Moderaters, Administrator, etc.) as selectable groups for EVE entities
  • Removing Mumble integration since it involves installing mods at webserver level, rather than using PHP files only.


Also, I will create a MODX file soonish, although I'm not sure if that will be compatible with AutoMOD.
Same for the script to update your forum when you are still using the old EVE API mod.

Link to the package can be found at the top.

'Likes' are appreciated.
Cyerus
University of Caille
Gallente Federation
#71 - 2011-11-08 12:04:39 UTC
I have updated the package to fix a small issue.
If you have already downloaded v5.1 prior to this message, you will need to download the package again.

Don''t forget to 'Clear Cache' and Remove / Reinstall the EVE API modules.
Furtran
#72 - 2011-11-08 19:22:24 UTC  |  Edited by: Furtran
mod: v5.1
file: acp_users.php
str: #951

find this: if ($config['evepi_validation'] && $update_keyId && $update_vCode)
replace with: if ($config['eveapi_validation'] && $update_keyId && $update_vCode)
Indigo Morchebe
Naranek Industries LLC
Goonswarm Federation
#73 - 2011-11-09 22:48:31 UTC  |  Edited by: Indigo Morchebe
Total noob question...

I have done the following:

FTPed the files to the right folders
imported the sql files (x3) using myphpadmin
followed the instructions in the first two posts
checked cURL is enabled
cleared cache

phpbb version 3.0.9 clean install
turned off Spam counter measures in ACP

Edit:

I have set Enable API validation ON
I have set Enable Corporation management ON with correct details



tried registering a new user but the reg seems to be not passing to the mod...

In the phpbb ACP - User registration settings which Account activation type do I choose?
Indigo Morchebe
Naranek Industries LLC
Goonswarm Federation
#74 - 2011-11-10 01:37:52 UTC
Well... some success

I am not sure which change helped but...

I downloaded the latest 5.1 files and reloaded them but also cleared the styles cache as well...

I am now getting the additional two api fields - however i now get this error when registering...




General Error

SQL ERROR [ mysqli ]

Unknown column 'eveapi_keyId' in 'field list' [1054]

An SQL error occurred while fetching this page.
Negativestatus
Caldari Provisions
Caldari State
#75 - 2011-11-10 04:47:57 UTC
Indigo Morchebe wrote:
Well... some success

I am not sure which change helped but...

I downloaded the latest 5.1 files and reloaded them but also cleared the styles cache as well...

I am now getting the additional two api fields - however i now get this error when registering...




General Error

SQL ERROR [ mysqli ]

Unknown column 'eveapi_keyId' in 'field list' [1054]

An SQL error occurred while fetching this page.


Did you import the SQL files into your database using PHPMYADMIN or mysql?
Indigo Morchebe
Naranek Industries LLC
Goonswarm Federation
#76 - 2011-11-10 21:08:09 UTC  |  Edited by: Indigo Morchebe
PHPMYADMIN

I had to re-import a few times as there was errors but eventually all three were successful

it would not kill me to start a new db for that matter.
Indigo Morchebe
Naranek Industries LLC
Goonswarm Federation
#77 - 2011-11-10 21:31:21 UTC
I did a search for field list within the db and looked through 12 tables but I didnt find the 'eveapi_keyId' Unknown column

Not being a db techie I will start with a clean db and do the import with mysql tools
Indigo Morchebe
Naranek Industries LLC
Goonswarm Federation
#78 - 2011-11-10 23:11:42 UTC  |  Edited by: Indigo Morchebe
Hmm...

Started from scratch and still get the same error. I have narrowed it down to the "default.sql" file import. I am getting an error on import


Error
SQL query:
ALTERTABLE phpbb_users ADDCOLUMN eveapi_keyId INTUNSIGNED NOTNULL DEFAULT0 AFTER user_reminded_time;
#1146 - Table 'mycorp_forum.phpbb_users' doesn't exist
Indigo Morchebe
Naranek Industries LLC
Goonswarm Federation
#79 - 2011-11-10 23:51:17 UTC  |  Edited by: Indigo Morchebe
Firstly my apologies for the running commentary

I have found the fault.

Installing a non standard phpbb was the cause...

phpbb install - Database settings - prefix for tables in database - "phpbb_"

and I have always put the following "phpbb_forums" so the tables in default didnt match. Come to think of it this would explain some other strange mod outcomes as well.

So the table mycorp_forum.phpbb_users definately didnt exist as it was called mycorp_forum.phpbb_forumsusers'
Zae'dra Xanthe
Republic Military School
Minmatar Republic
#80 - 2011-11-11 09:55:23 UTC
Any idea why I'm getting this when I try to enter my TeamSpeak server UID and hit submit?

Quote:
exception 'TeamSpeak3_Helper_Exception' with message 'invalid URI supplied' in /var/www/bb/web/forum/includes/eveapi/TeamSpeak3/Helper/Uri.php:133 Stack trace: #0 /var/www/bb/web/forum/includes/eveapi/TeamSpeak3/TeamSpeak3.php(287): TeamSpeak3_Helper_Uri->__construct('serverquery://b...') #1 /var/www/bb/web/forum/includes/eveapi/functions_eveapi.php(81): TeamSpeak3::factory('serverquery://b...') #2 /var/www/bb/web/forum/includes/acp/acp_users.php(973): eveapi_setTeamSpeakGroups('MKGNGTYVx0fD3wR...', Array, 'Khroam') #3 /var/www/bb/web/forum/includes/functions_module.php(507): acp_users->main('users', 'overview') #4 /var/www/bb/web/forum/adm/index.php(74): p_master->load_active() #5 {main}


Also, the TS reg doesn't seem to work. To clarify a few points:

1. TS server is on a different machine (does this matter?)
2. IP of the connecting server (where the forum is) is whitelisted
3. The MOD was installed on a fresh instance of phpBB3 3.0.9 with no other mods, however, data was imported from another phpBB3 forum (same version) with the old EVE API mod.
4. I'm also seeing this in my config panel (is this normal?) screenshotscreenshot
5. The drop-downs where I must select a group in any part of the MOD does not contain any pre-determined forum groups, only those that have been created manually.

I appreciate your attention! Thanks in advance!