hi Every one,
is it possible to get current login user information from joomla to custom php file which also present in joomla root directory i tried but i get error please need urgently...
but i got error/warning..as ...
please help me..
is it possible to get current login user information from joomla to custom php file which also present in joomla root directory i tried but i get error please need urgently...
?php
define( '_JEXEC', 1 );
define('JPATH_BASE', 'D:/xampp/community/' );
define( 'DS', DIRECTORY_SEPARATOR );
require_once ( DS.'includes'.DS.'defines.php' );
require_once ( DS.'includes'.DS.'framework.php' );
$mainframe =& JFactory::getApplication('site');
$user =& JFactory::getUser();
echo "user is".$user->username;
but i got error/warning..as ...
Warning: require_once(\includes\defines.php) [function.require-once]: failed to open stream: No such file or directory in D:\xampp\htdocs\community\components\com_booklibrary\mybooks.php on line 9
Fatal error: require_once() [function.require]: Failed opening required '\includes\defines.php' (include_path='.;D:\xampp\php\PEAR') in D:\xampp\htdocs\community\components\com_booklibrary\mybooks.php on line 9
please help me..