Mysidia Adoptables Support Forum  

Home Community Mys-Script Creative Off-Topic
Go Back   Mysidia Adoptables Support Forum > Community Board > Mysidia Adoptables Official Announcement

Notices

Closed Thread
 
Thread Tools Display Modes
  #41  
Old 01-25-2014, 09:21 PM
squiggler's Avatar
squiggler squiggler is offline
Squiggling since 1995
 
Join Date: Jul 2013
Posts: 185
Gender: Unknown/Other
Credits: 8,102
squiggler is on a distinguished road
Default

(Not sure if I should have put this in Bugs, sorry?)
When you first adopt an adoptable, text tells you to make sure to feed your adoptable so it grows. The link is levelup/# instead of levelup/click/# so it doesn't work.

I changed adoptview.php from this:
$document->add(new Link("levelup/{$aid}", "feed "));
To this:
$document->add(new Link("levelup/click/{$aid}", "feed "));

The link now works. Just make sure you don't forget the / or it'll give you an error like the first one.

The file is in public_html > view.
__________________
Avatar courtesy of Doll Divine.
  #42  
Old 01-26-2014, 10:08 PM
Kyttias's Avatar
Kyttias Kyttias is offline
Premium Member
 
Join Date: Jan 2014
Posts: 857
Gender: Unknown/Other
Credits: 86,972
Kyttias is on a distinguished road
Default fresh install issues

Hi! Last year, I downloaded the script and gave it a test install and it worked great - but that was a different version. This version is giving me issues on a fresh install!

I have a brand new laptop, and I just downloaded a fresh install of WAMP (this release comes with PHP 5.4 with MySQL 5.6). Immediately I started having troubles. (But luckily nothing that will immediately prevent me from continuing on my way, I think.) I strongly believe all of this is caused because I have 5.4 and the temporary solution is to just turn off php error notices (everything seems to work, despite the notices).

Problem 1 - The index.php in the installer has the following notice at the top of the page:
PHP Code:
( ! ) NoticeUndefined indexstep in C:\wamp\www\Mysidia\install\index.php on line 5 
But I could proceed, anyway. Everything passed on the second page. Onto the third page-

Problem 2 - I had to set a password for myphpadmin root, no biggie, that's more secure than not having one, so I got that done. (It wouldn't let me run the install script without a password, anyway.) I attempted to run the install script now that I had a password...

Problem 3 - The install script went and timed out on me (warning sign number one) - so I went into my php.ini file and upped the script timeout from 30 seconds to 5 minutes, cleared the tables in the database it had managed to install, and tried again. Success! I got all the way to step six.

Problem 4 - Installation complete! But wait, there are four php notices at the top of the page:
PHP Code:
( ! ) NoticeUndefined indexrewardmoney in C:\wamp\www\Mysidia\install\sitesetting.php on line 29

( ! ) NoticeUndefined indexenabletrades in C:\wamp\www\Mysidia\install\sitesetting.php on line 30

( ! ) NoticeUndefined indextradecost in C:\wamp\www\Mysidia\install\sitesetting.php on line 31

( ! ) NoticeUndefined indextradeoffercost in C:\wamp\www\Mysidia\install\sitesetting.php on line 32 
Well, whatever, right? I clicked proceeded to click on 'View Your Website' and oh my goodness:

Problem 5 - The good news? The site does load... at the bottom of the page after several dozen notice errors. I get one of this:
PHP Code:
( ! ) NoticeUndefined variablecontroller in C:\wamp\www\Mysidia\classes\class_language.php on line 111 
And then about 54 of these, and they're all identical:
PHP Code:
( ! ) NoticeUndefined propertyDocumentRenderer::$thematicBreak in C:\wamp\www\Mysidia\classes\class_guirenderer.php on line 184 
I didn't bother including the callstack information that came with those specific notice, but I can if you like. Notice that they're just notices and not errors? That's a good thing, in that I can actually force PHP to not display notices on my server. (You can change the error_reporting setting in php.ini from error_reporting = E_ALL to error_reporting = E_ALL & ~E_NOTICE. And then it's important to restart the server so the changes can be activated.) However, these notices should be repaired before they become serious problems in future versions of PHP, right? (Currently, many web hosting providers may have these error notices turned off by default? But they also may not, leaving people unable to turn them off.)

PHP is one of those languages that's constantly upgrading and it's syntax gets a little outdated. Even best practices can become obsolete, given enough time. (e.g., Using an uninitialized variable and relying on the fact it's automatically initialized to an empty string.) As a developer, that sort of stuff makes you want to pull your hair out, I know.

(Oh!! I think it's worth mentioning that I also had the initial 500 Internal Server Error, but that was because mod_rewrite wasn't turned on by default in WAMP's Apache. I turned that on and restarted and everything seemed to have fixed itself.)

Anyway, moving along:

Problem 6 - On the Register page, this time I get an actual, non-notice error:
PHP Code:
( ! ) Strict standardsDeclaration of RadioList::add() should be compatible with GUIContainer::add(GUIComponent $component$index = -1in C:\wamp\www\Mysidia\classes\class_radiolist.php on line 68 
However, this seems irrelevant, as registration is successful anyway. It's noted that it says I am now logged in, but there is no ajax to automatically whisk away the login panel on the side (but this is obviously something you're probably working on fixing for the next major release, so its barely worth mentioning).

I'm not -sure- if I can turn Strict php error notices off, but I'll give it a shot. I look forward to your next major release but I'll have fun building off what's already provided. Thank you for your hard work!

Last edited by Kyttias; 01-27-2014 at 12:54 AM.
  #43  
Old 01-27-2014, 12:48 AM
Hall of Famer's Avatar
Hall of Famer Hall of Famer is offline
Administrator, Lead Coder
 
Join Date: Dec 2008
Location: South Brunswick
Posts: 4,448
Gender: Male
Credits: 327,496
Hall of Famer is on a distinguished road
Default

Well most of these aint really problems, especially the notices. All you have to do is to disable notice errors in php.ini. For the strict standard error, go to /classes/class_radiolist.php and change:

PHP Code:
public function add(){ 
to this:

PHP Code:
public function add(GUIComponent $component NULL$index = -1){ 
and the strict standard error should go away as well.
__________________


Mysidia Adoptables, a free and ever-improving script for aspiring adoptables/pets site.
  #44  
Old 01-27-2014, 03:52 AM
Kyttias's Avatar
Kyttias Kyttias is offline
Premium Member
 
Join Date: Jan 2014
Posts: 857
Gender: Unknown/Other
Credits: 86,972
Kyttias is on a distinguished road
Default

Quote:
Originally Posted by Hall of Famer View Post
Well most of these aint really problems, especially the notices. All you have to do is to disable notice errors in php.ini. For the strict standard error, go to /classes/class_radiolist.php and change:

PHP Code:
public function add(){ 
to this:

PHP Code:
public function add(GUIComponent $component NULL$index = -1){ 
and the strict standard error should go away as well.
Mhmm! And I'm sure you've got plans to clean those away in the future, sorry if reporting them was redundant. ^^;;;

My line in /classes/class_radiolist.php was actually:
PHP Code:
    public function add(RadioButton $radio$index = -1){ 
but changing it to yours gave me this beauty:
PHP Code:
( ! ) Fatal errorCall to a member function getName() on a non-object in C:\wamp\www\Mysidia\classes\class_radiolist.php on line 44
Call Stack
#    Time    Memory    Function    Location
1    0.0018    275152    {main}( )    ..\index.php:0
2    0.0107    389752    IndexController
::main( )    ..\index.php:78
3    0.9250    5257392    FrontController
->render( )    ..\index.php:74
4    0.9250    5257632    RegisterView
->index( )    ..\class_frontcontroller.php:100
5    0.9884    5506096    RadioList
->add( )    ..\registerview.php:49 
Can I get the full function? (Before the edit, mine was:)
PHP Code:
public function add(RadioButton $radio$index = -1){
        if(
$radio->getName() != $this->name) throw new GUIException("Cannot add unrelated radiobuttons to a RadioList.");
        
parent::add($radio$index);            
    } 
I couldn't find an add function with no parameter, just that one. @u@;;

However! I did work around the original Strict alert, with the code my install came with, because I can also turn Strict alerts off in php.ini, apparently. error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT does the trick.

Last edited by Kyttias; 01-27-2014 at 04:04 AM.
  #45  
Old 01-27-2014, 05:27 AM
Hall of Famer's Avatar
Hall of Famer Hall of Famer is offline
Administrator, Lead Coder
 
Join Date: Dec 2008
Location: South Brunswick
Posts: 4,448
Gender: Male
Credits: 327,496
Hall of Famer is on a distinguished road
Default

Oh I see, then you probably just change RadioButton to GUIComponent instead. PHP is an annoying language in a way that its type hinting is incomplete. RadioButton is a subclass of GUIComponent, this kind of type hinting is normally reasonable but in PHP it generates strict standard errors.
__________________


Mysidia Adoptables, a free and ever-improving script for aspiring adoptables/pets site.
  #46  
Old 01-27-2014, 11:52 AM
Kyttias's Avatar
Kyttias Kyttias is offline
Premium Member
 
Join Date: Jan 2014
Posts: 857
Gender: Unknown/Other
Credits: 86,972
Kyttias is on a distinguished road
Default

Quote:
Originally Posted by Hall of Famer View Post
Oh I see, then you probably just change RadioButton to GUIComponent instead. PHP is an annoying language in a way that its type hinting is incomplete. RadioButton is a subclass of GUIComponent, this kind of type hinting is normally reasonable but in PHP it generates strict standard errors.
Ah, sorry, doing so is what caused the Fatal Error instead, so I changed it back to what it came with and disabled the Strict warnings from displaying, so it's okay.

I think newer versions of PHP are doing a little better, hence all the complaining it does over code it's changed requirements for, but as a constantly updating language it's lack of backwards compatibility as soon as a server updates makes it quite a headache. Despite having a book or two laying around, and tinkering around with PHP for a couple years, I still end up at a loss of what I'm doing most of the time and end up turning to Google to find nothing but forums full of people going 'have you googled it?' and shaking my head at the irony. Luckily, these warnings aren't major problems (yet, or hopefully anytime soon).

But thank you so much for your time! I won't spend my time troubleshooting stuff I can just shut off, and I'm sure it's all going to get sorted out eventually. You never know what happens when PHP decides to update. It's like buying a new computer, eventually, you just can't find the old version you like in the store anymore.

I'm glad to see activity, and this probably isn't where I'm meant to be posting, so when I have more questions, I'll post elsewhere. Sorry for that!

I'm off to go build a template~
  #47  
Old 01-27-2014, 04:33 PM
Hall of Famer's Avatar
Hall of Famer Hall of Famer is offline
Administrator, Lead Coder
 
Join Date: Dec 2008
Location: South Brunswick
Posts: 4,448
Gender: Male
Credits: 327,496
Hall of Famer is on a distinguished road
Default

I see, and yeah at this moment turning off notice/strict-error reporting is the best choice to take. I kinda forget what the method signature was, but I may take a look at it and see if I can get rid of the error message for you. It does not affect your site's functionality in any way, just some plainly annoying text you wish it to disappear. Good luck making a theme/template btw.
__________________


Mysidia Adoptables, a free and ever-improving script for aspiring adoptables/pets site.
  #48  
Old 02-12-2014, 04:11 PM
collierox collierox is offline
the betrayed
 
Join Date: Dec 2013
Location: Detroit, MI
Posts: 6
Gender: Female
Credits: 3,097
collierox is on a distinguished road
Unhappy Problem

I tried doing the "/install/index.php" part, but it's not working for me....
  #49  
Old 02-12-2014, 04:16 PM
Hall of Famer's Avatar
Hall of Famer Hall of Famer is offline
Administrator, Lead Coder
 
Join Date: Dec 2008
Location: South Brunswick
Posts: 4,448
Gender: Male
Credits: 327,496
Hall of Famer is on a distinguished road
Default

What errors do you get? Are you sure you are accessing the correct url path? Sometimes this kind of issues are caused by improper uploads of script files, if you just upload the entire folder through FTP it may not work unless you rename it.
__________________


Mysidia Adoptables, a free and ever-improving script for aspiring adoptables/pets site.
  #50  
Old 06-03-2014, 03:23 PM
Abronsyth's Avatar
Abronsyth Abronsyth is offline
A Headache Embodied
 
Join Date: Aug 2011
Location: NY
Posts: 1,011
Gender: Male
Credits: 111,687
Abronsyth is on a distinguished road
Default

Was just installing script and I am unfamiliar with the cPanel, so I might have done something wrong here...but while trying to install I got this error;
Could not connect to database, the following error has occurred:
SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

Not sure what it means?
__________________
My Mods Site (1.3.4, 2020 Mods)
Closed Thread

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Mysidia Adoptables v1.3.3[Security Release] Hall of Famer Mysidia Adoptables Official Announcement 122 05-18-2013 04:02 PM
Mysidia Adoptables v1.3.0[Security Release] Hall of Famer Mysidia Adoptables Official Announcement 180 04-01-2012 10:16 PM
Mysidia Adoptables v1.2.0[Security Release] Hall of Famer Mysidia Adoptables Official Announcement 21 03-22-2011 04:13 PM
Mysidia Adoptables v1.1.4[Security Release] Hall of Famer Mysidia Adoptables Official Announcement 15 01-28-2011 11:48 AM
Mysidia Adoptables v1.1.3[Security Release] Hall of Famer Mysidia Adoptables Official Announcement 27 01-26-2011 02:59 PM


All times are GMT -5. The time now is 02:10 PM.

Currently Active Users: 443 (0 members and 443 guests)
Threads: 4,080, Posts: 32,024, Members: 2,016
Welcome to our newest members, jolob.
BETA





What's New?

What's Hot?

What's Popular?


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
vBCommerce I v2.0.0 Gold ©2010, PixelFX Studios
vBCredits I v2.0.0 Gold ©2010, PixelFX Studios
Emoticons by darkmoon3636