Mysidia Adoptables Support Forum

Mysidia Adoptables Support Forum (http://www.mysidiaadoptables.com/forum/index.php)
-   Tutorials and Tips (http://www.mysidiaadoptables.com/forum/forumdisplay.php?f=27)
-   -   [guide] Setting up WAMP w/Mysidia (http://www.mysidiaadoptables.com/forum/showthread.php?t=4774)

Kasandra 02-15-2016 08:24 PM

nvm, I think I've worked it out

Kyttias 02-15-2016 09:01 PM

The Notices exist because you have a higher version of PHP than Mysidia was created on, and some things have since fallen out of best practice, but the code still functions.

Warnings... same deal, the code is still functional. As for the warning, you could try using 127.0.0.1 instead of localhost in Mysidia's configuration file (inc/config.php)?

Stackoverflow: What is the difference between a Notice and a Warning?

You can turn off Notices and Warnings in XAMPP's php.ini file (help finding it) under error_reporting (search for the line that does not begin with a semi-colon, may be the second result rather than the first): Try:
Code:

error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT
Hosts online already tend to have these disabled, as they're not true error messages. The creator of Mysidia is already aware of these "problems" and they should be fixed in the next version.

Kasandra 02-15-2016 09:20 PM

Urg, I'm getting another problem after install..

Code:

Warning: require(C:/xampp/htdocs//inc/smarty/Smarty.class.php): failed to open stream: No such file or directory in C:\xampp\htdocs\Mysidia\classes\class_mysidia.php on line 326

Fatal error: require(): Failed opening required 'C:/xampp/htdocs//inc/smarty/Smarty.class.php' (include_path='.;C:\xampp\php\PEAR') in C:\xampp\htdocs\Mysidia\classes\class_mysidia.php on line 326


Kasandra 02-15-2016 09:41 PM

Okay, I made another install and it works fine now. I noticed that the url wasn't quite right and worked out that I forgot to include the subfolder in the installation. -is shot-

Kasandra 02-15-2016 09:50 PM

And now I can't login...

what am I doing wrong? XD


Saw this in your tutorial,
Code:

Always access your site with 127.0.0.1, not localhost - else you'll have issues logging in/staying logged in. So go ahead and bookmark 127.0.0.1.
I can't access the site under 127.0.0.1/Mysidia
The only way I can access it is with http://localhost:8080/Mysidia

Is that the reason I cannot login? And if so, how can I fix it? Currently the 127.0.0.1 shows only a blank page.

Edit: 127.0.0.1:8080 works >.>

But still unable to login.

Edit2: Made another account, logs in (or at least it says it does, as it comes up with the welcome message) then immediately logs out again when I try to click on any other link.

Kyttias 02-15-2016 11:38 PM

Just make sure your inc/config.php file matches whatever it is that you're trying to access...? If it requires 8080 as part of the url, make sure that's part of the configuration's file.

I have another solution, though it's an added layer of complexity. Because you're acting as your own server, you can create a "Virtual Host" which will allow you essentially make a fake domain name (fake, because only you can access it... I tend to end my fake sites in .dev but you really could make it anything). Here's a guide that should help. Because you'll be accessing the site at something other than either localhost or 127.0.0.1, it'll route it properly every time.

Kasandra 02-16-2016 07:31 PM

Hi Kyttias,

This is my config file;

Code:

<?php
//Mysidia Adoptables Site Configuration File

define('DBHOST', '127.0.0.1');            //DB Hostname
define('DBUSER', 'root');            //DB Username
define('DBPASS', '*****');            //DB Password
define('DBNAME', 'mysite');            //Your database name
define('DOMAIN', '127.0.0.1:8080');            //Your domain name (No http, www or . )
define('SCRIPTPATH', '/Mysidia');    //The folder you installed this script in
define('PREFIX', 'adopts_');
?>

If 127.0.0.1:8080/Mysidia works (but wont let me login) then these settings look correct.

I followed that procedure you linked to, but came up with this error:

ERR_ICANN_NAME_COLLISION

Apparently Chrome does not like you using .dev
So I tried .loc , .local , .localhost
and they all just went to google search instead.

I restarted Xampp each time.

I've even attempted to try this - https://support.apple.com/en-us/HT204684

So, maybe its the files themselves? Well, here's what I have.

.hosts
Code:

        127.0.0.1      localhost
        127.0.0.1      www.mysidia.localhost

I've even tried added the 8080 port, just in case, but that didn't work either.

...-vhosts.config
Code:

NameVirtualHost *:8080

<VirtualHost *:8080>
      DocumentRoot "C:/xampp/htdocs/"
      ServerName localhost
</VirtualHost>

<VirtualHost *:8080>
DocumentRoot "C:/xampp/htdocs/Mysidia"
ServerName mysidia.localhost
ServerAlias www.mysidia.localhost
<Directory "C:/xampp/htdocs/Mysidia">
AllowOverride All
Require all Granted
</Directory>
</VirtualHost>

I am at my wits end trying to work this out >.<

Kasandra 02-16-2016 07:32 PM

Actually, I've even tried to do the same with another site I was working on for a friend, and had to access that through the localhost:8080 because nothing else worked... But that site was static and didn't require any login.

Kasandra 02-26-2016 04:58 AM

Not trying to rush anyone, but if there was someone that could help me set this up so that it works and I can play around with it and build a site it would be greatly appreciated.

Kyttias 02-26-2016 09:49 AM

Alright, see, you're asking 127.0.0.1 to redirect to www.mysidia.localhost, but 127.0.0.1 is not your site, as in your config file you've put in 127.0.0.1:8080. Try updating your hosts file to reflect 127.0.0.1:8080. And once you're done, update Mysidia's config file to have the domain be to what you've got in your hosts file!

There a number of things that can go wrong. Virtual hosts must be enabled in httpd.conf, and then what you have above (more or less) should be, of course, in httpd-vhosts.conf -- and you have to make sure these are the right copies of these files in the XAMPP installation, because I know for certain WAMP keeps backups and editting those won't help (so long as you followed a guide, you're good).

My virtual hosts set up is like this:

Code:

<Directory C:/Users/Kyttias/Dropbox/WAMP>
    Order Deny,Allow 
    Allow from all
</Directory>

<VirtualHost *:80> 
    DocumentRoot "C:\Users\Kyttias\Dropbox\WAMP\Sanctuary"
    ServerName sanctuary.dev
    ServerAdmin kyttias@gmail.com
    ErrorLog "logs/Sanctuary-error.log"
    CustomLog "logs/Sanctuary-access.log" common
</VirtualHost>

(One of many, anyway.) You have ServerAlias in yours, I've never used that. But my ServerName matches what's in the host file exactly, and yours does not. =/

My hosts for this would be (lines for this example only):
Code:

127.0.0.1      localhost
127.0.0.1      sanctuary.dev

And then my Mysidia inc/config.php file is now using:
Code:

define('DOMAIN', 'sanctuary.dev');            //Your domain name (No http, www or . )
But I'm not using 8080. You could always try reconfiguring XAMPP to not need 8080, if you haven't given that a shot. I honestly have no experience with 8080 or needing to work around it.

At some point or another you'd be better of seeking help from people who understand the problem... I can really only help people working with WAMP under a standard port 80. :cfrown:


All times are GMT -5. The time now is 01:28 PM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.