Two possible bugs in 1.3.7

a complete banner management system, any number of banners can be added
Forum rules
The content in this forum is dated Dec. 21 2005 and can be used as Archive only. This Forum is LOCKED and READ ONLY !

Two possible bugs in 1.3.7

Postby mosor on Mon 31. Jan, 2005 12:43

I'm running phpBB 2.0.11, with Easymod 0.1.13 being the only mod installed on it. Installing Complete banner goes well (ofcourse, using EM), but the trouble begins when adding my first banner.

First of all, I get this error message:

Code: Select all
Couldn't update/insert into banners table

DEBUG MODE

SQL Error : 1064 You have an error in your SQL syntax near ''122','55','0','600','50')' at line 2

INSERT INTO phpbb_banner (banner_id, banner_name, banner_active, banner_spot, banner_description, banner_url, banner_click, banner_view, banner_owner, banner_level, banner_level_type, banner_timetype, time_begin, time_end, date_begin, date_end, banner_comment, banner_type, banner_width, banner_height, banner_filter, banner_filter_time,banner_weigth) VALUES ('1','http://forum.teretana.net/images/banners/scitec.jpg', '1', '0', 'SciTec', 'http://www.scitecnutrition.com/', '0', '0', '2', '-1', '2', '0', '0', '0', '0', '0', 'Sc','0',o'122','55','0','600','50')

Line : 1231
File : /home/users/mosor/forum.teretana.net/htdocs/admin/admin_banner.php


After manualy updating the MySQL table and fixing that error the banner finaly showes. But, when trying to edit this banner's properties I can't set any reasonable "Images size". For example, I input 550x60, but instead of that I get 550x550. Again, manualy alterin MySQL tables gets the job done, but that's not the way I want it to work.

Any ideas?
mosor
Poster
Poster
 
Posts: 4
Joined: Wed 26. Jan, 2005 21:51

Postby rew2 on Mon 31. Jan, 2005 18:16

i delete from admin_banner.php line 610 this
Code: Select all
ř
and al is ok but i have this same problem if i have edit this baner :cry:
rew2
Poster
Poster
 
Posts: 6
Joined: Wed 07. Jan, 2004 02:41
Location: Warsaw Poland

Postby mosor on Mon 31. Jan, 2005 18:46

rew2 wrote:i delete from admin_banner.php line 610 this
Code: Select all
ř
and al is ok but i have this same problem if i have edit this baner :cry:


Fixed line 610, now I can at least add new banners without messing with MySQL console. But banner resizeing is still a problem...
mosor
Poster
Poster
 
Posts: 4
Joined: Wed 26. Jan, 2005 21:51

Postby rew2 on Mon 31. Jan, 2005 19:00

i change in sql this

Code: Select all
banner_height  mediumint(5)    UNSIGNED Nie  50
and
banner_width  mediumint(5)    UNSIGNED Nie  400


but this is on hard :(
rew2
Poster
Poster
 
Posts: 6
Joined: Wed 07. Jan, 2004 02:41
Location: Warsaw Poland

Postby ario on Sat 05. Feb, 2005 00:42

where do i go to change it in the mysql???
ario
Poster
Poster
 
Posts: 2
Joined: Sat 04. Oct, 2003 23:05

Postby darakhshan on Mon 21. Feb, 2005 20:22

mosor wrote:
rew2 wrote:i delete from admin_banner.php line 610 this
Code: Select all
ř
and al is ok but i have this same problem if i have edit this baner :cry:


Fixed line 610, now I can at least add new banners without messing with MySQL console. But banner resizeing is still a problem...


I hate this all, I can not find
Code: Select all
ř

what kind of font is this?
My 610 line looks like this
Code: Select all
   VALUES ('$banner_id','" . str_replace("\'", "''", $banner_name) . "', '$banner_active', '$banner_spot', '" . str_replace("\'", "''", $banner_description) . "', '" . str_replace("\'", "''", $banner_url) . "', '$banner_click', '$banner_view', '".$owner['user_id']."', '$banner_level', '$banner_level_type', '$time_type', '$time_begin', '$time_end', '$date_begin', '$date_end', '" . str_replace("\'", "''", $banner_comment) . "','$banner_type',?" . str_replace("\'", "''", $banner_width) . "','" . str_replace("\'", "''",
darakhshan
Poster
Poster
 
Posts: 46
Joined: Sat 15. May, 2004 12:19

Postby M. W. I. Prod. on Wed 23. Feb, 2005 01:48

Your code seems OK :)
M. W. I. Prod.
Poster
Poster
 
Posts: 2
Joined: Sun 23. Nov, 2003 09:49

Postby tikilab on Wed 02. Mar, 2005 15:26

The error is seemingly a typo in admin_banner.php, which is included with the mod.

Around Line 610, change this:

Code: Select all
VALUES ('$banner_id','" . str_replace("\'", "''", $banner_name) . "', '$banner_active', '$banner_spot', '" . str_replace("\'", "''", $banner_description) . "', '" . str_replace("\'", "''", $banner_url) . "', '$banner_click', '$banner_view', '".$owner['user_id']."', '$banner_level', '$banner_level_type', '$time_type', '$time_begin', '$time_end', '$date_begin', '$date_end', '" . str_replace("\'", "''", $banner_comment) . "','$banner_type',¯'" . str_replace("\'", "''", $banner_width) . "','" . str_replace("\'", "''",
$banner_height) . "','$banner_filter','$banner_filter_time','$banner_weigth')";


to this:

Code: Select all
VALUES ('$banner_id','" . str_replace("\'", "''", $banner_name) . "', '$banner_active', '$banner_spot', '" . str_replace("\'", "''", $banner_description) . "', '" . str_replace("\'", "''", $banner_url) . "', '$banner_click', '$banner_view', '".$owner['user_id']."', '$banner_level', '$banner_level_type', '$time_type', '$time_begin', '$time_end', '$date_begin', '$date_end', '" . str_replace("\'", "''", $banner_comment) . "','$banner_type', '" . str_replace("\'", "''", $banner_width) . "','" . str_replace("\'", "''",
$banner_height) . "','$banner_filter','$banner_filter_time','$banner_weigth')";


Note only one character is changed, a little after "banner_type". This:

Code: Select all
¯


was changed to a space.

I also noticed that in this file "banner_weight" is spelled "banner_weigth". Be sure you don't try and correct this anywhere (like I initially did - I thought it was a single typo, but then I looked closer and saw it was this way everywhere in the file - oops). As long as it's consistent throughout, it should work fine.

I still can't find what's causing the image size problem...
tikilab
Poster
Poster
 
Posts: 5
Joined: Sun 31. Oct, 2004 07:00
Location: Phoenix, Arizona, USA

Next

Return to Complete banner [2.0.6/EM]

Who is online

Users browsing this forum: No registered users and 1 guest

cron