TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

March 29, 2024, 09:25:42 AM

Login with username, password and session length
Members
Stats
  • Total Posts: 195,106
  • Total Topics: 21,213
  • Online today: 358
  • Online ever: 3,540 (September 03, 2022, 01:38:54 AM)
Users Online
  • Users: 0
  • Guests: 87
  • Total: 87

Error trying to use download manager

Started by jarrodavisoftware, February 20, 2009, 10:50:51 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

jarrodavisoftware

When I try to use the download manager in any way, I get this error. This is a new install.

Link to my site: http://pyrogine.jarrodavisoftware.com
SMF version: 1.1.8
TP version: 1.0 beta3
Theme name and version: default
Mods installed: TP | media gallery
Related Error messages: Fatal error: Cannot redeclare tpdownload() (previously declared in /home/jarrodav/public_html/pyrogine/Sources/TPmodules.php:2055) in /home/jarrodav/public_html/pyrogine/Sources/TPdlmanager.php on line 1517

G6Cad

This error probably generates because of a bad update from an earlier version of TP ? = duplocate code in some or more files.

Check the manual install instructions and follow the steps and make sure the code and files are there and are correct.

How do I manually install TinyPortal

Modification Instructions

jarrodavisoftware

Hi, thanks for the reply. Ok, I will check over everything. Thanks again.

jarrodavisoftware

hmm...

1. cleaned the install folder
2. cleaned the database
3. manually installed smf 1.1.8
4. install tp beta 3
5. click on download, and I get the same error
6. out of frustration, uninstalled beta3 (via pkg mgr) and I installed beta 2 and it
works as expected.

Note: the beta3 install was not an upgrade. I created the subdomain, installed smf + beta 3 fresh all today.

Renegd98

Did you manually install TP Beta 3 or just manually install SMF? You should of manually installed TP Beta 3.

jarrodavisoftware

Yes, I tried the manual install.

Looking at the sources, function tpdownload($memID) is define in TPmodules.php and there is function TPdownload() defined in TPdlmanager.php. This is not the case in beta 2. I'm just getting my feet wet with PHP, is it  a case sensitive language, if so then this should not be a problem I guess, but if it is then... I don't know is why I'm asking.

i renamed tpdownload($memID) to tpdownload1($memID) and all the calls in the file it was located in. Now, when I click on download it works as expected. What I'm not sure about yet is if tpdownload in TPmodules.php is being called any other place.


Renegd98

This is the first I have heard of this problem as TP Beta 3 works fine for me on many sites.  I am thinking you may have some left over files from a different TP install.

Xarcell

Normally a redeclare is a duplication of code in the package manager installation or something done manually.

Can you be a little more specific with what your doing to cause the error? I visited the link and didn't have any problems browsing the downloads.



Xarcell

As Renegd98 says, that could be the case too.

jarrodavisoftware

Hi guys, thanks for the reply and info. Well, this is the thing:

1. jarrodavisoftware.com and the subdomain pyrogine, got created today on a brand new dedicated server, so there has never been any thing left over from a previous install.

2. I created this domain in whm, created the subdomain in cpanel, so at this point, fresh site install with empty directory listing. I created the database from cpanel

3. I uploaded and extracted sfm 1.1.8 via the file manager in cpanel and ran the installer and it installed.

4. I then went to the package manager, installed tpb3 by selecting it from my local HD and it installed without any visible issues.

5. So now I have a default smf+tp installation. Note, I've not changed any settings at the moment.

6. I go to frontpage, click on [download] in the sitemape section and bam, I get that redeclaration error.

7. It (seems to be) working now (I can use all the functionality) because I renamed one of the tpdownload functions and that seem to solve the problem for me. I'm a software developer so I naturally jumped in and started looking at the code is why I was asking if php is a case sensitive language. I have this  >.< much experience with php (only coded a few basic plugins for Joomla) so I really do not know a great deal about it. I know I almost went nuts with the same type of error when coding that joomla plugin so I've seen it before.

The fact that Renegd98 has tpb3 running then means something is going on with my server. Maybe the php.ini settings needs to be tweaked. I can only set file permission to 755 because of the security mod (I forget the name, suec something), but I didn't notice any visible permission related issues. So at this point I'm clueless and so far there seems to be no other people that has reported this problem.

Some facts:
1. new server, new domain, it never had smf and tp on it.
2. smf 1.1.8 installs and run ok
3. tpb2 installs and run ok
4. tpb3 does not
5. tpb2 dos not seem to have those two functions with the same name
6. for tpb3 I renamed one of them and now it seems to work ok for me.