create facebook addons

Permalink
Hello friends I am creating a Facebook ad dons for log in . I don't want to purchase this. I want to make our own custom ad dons. How i can is possible please suggest me.
thanks in advance

 
mnakalay replied on at Permalink Reply
mnakalay
Concrete5 already comes with a Facebook login system, you don't need to build or buy it.

On your website go to dashboard/system/registration/authentication
vikaskushwah replied on at Permalink Reply
This is for admin ,but i want to do for user
vikaskushwah replied on at Permalink Reply
This is for admin ,but i want to do for user
mnakalay replied on at Permalink Reply
mnakalay
I am not sure what you mean by "this is for admin".

If you activate the Facebook login option, it will appear on your site normal login screen which is for everybody not just for admin.

When setting it up you can select to which user group your users will be added, so it can be the guest group or any non-admin group.

Am I missing something?
vikaskushwah replied on at Permalink Reply
this solution for 5.x version
how we can do with lower version
vikaskushwah replied on at Permalink Reply
version": "2.0.0"
mnakalay replied on at Permalink Reply
mnakalay
Oh, I see. Then why don't you just look at how it's done with the newer version and adapt it to the old one? All the code you need is there.
vikaskushwah replied on at Permalink Reply
so where i can find this type of code
mnakalay replied on at Permalink Reply
mnakalay
Download C5's latest version from here and look inside the concrete/authentication/facebook folder.
vikaskushwah replied on at Permalink Reply
how i can apply in my project
mnakalay replied on at Permalink Reply
mnakalay
I don't know your project so I can't tell for sure.

However, I can say that, for sure, you need to:
1- know about Concrete5 at least to some extent
2- Know how to code in PHP
3- Be willing to have a look and gather information from the code

If you don't have at least these 3 down, you can't do it on your own.
vikaskushwah replied on at Permalink Reply
I know this
vikaskushwah replied on at Permalink Reply
sir
how to call ajax in concrete5 and I have to pass data also
can you give me syntax
vikaskushwah replied on at Permalink Reply
Here check is method name of controller why this is create wrong URL can enplane me
<?php $action = $this->action( 'check' ); ?>
console.log("<?php echo $action;?>");
output is
"https://testing.pd.cisinlive.com/concrete5-8/index.php/check/190"

why here 190 extra add here and how i can solve it
mnakalay replied on at Permalink Reply
mnakalay
It looks like you're doing that from a block's controller so the system automatically adds the value of the block's ID (bID) to the action URL. If you have more than one of those blocks on the page, you need the bID to check from within the block if the call is for this instance of the block or for another on the page. Without that bID, all your block instances on the page would react to your call at the same time which is probably not what you want.

So for your check() function you would do this in your block's controller
public function action_check($bID) {
    if (empty($bID) || $bID != $this->bID) {
        return false;
    }
    // rest of your code here
}
vikaskushwah replied on at Permalink Reply
Thank so much
it's working
vikaskushwah replied on at Permalink Reply
can we insert data from controller if yes
can you send me syntax of insert code
thanks in advanse
mnakalay replied on at Permalink Reply
mnakalay
I am not sure I understand the question. DO you mean sending data from the controller to the view?
If that's your question, in your controller you can do
$this->set('myVar', 'myValue');

And then in your view you'll have the variable $myVar with the value 'myValue'
vikaskushwah replied on at Permalink Reply
insert data in database
like insert query
I want insert data in from controller
vikaskushwah replied on at Permalink Reply
$sql = "INSERT INTO Users (uName,uEmail) VALUES '','' ";
vikaskushwah replied on at Permalink Reply
if i applied this query for fetch form data

$db->fetchColumn('SELECT uEmail FROM Users WHERE uEmail = ?', [$email]);

then if email id not found it's give error like query is empty
so how i can solve it sir
vikaskushwah replied on at Permalink Reply
one other question is how redirect to controller view page
and
any way where i can learn concret5 easily
thanks sir for helping me
Gondwana replied on at Permalink Reply
Gondwana
In general, you shouldn't put things in c5's database if there's an API call for what you're trying to achieve.
vikaskushwah replied on at Permalink Reply
hi
i have installed concrete5.6.3.2 it's give me fatel error
PHP Fatal error: Cannot use 'Object' as class name as it is reserved in /var/www/html/concrete5.6.3.2/concrete/libraries/object.php on line 3
any one suggest me how i can solve this error
mnakalay replied on at Permalink Reply
mnakalay
It seems you are trying to use it with PHP 7.2 which is not going to work.
With your version of Concrete5 you should probably stick to PHP 5.6.x

You may be able to use PHP 7.1.x with Concrete5 5.6.3.5

I am not sure I understand why you are trying to use an old version of an unsupported branch of Concrete5.

If you need to use old C5 at least use the latest version of that branch.

And if you ave a choice, use the new v8 branch which is supported
vikaskushwah replied on at Permalink Reply
I don't have any choice because my project already exist in this version