Jump to content


[Script] Login System

login logout access permission restricted restrict form registered admin log

  • Please log in to reply
12 replies to this topic

#1 portapipe

portapipe

    Member

  • Members
  • PipPip
  • 11 posts

Posted 22 August 2016 - 08:19 AM

Hey, HI!

If you need a quick and easy way to protect your Admin Panel well... use Login-GroceryCrud!

No registration form, no lost password, just Login.

 

https://portapipe.gi...in-GroceryCrud/

 

Note: the user will be managed by GroceryCrud, so you need to create the page for the management of the users BUT you can find it in the WIKI of the github project so just copy and paste :)

Note 2: the user table will be create automagically, so you don't need to care about it :)

 

Please give me your feedback, I will happy to hear your experience with Login-GroceryCrud!



#2 Ahmed Adebiyi Oladapo

Ahmed Adebiyi Oladapo

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 24 August 2016 - 12:31 AM

I am so new to grocery crud, can you please do a short video on how to use this script?



#3 portapipe

portapipe

    Member

  • Members
  • PipPip
  • 11 posts

Posted 25 August 2016 - 11:25 AM

Hi! I'm adding a group management system to this script, so I think I'll do a video but not now.

Anyway you MUST read the GitHub page, 'cause it contains the exact example on how to implement it.

In a couple of words:

Put the files into your GroceryCrud/Codeigniter installation and go to 'yourBaseDomain.com/login'

Use 'admin' as username and 'admin' as password and you're done!



#4 Ahmed Adebiyi Oladapo

Ahmed Adebiyi Oladapo

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 27 August 2016 - 04:27 PM

Hi! I'm adding a group management system to this script, so I think I'll do a video but not now.

Anyway you MUST read the GitHub page, 'cause it contains the exact example on how to implement it.

In a couple of words:

Thanks so very much...



#5 Bluto

Bluto

    Newbie

  • Members
  • Pip
  • 3 posts

Posted 14 September 2016 - 07:47 AM

I keep getting the following error. 

I installed in my Dev site on localhost and it is running clean for any other installation I have tested in the same directory. It is a clean, unaltered CI directory that is configured correctly for my database and host.

I tried several fixes suggested on stackoverflow.com for this error with no result. 

I am a newbie to PHP/CI/CRUD and might be missing something, can you resolve this?

 

 

An uncaught Exception was encountered

Type: ParseError

Message: syntax error, unexpected end of file

Filename: C:\xampp\htdocs\CRUD\application\controllers\Login.php

Line Number: 247

Backtrace:

File: C:\xampp\htdocs\CRUD\index.php
Line: 315
Function: require_once



#6 arissurya

arissurya

    Newbie

  • Members
  • Pip
  • 3 posts

Posted 15 September 2016 - 04:49 PM

 

I keep getting the following error. 

I installed in my Dev site on localhost and it is running clean for any other installation I have tested in the same directory. It is a clean, unaltered CI directory that is configured correctly for my database and host.

I tried several fixes suggested on stackoverflow.com for this error with no result. 

I am a newbie to PHP/CI/CRUD and might be missing something, can you resolve this?

 

 

An uncaught Exception was encountered

Type: ParseError

Message: syntax error, unexpected end of file

Filename: C:\xampp\htdocs\CRUD\application\controllers\Login.php

Line Number: 247

Backtrace:

File: C:\xampp\htdocs\CRUD\index.php
Line: 315
Function: require_once

 

 

i have the same problem with you dude... i think we didn't include the bootstrap theme yet...



#7 portapipe

portapipe

    Member

  • Members
  • PipPip
  • 11 posts

Posted 16 September 2016 - 08:09 AM

Try to remove the line 131 in the controllers/Login.php file:

$crud->set_theme("bootstrap");

and give it a try.

Anyway I just updated the file, so click here to see the changes and here to download the new Login.php file



#8 Bluto

Bluto

    Newbie

  • Members
  • Pip
  • 3 posts

Posted 20 September 2016 - 08:24 AM

Sadly, it did not fix the problem.  I am not sure why I am having this issue when others deploy and use it without problems.

 

I am using XAMPP version 7.0.8 which includes PHP 7.  As I said, I am a newbie and at this point I am grabbing at straws but is it possible that your application requires PHP 5.6? 

 

I don't want to just drop the issue and move on to a different login tool because I learn valuable lessons from experiences like this.

 

Thank you for your help.



#9 anilp78

anilp78

    Newbie

  • Members
  • Pip
  • 3 posts

Posted 20 September 2016 - 02:37 PM

Hi !

Am a newbie and I am running grocery CRUD on localhost with the default "examples" and responsive theme. I copied your controller files into grocery controller folder, likewise models and views. I dont know how to access the login page now for the first time from the url to get the sql table generated and login starts working. Can you help?

 

thanks,



#10 fapth

fapth

    Member

  • Members
  • PipPip
  • 10 posts

Posted 24 September 2016 - 08:17 AM

Hello i tried to install this Plugin, but wenn i go to localhost/index.php/login i get following error:

Parse error: syntax error, unexpected end of file in C:\xampp\htdocs\helpdesk\application\controllers\Login.php on line 245
A PHP Error was encountered

Severity: Parsing Error

Message: syntax error, unexpected end of file

Filename: controllers/Login.php

Line Number: 245

Backtrace:

CodeIgniter3 and groverycrud



#11 Bluto

Bluto

    Newbie

  • Members
  • Pip
  • 3 posts

Posted 12 October 2016 - 05:30 AM

OK ... I solved my problem after much research so I wanted to share what I learned.

To refresh: I got this error when I tried to execute login - 

Parse error: Syntax error, unexpected end of file in my PHP code

The answer was a setting in my php.ini file.  

To fix the problem I changed short_open_tag to On

 

for example I replaced the short_open_tag line as follows:

; short_open_tag = Off ; previous value
short_open_tag
= On ; new value

 

find php.ini in the root of apache where htdocs is found inside the folder php, I stopped and restarted apache to make sure it picked up the change and it started working like magic. 

 

I hope this helps someone with their install.  

By the way ... Nice tool!  Thank you for sharing it with us.



#12 portapipe

portapipe

    Member

  • Members
  • PipPip
  • 11 posts

Posted 23 October 2016 - 07:51 AM

Guys I'm sorry, no notifications are sent to my mail. I need to re-checkup the notification system of the forum.

SO.

@anilp you have to go to http://yourdomain.com/login

@fapth read below

@Bluto that should fix the fapth issue too! I'm gonna change the code a bit to avoid this error. You can easily fix it by adding 'php' after the '<?' tag to make it '<?php' in line 167 of the Login.php controller.

 

I don't get why this is not enabled by default... ANYWAY fixed in the source code too!

 

@Bluto you're welcome! I think this is a MUST-have tool for a control panel like this.



#13 wellsprings

wellsprings

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 15 January 2017 - 06:58 AM

Hi, I am totally new to CI and Grocerycrud and after some trials, I managed to get CI and the Examples in Grocerycrud to work. I am trying to implement a simple login using your 3 files. I have installed them but I am not sure how to call or load this login class in my Examples.php.

 

Where do I paste this line?

 

$this->load->model("login_model");

if($this->login_model->isLogged()){
    $name = $this->login_model->name();
    echo "HI $name! You are Logged IN!";
}else{
    redirect("/login");
}

 

Thanks for your help. My link is 45.76.150.27/ci312/index.php/examples and the login is in 45.76.150.27/ci312/index.php/login

 

peter.







Also tagged with one or more of these keywords: login, logout, access, permission, restricted, restrict, form, registered, admin, log

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users