Welcome to the MetaMod and Chameleon Support Forums.

Before posting, please check out the FAQs.

helpme

 

Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.

 

first enter code then access website

first enter code then access website

Hi Stephen

i have develop  joomla http://www.imperialroi.com/  website
i have another page which is simple html form page not integrated with joomla.. i want before access main website url.. user redirect to  login.html enter 4 digit code then access website for the rest of the time
eg
http://www.callofduty.com/blackops/age- … ckops/home

second how to restrict direct access of any page.
eg i dont want user visit direct to   http://www.imperialroi.com/about     or any other page of only user with authorized code access all pages

thanks
Best Regards

lordman
Beginner Modder
ranks
useravatar
Offline
10 Posts
User info in posts
Administrator has disabled public posting

Re: first enter code then access website

Hi Lordman,

With Chameleon I think you could do this quite easily by using the session variables to keep track of whether they have logged in or not. You could also use the PHP box in the rule to process the form.

rule 1: allow anyone who has logged in to continue
- detect session variable A, and if found, quit the rule chain (i.e. don't do any further checking)

rule 2: process the form
- use some PHP to check the form values. If they are found, return true so that the form succeeds. In the Succeed action, set session variable A and quit the rule chain

rule 3: allow the form page
- detect the page that the form is on. In the succeed action, quit the rule chain to allow them to view that page

rule 4: at this stage they are not logged in, not on the form page. So just redirect them to the form page.


Make sense?
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3312 Posts
User info in posts
Administrator has disabled public posting

Board Info

Board Stats:
 
Total Topics:
1667
Total Polls:
6
Total Posts:
5909
Posts this week:
1
User Info:
 
Total Users:
10118
Newest User:
jack67484
Members Online:
2
Guests Online:
140


Forum Legend:

 Topic
 New
 Locked
 Sticky
 Active
 New/Active
 New/Locked
 New Sticky
 Locked/Active
 Active/Sticky
 Sticky/Locked
 Sticky/Active/Locked