Class 'R' not found

179 views
Skip to first unread message

Stephan Krauss

unread,
May 18, 2016, 3:29:18 PM5/18/16
to redbeanphp
Hello,

i have installed RedBean with composer.
When i call

\R::setup( 'mysql:host=localhost;dbname=mydatabase', 'myusername', 'mypassword' );

i get the error 'Class 'R' not found'

In my Php file is:

namespace controller;
use models\model;
use models\myCalc;
use \RedBeanPHP\R;

Who can help ?

Your sincerly

Stephan

Jose Zapata

unread,
May 18, 2016, 7:03:19 PM5/18/16
to redbe...@googlegroups.com
Maybe try

use \RedBeanPHP\R as R;

and then 


R::setup( 'mysql:host=localhost;dbname=mydatabase', 'myusername', 'mypassword' );

--
You received this message because you are subscribed to the Google Groups "redbeanphp" group.
To unsubscribe from this group and stop receiving emails from it, send an email to redbeanorm+...@googlegroups.com.
To post to this group, send email to redbe...@googlegroups.com.
Visit this group at https://groups.google.com/group/redbeanorm.
For more options, visit https://groups.google.com/d/optout.

Stephan Krauss

unread,
May 19, 2016, 8:50:31 AM5/19/16
to redbeanphp
Thanks


Reply all
Reply to author
Forward
0 new messages