Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
Create script to login and activate
Old 07-04-2009, 06:49 PM Create script to login and activate
Junior Talker

Posts: 3
Trades: 0
I need to create a script, for you who know much, is easy.

See the image below what I needed, someone has this script or could help me do. It is very simple for you.




2 - Folders.. (Admin and site)
2 - Files ..

Only one user. Please. Help me.

Thank you.

Cood

Last edited by Cood; 07-04-2009 at 06:50 PM..
Cood is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 07-04-2009, 08:26 PM Re: Create script to login and activate
NullPointer's Avatar
Will Code for Food

Posts: 2,781
Name: Matt
Location: Irvine, CA
Trades: 0
If you only have one user there is no real need to code a login system in PHP. You can just password protect the admin directory:

http://www.google.com/search?hl=en&s...q=f&oq=&aqi=g2
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
NullPointer is online now
Reply With Quote
View Public Profile Visit NullPointer's homepage!
 
Old 07-04-2009, 08:30 PM Re: Create script to login and activate
Junior Talker

Posts: 3
Trades: 0
No I'dont need simple login, I need activate a variable and another file I comparte and execute with situation of var.

Can be login. Understand.

Thankjs.
Cood is offline
Reply With Quote
View Public Profile
 
Old 07-06-2009, 02:45 AM Re: Create script to login and activate
Average Talker

Posts: 26
Name: Prithwiraj Bose
Location: Kalyani, West Bengal, India
Trades: 0
Code for admin/index.php

Code:
 
<?php 
$pass="your password";
$user="your username";
if($pass=='entered password' && $user=='entered username')
{
$activate=1;
}
else
{
$activate=0;
}
header("Location: ../site/index.php?activate=".$activate);
?>
Code for site/index.php

Code:
 
<?php
if($_REQUEST['activate']==1)
{
?>
<enter code html1 here>
<?php
}
else
{
?>
<enter code html2 here>
<?php
}
?>
__________________

Please login or register to view this content. Registration is FREE
in Kolkata
|
Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
| Become a
Please login or register to view this content. Registration is FREE
for Free.

Last edited by techbongo; 07-06-2009 at 02:47 AM.. Reason: typo inside if()
techbongo is offline
Reply With Quote
View Public Profile
 
Old 07-06-2009, 11:04 AM Re: Create script to login and activate
Junior Talker

Posts: 3
Trades: 0
Great!

Exactly what I was looking for.

However I need to put the fields in the Input / admin as I do this in php. The "input" to the user and also the "input" to pass.

Ah! You do not need to put in / site / index.php a call to the admin file?

Thank you.

Cood.
Cood is offline
Reply With Quote
View Public Profile
 
Old 07-06-2009, 02:43 PM Re: Create script to login and activate
orionoreo's Avatar
Ultra Talker

Posts: 335
Name: Jerry
Trades: 0
i believe this was the same ordeal:

http://www.webmaster-talk.com/php-fo...-profiles.html
orionoreo is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Create script to login and activate
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.29669 seconds with 12 queries