Page 1 of 1

need help on function . require

Posted: Fri Aug 22, 2008 5:54 am
by srisree
My site is running with social network script.

I want to integrate user registration with another script is business directory.

For every member who registers in mysite then he will regsiter as user in business directory also. for that I have API

To call API i have inserted the following block in mysite join.php.


//BLOCK FOR DIRECTORY API MODULE INTEGRATION

$directory = '/home/mysite/public_html/mydirectory';
require_once( $directory . '/API/scripts/new_member.php?secret=9999999&username=' . $aProfile[NickName] . '&password=' . $aProfile[Password] );

//END DIRECTORY API MODULE INTEGRATION

file structure is like this

http://www.mysite.com/join.php

i installed Business directory here

http://www.mysite.com/mydirectory

* Both are using same Databse

after adding this in join.php everthing is fine fine but when i filled l join form and hit submit button

i got the following error

Warning: registermember(/home/mysite/public_html/mydirectory/API/scripts/new_member.php?secret=9999999&username=golden&password=tester) [function.registermember]: failed to open stream: No such file or directory in /home/mysite/public_html/join.php on line 394

Fatal error: registermember() [function.require]: Failed opening required '/home/mysite/public_html/mydirectory/API/scripts/new_member.php?secret=9999999&username=golden&password=tester' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/mysite/public_html/join.php on line 394


I have checked all files path everything is right



Line 394 is in join.php is


LINE393 $directory = '/home/mysite/public_html/mydirectory';
LINE394 require_once( $directory . '/API/scripts/new_member.php?secret=9999999&username=' . $aProfile[NickName] . '&password=' . $aProfile[Password] );


Anyone Please

Regards

Re: need help on function . require

Posted: Fri Aug 22, 2008 8:59 am
by ghurtado
You cant have query strings (everything after the question mark) in local file includes.

Re: need help on function . require

Posted: Fri Aug 22, 2008 9:20 am
by ghurtado
Do not send me your questions via Personal Message, instead post them here.

Re: need help on function . require

Posted: Fri Aug 22, 2008 10:24 am
by srisree
I do not know forum Rules here.
I joined today
sorry for sending PM

so how to pass these query to API/scripts/new_member.php

secret=9999999
username=$aProfile[NickName]
password=$aProfile[Password]

Please