Jump to content

Recommended Posts

Posted (edited)

Hi Everyone,

 

I hope I am in the correct forum for this topic. I am trying to install phpbb album (http://www.phpbbhacks.com/download/1060) for my forums. I have no experience with SQL and very little with anything else really. I followed the install directions carefully and double-checked everything. I am not sure how to make the SQL modifications.

 

I went into the "MySQL Databases" area in cPanel and manually added the tables mentioned in the instructions, but I'm not sure I did it correctly. I don't know how to access the entire database without going through the interface in cPanel. I was also unable to add additional values to the phpbb_album_config table because I simply don't know how. :(

 

Anyway, everything looks fairly good in the admin control panel for my forum, but when I actually click on the Album link on my forum page (http://www.historique.net//cheval/album.php) I get this error message:

 

Could not query recent pics information

 

DEBUG MODE

 

SQL Error : 1064 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 '' at line 10

 

SELECT p.pic_id, p.pic_title, p.pic_desc, p.pic_user_id, p.pic_user_ip, p.pic_username, p.pic_time, p.pic_cat_id, p.pic_view_count, u.user_id, u.username, r.rate_pic_id, AVG(r.rate_point) AS rating, COUNT(DISTINCT c.comment_id) AS comments FROM phpbb_album AS p LEFT JOIN phpbb_users AS u ON p.pic_user_id = u.user_id LEFT JOIN phpbb_album_cat AS ct ON p.pic_cat_id = ct.cat_id LEFT JOIN phpbb_album_rate AS r ON p.pic_id = r.rate_pic_id LEFT JOIN phpbb_album_comment AS c ON p.pic_id = c.comment_pic_id WHERE p.pic_cat_id IN (1,2) AND ( p.pic_approval = 1 OR ct.cat_approval = 0 ) GROUP BY p.pic_id ORDER BY p.pic_time DESC LIMIT

 

Line : 259

File : /home/cheval/public_html/cheval/album.php

 

This is what I created using the interface in cPanel. I'm not sure that I got all the perameters right, though since I couldn't cut-and-paste.

 

CREATE TABLE phpbb_album (

pic_id int(11) UNSIGNED NOT NULL auto_increment,

pic_filename varchar(255) NOT NULL,

pic_thumbnail varchar(255),

pic_title varchar(255) NOT NULL,

pic_desc text,

pic_user_id mediumint(8) NOT NULL,

pic_username varchar(32),

pic_user_ip char(8) NOT NULL DEFAULT '0',

pic_time int(11) UNSIGNED NOT NULL,

pic_cat_id mediumint(8) UNSIGNED NOT NULL DEFAULT '1',

pic_view_count int(11) UNSIGNED NOT NULL DEFAULT '0',

pic_lock tinyint(3) NOT NULL DEFAULT '0',

pic_approval tinyint(3) NOT NULL DEFAULT '1',

PRIMARY KEY (pic_id),

KEY pic_cat_id (pic_cat_id),

KEY pic_user_id (pic_user_id),

KEY pic_time (pic_time));

 

CREATE TABLE phpbb_album_rate (

rate_pic_id int(11) UNSIGNED NOT NULL,

rate_user_id mediumint(8) NOT NULL,

rate_user_ip char(8) NOT NULL,

rate_point tinyint(3) UNSIGNED NOT NULL,

KEY rate_pic_id (rate_pic_id),

KEY rate_user_id (rate_user_id),

KEY rate_user_ip (rate_user_ip),

KEY rate_point (rate_point));

 

CREATE TABLE phpbb_album_comment (

comment_id int(11) UNSIGNED NOT NULL auto_increment,

comment_pic_id int(11) UNSIGNED NOT NULL,

comment_user_id mediumint(8) NOT NULL,

comment_username varchar(32),

comment_user_ip char(8) NOT NULL,

comment_time int(11) UNSIGNED NOT NULL,

comment_text TEXT,

comment_edit_time int(11) UNSIGNED,

comment_edit_count smallint(5) UNSIGNED NOT NULL DEFAULT '0',

comment_edit_user_id mediumint(8),

PRIMARY KEY(comment_id),

KEY comment_pic_id (comment_pic_id),

KEY comment_user_id (comment_user_id),

KEY comment_user_ip (comment_user_ip),

KEY comment_time (comment_time));

 

CREATE TABLE phpbb_album_cat (

cat_id mediumint(8) UNSIGNED NOT NULL auto_increment,

cat_title varchar(255) NOT NULL,

cat_desc text,

cat_order mediumint(8) NOT NULL,

cat_view_level tinyint(3) NOT NULL DEFAULT '-1',

cat_upload_level tinyint(3) NOT NULL DEFAULT '0',

cat_rate_level tinyint(3) NOT NULL DEFAULT '0',

cat_comment_level tinyint(3) NOT NULL DEFAULT '0',

cat_edit_level tinyint(3) NOT NULL DEFAULT '0',

cat_delete_level tinyint(3) NOT NULL DEFAULT '2',

cat_view_groups varchar(255),

cat_upload_groups varchar(255),

cat_rate_groups varchar(255),

cat_comment_groups varchar(255),

cat_edit_groups varchar(255),

cat_delete_groups varchar(255),

cat_moderator_groups varchar(255),

cat_approval tinyint(3) NOT NULL DEFAULT '0',

PRIMARY KEY (cat_id),

KEY cat_order (cat_order));

 

CREATE TABLE phpbb_album_config (

config_name varchar(255) NOT NULL,

config_value varchar(255) NOT NULL,

PRIMARY KEY (config_name));

 

INSERT INTO phpbb_album_config VALUES ('max_pics', '1024');

INSERT INTO phpbb_album_config VALUES ('user_pics_limit', '50');

INSERT INTO phpbb_album_config VALUES ('mod_pics_limit', '250');

INSERT INTO phpbb_album_config VALUES ('max_file_size', '128000');

INSERT INTO phpbb_album_config VALUES ('max_width', '800');

INSERT INTO phpbb_album_config VALUES ('max_height', '600');

INSERT INTO phpbb_album_config VALUES ('rows_per_page', '3');

INSERT INTO phpbb_album_config VALUES ('cols_per_page', '4');

INSERT INTO phpbb_album_config VALUES ('fullpic_popup', '1');

INSERT INTO phpbb_album_config VALUES ('thumbnail_quality', '50');

INSERT INTO phpbb_album_config VALUES ('thumbnail_size', '125');

INSERT INTO phpbb_album_config VALUES ('thumbnail_cache', '1');

INSERT INTO phpbb_album_config VALUES ('sort_method', 'pic_time');

INSERT INTO phpbb_album_config VALUES ('sort_order', 'DESC');

INSERT INTO phpbb_album_config VALUES ('jpg_allowed', '1');

INSERT INTO phpbb_album_config VALUES ('png_allowed', '1');

INSERT INTO phpbb_album_config VALUES ('gif_allowed', '0');

INSERT INTO phpbb_album_config VALUES ('desc_length', '512');

INSERT INTO phpbb_album_config VALUES ('hotlink_prevent', '0');

INSERT INTO phpbb_album_config VALUES ('hotlink_allowed', 'smartor.is-root.com');

INSERT INTO phpbb_album_config VALUES ('personal_gallery', '0');

INSERT INTO phpbb_album_config VALUES ('personal_gallery_private', '0');

INSERT INTO phpbb_album_config VALUES ('personal_gallery_limit', '10');

INSERT INTO phpbb_album_config VALUES ('personal_gallery_view', '-1');

INSERT INTO phpbb_album_config VALUES ('rate', '1');

INSERT INTO phpbb_album_config VALUES ('rate_scale', '10');

INSERT INTO phpbb_album_config VALUES ('comment', '1');

INSERT INTO phpbb_album_config VALUES ('gd_version', '2');

INSERT INTO phpbb_album_config VALUES ('album_version', '.0.54');

Edited by buggurl
Posted

The database should have your username_ on the front of it.

 

Try creating;

 

cpanelusername_phpbb_album

 

And then putting the data into that, and using the full database name in the config file.

Posted

Thank you for your suggestions. phpbb_album is acutally just a table in my existing database that does in fact have my username in front of it.

 

Is there a way to go into the database and edit the code without using the cPanel MySQL database interface?

Posted

Hello,

 

Can i please suggest something different?

 

The album you are about to load, is Smartors album, which can actually be found here:

 

http://smartor.is-root.com/

 

However, there are many upgrades and new bits added to it, and for some while, Smartor has not really done much to it (to be honest, it doesnt really need anything doing to it)

 

However, some guy has taken this further, and with Smartors permission, added everything together, as well as updating a few things which are now hard to get hold of (the important super service pack for one).

 

The original post was here:

 

http://smartor.is-root.com/viewtopic.php?t=15886

 

And the website for this Full Album pack (FAP) is here:

 

http://www.area69.phphost.info/

 

I suggest you download that and use that instead, its much easier, and is continously updated. It used to be my album of choice before I moved away from phpBB about 6 weeks ago.

 

Let me know how it goes

 

JimE

Posted

Wow! :tchrocks: Thanks for the suggestion! I installed everything and it's working...so far. :) I'll post an update after I work with it for a while. I have one error so far, but I don't know how bad it is.

 

One part in the instructions was not clear to me. I don't know where this "Admin CP" file is.

 

#-----[ DIY INSTRUCTIONS ]------------------------------------

#

CHMOD these directories for Full Album Pack to work correctly.

.

CHMOD 777 album_mod/upload

CHMOD 777 album_mod/upload/cache

CHMOD 777 album_mod/upload/med_cache

CHMOD 777 album_mod/upload/otf

CHMOD 777 album_mod/upload/wm_cache

.

Change "Path to cgi-in" in Admin CP to a relative path from phpBB root to your cgi-bin

Create folder: cgi-bin/tmp/

CHMOD 777 cgi-bin/tmp/

CHMOD 755 cgi-bin/nuffload.cgi

Posted

Hello,

 

Your Admin CP is also know as "Administrator Control Panel". The area where you go when you click "Administrator" at the bottom or top of the forum (depending on where that link is).

 

Now if you scroll down the side until you reach the album area. Then in one of the sub menus off this, will be the nuffload area which you can change the path to the CGI script.

 

Glad its working well!

 

JimE

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...