Eve Support Community
Forums
Eve Community
Customization Ideas
OK, my API problems....|
Go
![]() |
New
![]() |
Find
![]() |
Notify
![]() |
Tools
![]() |
Reply
![]() |
|
|
Groupee Member |
OK, here we go, grab a drink and some snacks, I have a feeling this could get long
So I downloaded the widget that Michael has post up top. I unzipped it and it came with 2 files. One is test.php and the other is SimpleAuthentication.php I opened them both in Notepad and made the following changes to test.php: In the top (the very top) I changed it to this: <?php
include_once('SimpleAuthentication.inc.php');
setEveURL('http://hometalk.infopop.cc/eve');
setSiteURL('http://hometalkxpress.com.com/test.php');
login();
?> I DID NOT make any changed to SimpleAuthentication.php. I then uploaded them both to my domain hometalkxpress.com I also DID NOT upload them to my Infopop webhosting account. After I uploaded them I went to my eve CP and went under master settings, and then advanced. I check the box to allow certain requests from the following domains. I typed in: hometalkxpress.com and saved it. I then went to http://hometalkxpress.com/test.php to see if it worked. It did not. I got this message: "Invalid Remote IP" So then I went back to my eve CP and entered in our sites (hometalkxpress.com) IP which Jonmark told me was 64.202.163.190 (I checked the box and did it under the "allowed IPs" not domain name) and clicked save. I then went back to http://hometalkxpress.com/test.php and got the same error "Invalid Remote IP" Help! Michael, you also have admin. powers on our forums in case I did something wrong with the IP or domain info. Thanks in advance for the help |
||
|
![]() |
Probably a very simple fix.
Here's the issue. hometalkxpress.com is a virtual domain but requests that a script makes *from* it go out from *another* domain. This is very common. I've attached a PHP script that will contact anoterh script on evedev.com. Upload it to the same directory as your simpleAuth PHP scripts. call it from a browser http://hometalkxpress.com/whoisasking.php It will tell you the IP or domain from which YOUR server is making its requests to eve. Use this data to update your eve "permitted" domain/IP list. Let us know how it goes. This message has been edited. Last edited by: MichaelF, Michael Farris<br/> Groupee whoisasking.zip (350 Bytes, 22 downloads) whoisasking zip |
|||
|
|
Groupee Member |
Michael, its not letting me download it, it just brings up a page that says,
Remote Host: admin.infopop.com Remote IP: 63.251.8.1 |
|||
|
|
Groupee Member |
Maybe you could try it again, or just send me the stuff needed via PT and I can paste it and save it from Notepad as a PHP page. Maybe that will work.
|
|||
|
![]() |
OK -- I dropped the file into a zip for download. Unzip it an upload to your directory.
Michael Farris<br/> Groupee |
|||
|
|
Groupee Member |
OK we have a little bit of success here... I don't get the invalid IP any more... if I am logged out it brings me to the Groupee login page for my forums, however, then when I login it says
"Login Required, please try again later." |
|||
|
![]() |
Odds are very good you have set
setEveURL('http://yourevename.infopop.cc/eve'); wrongly this is your ***EVE*** site URL, not your remote site Try http://hometalk.infopop.cc/eve If not paste in that top few lines of code block from test.php here Michael Farris<br/> Groupee |
|||
|
|
Groupee Member |
Nope, I have it set to my eve... here are the first lines on test.php:
<?php
include_once('SimpleAuthentication.inc.php');
setEveURL('http://hometalk.infopop.cc/eve');
setSiteURL('http://hometalkxpress.com.com/test.php');
login();
?> |
|||
|
![]() |
??? Michael Farris<br/> Groupee |
|||
|
|
Groupee Member |
Of course, a .com.com is all the rage these days
Hahaha, thanks for pointing that out, I fixed it, uploaded it, and POOF! It works now! YAY! So now the only other question I have it for any page I want to protect that way I just add this PHP script: <?php include_once('SimpleAuthentication.inc.php'); setEveURL('http://hometalk.infopop.cc/eve'); setSiteURL('http://hometalkxpress.com/test.php'); login(); ?> Then follow with my coding like a regular HTML page, but save it as a PHP document, correct? |
|||
|
![]() |
Glad it works.
If you are including this bit of code on lots of pages you might streamline things by making one variable dynamic setSiteURL('http://' .$_SERVER['SERVER_NAME'] . $_SERVER['PHP_SELF']); For example: <?php include_once('SimpleAuthentication.inc.php'); setEveURL('http://michael.infopop.cc/eve'); //setSiteURL('http://yousite.com/path/test.php'); setSiteURL('http://' .$_SERVER['SERVER_NAME'] . $_SERVER['PHP_SELF']); login(); ?> Otherwise your need to edit setSiteURL('http://yousite.com/path/test.php'); to match each file name you protect. Just test.php won't work. Remember this line include_once('SimpleAuthentication.inc.php'); assumes that SimpleAuthentication.inc.php is in the same directory as the files. Michael Farris<br/> Groupee |
|||
|
|
Groupee Member |
Alrighty, thanks
|
|||
|
| Previous Topic | Next Topic | powered by eve community |
| Please Wait. Your request is being processed... |
|
Eve Support Community
Forums
Eve Community
Customization Ideas
OK, my API problems....
