Problems, need help? Have a tip or advice? Post it here.
16 posts Page 2 of 2
I have used the same code as you have suggested
Code: Select all
<li class="login"><a href="<cms:login_link redirect="<cms:link 'loggedin.php' />"/>">Login</a></li>


1. If i go from home page (index.php) to the login page by clicking the menu item (on home page) it shows redirection to the loggedin.php page. But when i log in, i get an error message "Security tokens do not tally for executing this action. Please try again." and i cant do anything there.

2. On getting the above error message, I change the url to "folder/couch" and get a access denied warning, from where i log out. (I do this to only logout).

3. Now on returning to the login page after logging out, the URL now shows: [url]folder/users/login.php?redirect=%2FAditiRai%2FBootstrapSite%2Fcouch%2F[/url] and not the loggedin.php page.

This is the code of my index page:
Code: Select all
<?php require_once( 'couch/cms.php' ); ?>
<cms:template title='Home Page - Editing' order='2' >
   <cms:repeatable name='banner' label='Banner' order='1'>
       <cms:editable name='banner_image' label='Banner - Image' type='image' show_preview='1' input_width='150' preview_width='200' />
        <cms:editable name='banner_title' label='Banner - Title' type='text' />
    </cms:repeatable>
    <cms:editable name='intro_blocks' label='Intro Boxes' type='group' order='2' />
       <cms:editable name='intro_blocks_employers_title' label='Employers - Title' type='text' group='intro_blocks' />
       <cms:editable name='intro_blocks_employers_desc' label='Employers - Description' type='richtext' group='intro_blocks' />
        <cms:editable name='intro_blocks_jobSeekers_title' label='Job Seekers - Title' type='text' group='intro_blocks' />
        <cms:editable name='intro_blocks_jobSeekers_desc' label='Job Seekers - Description' type='richtext' group='intro_blocks' />
    <cms:editable name='timeline' label='Timeline' type='group' order='3' />
       <cms:editable name='timeline_title' label='Timeline - Title' type='text' group='timeline' />
        <cms:repeatable name='timeline_content' label='Timeline - Content' group='timeline' start_count='1' >
           <cms:editable name='timeline_content_title' label='Title' type='text' />
            <cms:editable name='timeline_content_desc' label='Description' type='nicedit' />
            <cms:editable name='timeline_content_color' label='Round Button Color' opt_values='red | | green | | yellow | | orange | | blue | | aqua' type='radio' />
            <cms:editable name='timeline_content_icon' label='Round Button Color' opt_values='key | | magnifier | | share | | view | | call | | thumbsup' type='radio' />
        </cms:repeatable>
   
</cms:template>
<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge">
        <meta name="viewport" content="width=device-width, initial-scale=1">
       
        <!-- Site Title -->
        <title>Aap Ke Sevak</title>
       
        <!-- Stylesheets -->
        <link href="css/bootstrap.css" rel="stylesheet">
        <link href="css/genxcoders.css" rel="stylesheet">
        <link href="css/font-awesome.css" rel="stylesheet">
        <!-- Banner -->
        <link rel="stylesheet" href="nivo-themes/default/default.css" type="text/css" media="screen" />
        <link rel="stylesheet" href="css/nivo-slider.css" type="text/css" media="screen" />
        <!--<link rel="stylesheet" href="style.css" type="text/css" media="screen" />-->
        <!-- Time Line -->
        <link rel="stylesheet" href="css/timeline-style.css">
        <script src="js/timeline-modernizr.js"></script>
        <script src="js/timeline-main.js"></script>
        <!-- Ticker -->
        <link type="text/css" href="testimonials/style000.css" rel="stylesheet" />
       
        <!--[if lt IE 9]>
        <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
        <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
        <![endif]-->
    </head>
    <body>
       
        <!-- Navigation -->
        <nav class="navbar navbar-default navbar-fixed-top" role="navigation">
           <div class="top-bar"></div>
           <div class="container">
                <div class="navbar-header">
                    <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
                        <span class="sr-only">Toggle navigation</span>
                        <span class="icon-bar"></span>
                        <span class="icon-bar"></span>
                        <span class="icon-bar"></span>
                    </button>
                    <a class="navbar-brand" href="index.html">
                       <img class="logo" src="images/aap-ke-sevak-logo.png" alt="Aap Ke Sevak" />
                    </a>
                </div>
           
                <!-- Collect the nav links, forms, and other content for toggling -->
                <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
                    <ul class="nav navbar-nav">
                        <cms:embed 'menu.html' />
                    </ul>
                    <ul class="nav navbar-nav navbar-right">
                       <form class="navbar-form navbar-left" role="search">
                            <div class="form-group">
                                <input type="text" class="form-control" placeholder="Aap Ke Sevak...">
                            </div>
                            <button type="submit" class="btn btn-default">Search</button>
                        </form>
                     <li class="login"><a href="<cms:login_link redirect="<cms:link 'loggedin.php' />"/>">Login</a></li>
                     <li class="register"><a href="#">Register</a></li>
                  </ul>
              </div><!-- /.navbar-collapse -->
           </div><!-- /.container-fluid -->
        </nav>
        <!-- Navigation -->
       
        <!-- Banner -->
        <div class="padding-top-50"></div>
        <div class="jumbotron">
           <!--<div class="container">-->
                <!--<div class="row">-->
                    <div id="wrapper">   
                        <!-- The slider wrapper div  -->
                        <div class="slider-wrapper theme-default">
                            <div id="slider" class="nivoSlider">
                                <!--  Images to slide through.  -->
                                <cms:show_repeatable 'banner'>
                                <img src="<cms:show banner_image />" alt="" title="<cms:show banner_title />" />
                                </cms:show_repeatable>
                            </div>
                        </div>
                    </div>
                <!--</div>-->
            <!--</div>-->
        </div>
        <!-- Banner -->
       
        <div class="padding-top-20"></div>
       
        <!-- Blocks -->
        <div class="container">
           <div class="row">
               <div class="col-md-6">
                   <div class="well">
                       <h4><cms:show intro_blocks_employers_title /></h4>
                        <div class="padding-top-10"></div>
                        <p class="text-justify">
                           <cms:show intro_blocks_employers_desc />
                        </p>
                    </div>
                </div>
                <div class="col-md-6">
                   <div class="well">
                       <h4><cms:show intro_blocks_jobSeekers_title /></h4>
                        <div class="padding-top-10"></div>
                        <p class="text-justify">
                           <cms:show intro_blocks_jobSeekers_desc />
                        </p>
                    </div>
                </div>
            </div>
        </div>
        <!-- Blocks -->
       
        <hr />
       
        <!-- Timeline -->
        <div class="padding-top-20"></div>
        <div class="container">
           <div class="row">
               <h3 class="text-center"><cms:show timeline_title /></h3>
               <div class="col-md-12">
                    <section id="cd-timeline" class="cd-container">
                       <cms:show_repeatable 'timeline_content' >
                        <cms:each my_categories as='color'>
                            <cms:set timeline_content_color="<cms:show color />" />
                            <cms:if "<cms:not_empty timeline_content_color />" >
                                <cms:if timeline_content_color = 'red' >red</cms:if>
                                <cms:if timeline_content_color = 'green' >green</cms:if>
                                <cms:if timeline_content_color = 'yellow' >yellow</cms:if>
                                <cms:if timeline_content_color = 'orange' >orange</cms:if>
                                <cms:if timeline_content_color = 'blue' >blue</cms:if>
                                <cms:if timeline_content_color = 'aqua' >aqua</cms:if>
                            </cms:if>     
                        </cms:each>
                        <div class="cd-timeline-block">
                            <div class="cd-timeline-img cd-<cms:show timeline_content_color />">
                               <cms:each my_categories2 as='icon'>
                                    <cms:set timeline_content_icon="<cms:show icon />" />
                                    <cms:if "<cms:not_empty timeline_content_icon />" >
                                        <cms:if timeline_content_icon = 'key' ></cms:if>
                                        <cms:if timeline_content_icon = 'magnifier' ></cms:if>
                                        <cms:if timeline_content_icon = 'share' ></cms:if>
                                        <cms:if timeline_content_icon = 'view' ></cms:if>
                                        <cms:if timeline_content_icon = 'call' ></cms:if>
                                        <cms:if timeline_content_icon = 'thumbsup' ></cms:if>
                                    </cms:if>     
                                </cms:each>
                                <img src="images/<cms:show timeline_content_icon/>.png" />
                            </div> <!-- cd-timeline-img -->
               
                            <div class="cd-timeline-content">
                                <h2 class="timeline-title"><cms:show timeline_content_title /></h2>
                                <p class="text-justify"><cms:show timeline_content_desc /></p>
                                <span class="cd-date">Step <cms:show k_count /></span>
                            </div> <!-- cd-timeline-content -->
                        </div> <!-- cd-timeline-block -->
                        </cms:show_repeatable>
               
                    </section> <!-- cd-timeline -->
            </div>
           </div>
        </div>
        <!-- Timeline -->
       
        <hr class="shadow" />
       
        <!-- Know More -->
        <div class="know-more">
           <div class="container">
               <div class="row">
                   <div class="col-md-12 text-center text-uppercase">
                       <h1>Know more about <i>"Aap Ke Sevak"</i></h1>
                    </div>
                    <div class="col-md-4">
                       <div class="padding-top-30"></div>
                        <a href="<cms:link 'concept.php' />">
                            <img class="know-more-image" src="images/about.png">
                            <div class="know-more-text text-center">
                                <div class="padding-top-10"></div>
                                <h3>About</h3>
                                <i>Concept</i>
                            </div>
                        </a>
                    </div>
                    <div class="col-md-4">
                       <div class="padding-top-30"></div>
                        <div class="arrow_box">
                           <div id="ticker">
                                <ul id="fade">
                                   <cms:embed 'testimonials.html' />
                                </ul>
                            </div>
                        </div>
                        <div class="know-more-text text-center">
                           <div class="padding-top-10"></div>
                           <h3>Testimonials</h3>
                            <i>In words of the Clients</i>
                        </div>
                    </div>
                    <div class="col-md-4">
                       <div class="padding-top-30"></div>
                        <a href="<cms:link 'faq.php' />">
                            <img class="know-more-image" src="images/faq.PNG">
                            <div class="know-more-text text-center">
                                <div class="padding-top-10"></div>
                                <h3>FAQ</h3>
                                <i>Freqently Asked Questions</i>
                            </div>
                        </a>
                    </div>
                </div>
            </div>
        </div>
        <!-- Know More -->
       
        <hr />
       
        <!-- Credability -->
        <div class="creds">
           <div class="container">
               <div class="row">
                   <div class="col-md-12 text-center">
                       <h1>Why should you prefer <i>"Aap Ke Sevak"</i> services?</h1>
                        <div class="padding-top-20"></div>
                    </div>
                    <div class="col-md-6">
                       <div class="box1">
                           <i class="fa fa-users fa-5x"></i>
                            <div class="padding-top-10"></div>
                            <h4><i>Social Initiative</i></h4>
                            <div class="padding-top-10"></div>
                            <p><i>Aap Ke Sevak</i> is a social initiative to help the under-privledged by providing them safe, secure and dignified jobs.</p>
                        </div>
                        <div class="padding-top-10"></div>
                    </div>
                    <div class="col-md-6">
                       <div class="box2">
                           <i class="fa fa-edit fa-5x"></i>
                            <div class="padding-top-10"></div>
                            <h4><i>Multiple Options</i></h4>
                            <div class="padding-top-10"></div>
                            <p>Select a <i>Sevak</i> according to your requirement, cooking, driving, plumbing, gardner and many more. With options of selecting skilled and experienced blue-collared work force.</p>
                        </div>
                        <div class="padding-top-10"></div>
                    </div>
                    <div class="col-md-6">
                       <div class="box1">
                           <i class="fa fa-eye fa-5x"></i>
                            <div class="padding-top-10"></div>
                            <h4><i>Verified Details</i></h4>
                            <div class="padding-top-10"></div>
                            <p>Get to see <i>Sevak</i> list that you can trust upon. Check their identity documents before contacting them and be at peace of mind.</p>
                        </div>
                        <div class="padding-top-10"></div>
                    </div>
                    <div class="col-md-6">
                       <div class="box2">
                           <i class="fa fa-thumbs-o-up fa-5x"></i>
                            <div class="padding-top-10"></div>
                            <h4><i>Ease of Access</i></h4>
                            <div class="padding-top-10"></div>
                            <p>Search, View and Shcedule interviews before hiring at your own ease and comfort. No more time co-ordination problems, no more waiting for long durations to get a <i>Sevak</i>.</p>
                        </div>
                        <div class="padding-top-10"></div>
                    </div>
                    <div class="col-md-6">
                       <div class="box1">
                           <i class="fa fa-clock-o fa-5x"></i>
                            <div class="padding-top-10"></div>
                            <h4><i>Quick &amp; Easy</i></h4>
                            <div class="padding-top-10"></div>
                            <p>It's Simple! It's Quick! It's Easy! You get to see and hire skilled employees for most of the household jobs. View and check their profiles. Hire them. All at your comfort.</p>
                        </div>
                        <div class="padding-top-10"></div>
                    </div>
                    <div class="col-md-6">
                       <div class="box2">
                           <i class="fa fa-shield fa-5x"></i>
                            <div class="padding-top-10"></div>
                            <h4><i>Data Security</i></h4>
                            <div class="padding-top-10"></div>
                            <p>Unlike most of the portals out there, we do not share the details of the employer with the job seekers unless you want so. Nor do we publicise your personal data (phone, address).</p>
                        </div>
                        <div class="padding-top-10"></div>
                    </div>
                </div>
            </div>
        </div>
        <!-- Credability -->
       
        <hr />
       
        <!-- Selection Process -->
        <div class="selection-process">
           <div class="container">
               <div class="row">
                    <div class="col-md-12 text-center">
                        <h1>How do we Shortlist a <i>"Sevak"</i></h1>
                        <div class="padding-top-20"></div>
                    </div>
                    <div class="col-md-4 text-center">
                       <span class="glyphicon glyphicon-check fa-5x"></span>
                        <div class="padding-top-10"></div>
                        <p>Address and Document Verification</p>
                    </div>
                    <div class="col-md-4 text-center">
                       <img src="images/icard.png" class="sp-image" />
                        <div class="padding-top-10"></div>
                        <p>Identity Document Verification</p>
                    </div>
                    <div class="col-md-4 text-center">
                       <span class="fa fa- fa-weixin fa-5x"></span>
                        <div class="padding-top-10"></div>
                        <p>Personal Interview</p>
                    </div>
                </div>
            </div>
        </div>
        <!-- Selection Process -->
       
        <hr>
       
        <!-- Media Mentions -->
        <div class="container">
           <div class="row">
               <div class="col-md-2 text-center">
                   <div class="box1">
                      <h1>Media Mentions</h1>
                    </div>
                </div>
                <div class="col-md-1">
                   <div class="vertical-border"></div>
                </div>
               <div class="col-md-9">
                   <marquee behavior="scroll" direction="left">
                      <ul class="media-mentions">
                            <cms:embed 'media-mentions.html' />
                       </ul>
                    </marquee>
                </div>
            </div>
        </div>
        <!-- Media Mentions -->
       
        <hr>
       
        <!-- Footer -->
        <footer>
           <div class="container">
               <div class="row">
                   <div class="col-md-4">
                       <div class="col-md-12">
                           <h4 class="text-center"><u>AapKeSevak.com</u></h4>
                            <div class="padding-top-10"></div>
                            <p class="text-justify">We are the pioneers in the city towards helping you hire blue-collared skilled work force at the ease of your home/office without a hassel. Be it a <i>Driver</i>, <i>Plumber</i>, <i>Maid</i>, <i>Medical Assistant</i>, we aim to provide to you the best possible and technically sound work force.</p>
                            <div class="padding-top-20"></div>
                            <h4 class="text-center"><u>Join Us</u></h4>
                            <div class="padding-top-10"></div>
                            <ul class="social-networking">
                               <li><a href="https://www.facebook.com/" target="_blank" class="fb"><i class="fa fa-facebook-official fa-2x"></i></a></li>
                                <li><a href="https://www.twitter.com/" target="_blank" class="tw"><i class="fa fa-twitter-square fa-2x"></i></a></li>
                                <li><a href="https://www.linkedin.com/" target="_blank" class="in"><i class="fa fa-linkedin-square fa-2x"></i></a></li>
                                <li><a href="https://plus.google.com/" target="_blank" class="gp"><i class="fa fa-google-plus-square fa-2x"></i></a></li>
                            </ul>
                        </div>
                    </div>
                    <div class="col-md-4">
                       <div class="col-md-12">
                           <h4 class="text-center"><u>Mandatory Disclosures</u></h4>
                            <div class="padding-top-10"></div>
                            <ul class="links">
                               <li><a href="#">Terms of Use</a></li>
                                <li><a href="#">Privacy Policy</a></li>
                                <li><a href="#">Important Decuments 1</a></li>
                                <li><a href="#">Important Decuments 2</a></li>
                            </ul>
                        </div>
                    </div>
                    <div class="col-md-4">
                       <h4 class="text-center"><u>Let's Partner and Grow</u></h4>
                        <div class="padding-top-10"></div>
                        <div class="padding-top-10"></div>
                        <form action="" method="get" name="partner">
                           <div class="col-md-6">
                              <input class="partner-form" name="fname" type="text" placeholder="First Name">
                            </div>
                            <div class="col-md-6">
                               <input class="partner-form" name="lname" type="text" placeholder="Last Name">
                            </div>
                            <div class="col-md-12">
                               <input class="partner-form" name="company" type="text" placeholder="Company">
                            </div>
                            <div class="col-md-12">
                               <input class="partner-form" name="mobile" type="text" placeholder="Mobile Number">
                            </div>
                            <div class="col-md-12">
                               <input class="partner-form" name="email" type="text" placeholder="Email">
                            </div>
                            <div class="col-md-12 text-center">
                               <button type="button" class="btn btn-default" aria-label="Left Align">
                                   <span class="glyphicon glyphicon-send" aria-hidden="true"></span> Send Mail
                                </button>
                            </div>
                        </form>
                    </div>
                </div>
               
                <hr class="footer">
               
                <div class="row">
                   <div class="col-md-6">
                       <div class="copyright">
                           <a href="#">&copy; AapKeSevak.com | 2015-2016</a>
                        </div>
                    </div>
                    <div class="col-md-6">
                       <div class="copyright">
                           <a href="http://www.genxcoders.in/" target="_blank" title="GenXCoders, Nagpur">Website Desgning and Development by <img src="images/genx.png" /></a>
                        </div>
                    </div>
                </div>
            </div>
        </footer>
        <!-- Footer -->
       
        <!-- Bootstrap's JavaScript plugins -->
        <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
        <script src="js/bootstrap.js"></script>
        <!-- Banner -->
        <!--<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js"></script>-->
      <script type="text/javascript" src="js/nivo-slider.js"></script>
        <script type="text/javascript">
         //<!--  Load the slider  -->
         $(window).load(function() {
            $('#slider').nivoSlider();
         });
      </script>
       
        <!-- Ticker -->
        <script type="text/javascript" src="testimonials/ticker00.js"></script>
        <script type="text/javascript">
            $(document).ready(function () {
                $('#fade').list_ticker({
                    speed: 6000,
                    effect: 'fade'
                });         
            })
        </script>
   </body>
</html>
<?php COUCH::invoke(); ?>


This is my login page code:
Code: Select all
<?php require_once( '../couch/cms.php' ); ?>
    <cms:template title='Login' hidden='1' />

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge">
        <meta name="viewport" content="width=device-width, initial-scale=1">
       
        <!-- Site Title -->
        <title>Aap Ke Sevak - Login</title>
       
        <!-- Stylesheets -->
        <link href="../css/bootstrap.css" rel="stylesheet">
        <link href="../css/genxcoders.css" rel="stylesheet">
        <link href="../css/font-awesome.css" rel="stylesheet">
        <!-- Banner -->
        <link rel="stylesheet" href="../nivo-themes/default/default.css" type="text/css" media="screen" />
        <link rel="stylesheet" href="../css/nivo-slider.css" type="text/css" media="screen" />
        <!--<link rel="stylesheet" href="style.css" type="text/css" media="screen" />-->
       
        <!-- Ticker -->
        <link type="text/css" href="../testimonials/style000.css" rel="stylesheet" />
       
        <!--[if lt IE 9]>
        <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
        <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
        <![endif]-->
    </head>
    <body>
       
        <!-- Navigation -->
        <nav class="navbar navbar-default navbar-fixed-top" role="navigation">
           <div class="top-bar"></div>
           <div class="container">
                <div class="navbar-header">
                    <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
                        <span class="sr-only">Toggle navigation</span>
                        <span class="icon-bar"></span>
                        <span class="icon-bar"></span>
                        <span class="icon-bar"></span>
                    </button>
                    <a class="navbar-brand" href="index.html">
                       <img class="logo" src="../images/aap-ke-sevak-logo.png" alt="Aap Ke Sevak" />
                    </a>
                </div>
           
                <!-- Collect the nav links, forms, and other content for toggling -->
                <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
                    <ul class="nav navbar-nav">
                        <cms:embed 'menu.html' />
                    </ul>
                    <ul class="nav navbar-nav navbar-right">
                       <form class="navbar-form navbar-left" role="search">
                            <div class="form-group">
                                <input type="text" class="form-control" placeholder="Aap Ke Sevak...">
                            </div>
                            <button type="submit" class="btn btn-default">Search</button>
                        </form>
                     <li class="login"><a href="#">Login</a></li>
                     <li class="register"><a href="#">Register</a></li>
                  </ul>
              </div><!-- /.navbar-collapse -->
           </div><!-- /.container-fluid -->
        </nav>
        <!-- Navigation -->
       
        <div class="padding-top-50"></div>
        <div class="padding-top-50"></div>
       
        <!-- Blocks -->
        <div class="container">
           <div class="row">
                <div class="col-md-3">
                    &nbsp;
                </div>
                <div class="col-md-6">
                   <cms:if k_logged_in >

                        <!-- this 'login' template also handles 'logout' requests. Check if this is so -->
                        <cms:set action="<cms:gpc 'act' method='get'/>" />
                   
                        <cms:if action='logout' >
                            <cms:process_logout />
                           <cms:else /> 
                            <!-- what is an already logged-in member doing on the login page? Send back to homepage. -->
                            <cms:redirect k_admin_link />
                        </cms:if>
                   
                    <cms:else />
                       
                        <!-- show the login form -->
                        <h1>Login</h1>
                       
                        <cms:form method='post' anchor='0'>
                            <cms:if k_success >
                                <!--
                                    The 'process_login' tag below expects fields named
                                    'k_user_name', 'k_user_pwd' and (optionally) 'k_user_remember', 'k_cookie_test'
                                    in the form
                                -->
                                <cms:process_login />
                               
                            </cms:if>
                           
                            <cms:if k_error >
                                <h3><font color='red'><cms:show k_error /></font></h3>
                            </cms:if>
                           
                           
                            Username: <br/>
                            <cms:input class="partner-form" type='text' name='k_user_name' /> <br/>
                           
                            Password: <br />
                            <cms:input class="partner-form" type='password' name='k_user_pwd' /> <br/>
                           
                            <!-- if 'remember me' function is not required, the following checkbox can be omitted -->
                            <cms:input type='checkbox' name='k_user_remember' opt_values='Remember me=1' /> <br/>
                           
                            <input type="hidden" name="k_cookie_test" value="1" />
                           
                            <button type="submit" value="Login" name="submit" class="btn btn-default" aria-label="Left Align" />
                                <span class="fa fa-unlock" aria-hidden="true"></span> Login
                            </button>
                        </cms:form>
                       
                        <!-- optionally display links for 'Create account' and 'Lost password' -->
                        <br />
                        <cms:if k_user_registration_template >
                            Not signed up yet? <a href="<cms:link k_user_registration_template />" />Create an account here.</a> <br>
                        </cms:if>
                        <cms:if k_user_lost_password_template >
                            Forgot your password? <a href="<cms:link k_user_lost_password_template />" />Click here.</a> <br>
                        </cms:if>
                       
                       
                    </cms:if>
                    <!--<form action="" method="get" name="login">
                        <div class="col-md-4 text-right">
                            Username (Email)
                        </div>
                        <div class="col-md-8">
                            <input class="partner-form" name="username" type="text">
                        </div>
                   
                        <div class="col-md-4 text-right">
                            Password
                        </div>
                        <div class="col-md-8">
                            <input class="partner-form" name="password" type="password">
                        </div>
                        <div class="col-md-12 text-center">
                            <button type="button" class="btn btn-default" aria-label="Left Align">
                                <span class="fa fa-key" aria-hidden="true"></span> Login
                            </button>
                        </div>
                    </form>-->
                </div>
                <div class="col-md-3">
                    &nbsp;
                </div>
            </div>
        </div>
        <!-- Blocks -->
       
        <hr />
       
        <!-- Selection Process -->
        <div class="selection-process">
           <div class="container">
               <div class="row">
                    <div class="col-md-12 text-center">
                        <h1>Testimonials <small>In words of the client</small></h1>
                        <div class="padding-top-20"></div>
                    </div>
                    <div class="col-md-12 text-center">
                        <div id="ticker">
                            <ul id="fade">
                                <li>
                                    <i>"Thanks guys, keep up the good work! Really good. Great job, I will definitely be hiring again!"</i>
                                    <div class="padding-top-10"></div>
                                    - Aditi R.
                                </li>
                                <li>
                                    <i>Just what I was looking for.</i>
                                    <div class="padding-top-10"></div>
                                    - Mahima S.
                                </li>
                                <li>
                                    <i>We've used Aap Ke Sevak for the last few months. Man, this thing is getting better and better as I learn more about it. Wow what great service, I love it! Nice work on your Aap Ke Sevak.</i>
                                    <div class="padding-top-10"></div>
                                    - Priya R.
                                </li>
                            </ul>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <!-- Selection Process -->
       
        <hr>
       
        <!-- Media Mentions -->
        <div class="container">
           <div class="row">
               <div class="col-md-2 text-center">
                   <div class="box1">
                      <h1>Media Mentions</h1>
                    </div>
                </div>
                <div class="col-md-1">
                   <div class="vertical-border"></div>
                </div>
               <div class="col-md-9">
                   <marquee behavior="scroll" direction="left" onmouseover="this.stop();" onmouseout="this.start();" scrollamount="3">
                      <ul class="media-mentions">
                            <li><a href="http://www.google.com/" target="_blank"><img class="media-mention-image" src="../images/aap-ke-sevak-logo.png"></a></li>
                            <li><a href="http://www.google.com/" target="_blank"><img class="media-mention-image" src="../images/GenXCoders-LOGO.png"></a></li>
                            <li><a href="http://www.google.com/" target="_blank"><img class="media-mention-image" src="../images/aap-ke-sevak-logo.png"></a></li>
                            <li><a href="http://www.google.com/" target="_blank"><img class="media-mention-image" src="../images/GenXCoders-LOGO.png"></a></li>
                            <li><a href="http://www.google.com/" target="_blank"><img class="media-mention-image" src="../images/aap-ke-sevak-logo.png"></a></li>
                       </ul>
                    </marquee>
                </div>
            </div>
        </div>
        <!-- Media Mentions -->
       
        <hr>
       
        <!-- Footer -->
        <footer>
           <div class="container">
               <div class="row">
                   <div class="col-md-4">
                       <div class="col-md-12">
                           <h4 class="text-center"><u>AapKeSevak.com</u></h4>
                            <div class="padding-top-10"></div>
                            <p class="text-justify">We are the pioneers in the city towards helping you hire blue-collared skilled work force at the ease of your home/office without a hassel. Be it a <i>Driver</i>, <i>Plumber</i>, <i>Maid</i>, <i>Medical Assistant</i>, we aim to provide to you the best possible and technically sound work force.</p>
                            <div class="padding-top-20"></div>
                            <h4 class="text-center"><u>Join Us</u></h4>
                            <div class="padding-top-10"></div>
                            <ul class="social-networking">
                               <li><a href="https://www.facebook.com/" target="_blank" class="fb"><i class="fa fa-facebook-official fa-2x"></i></a></li>
                                <li><a href="https://www.twitter.com/" target="_blank" class="tw"><i class="fa fa-twitter-square fa-2x"></i></a></li>
                                <li><a href="https://www.linkedin.com/" target="_blank" class="in"><i class="fa fa-linkedin-square fa-2x"></i></a></li>
                                <li><a href="https://plus.google.com/" target="_blank" class="gp"><i class="fa fa-google-plus-square fa-2x"></i></a></li>
                            </ul>
                        </div>
                    </div>
                    <div class="col-md-4">
                       <div class="col-md-12">
                           <h4 class="text-center"><u>Mandatory Disclosures</u></h4>
                            <div class="padding-top-10"></div>
                            <ul class="links">
                               <li><a href="#">Terms of Use</a></li>
                                <li><a href="#">Privacy Policy</a></li>
                                <li><a href="#">Important Decuments 1</a></li>
                                <li><a href="#">Important Decuments 2</a></li>
                            </ul>
                        </div>
                    </div>
                    <div class="col-md-4">
                       <h4 class="text-center"><u>Let's Partner and Grow</u></h4>
                        <div class="padding-top-10"></div>
                        <div class="padding-top-10"></div>
                        <form action="" method="get" name="partner">
                           <div class="col-md-6">
                              <input class="partner-form" name="fname" type="text" placeholder="First Name">
                            </div>
                            <div class="col-md-6">
                               <input class="partner-form" name="lname" type="text" placeholder="Last Name">
                            </div>
                            <div class="col-md-12">
                               <input class="partner-form" name="company" type="text" placeholder="Company">
                            </div>
                            <div class="col-md-12">
                               <input class="partner-form" name="mobile" type="text" placeholder="Mobile Number">
                            </div>
                            <div class="col-md-12">
                               <input class="partner-form" name="email" type="text" placeholder="Email">
                            </div>
                            <div class="col-md-12 text-center">
                               <button type="button" class="btn btn-default" aria-label="Left Align">
                                   <span class="glyphicon glyphicon-send" aria-hidden="true"></span> Send Mail
                                </button>
                            </div>
                        </form>
                    </div>
                </div>
               
                <hr class="footer">
               
                <div class="row">
                   <div class="col-md-6">
                       <div class="copyright">
                           <a href="#">&copy; AapKeSevak.com | 2015-2016</a>
                        </div>
                    </div>
                    <div class="col-md-6">
                       <div class="copyright">
                           <a href="http://www.genxcoders.in/" target="_blank" title="GenXCoders, Nagpur">Website Desgning and Development by <img src="../images/genx.png" /></a>
                        </div>
                    </div>
                </div>
            </div>
        </footer>
        <!-- Footer -->
       
        <!-- Bootstrap's JavaScript plugins -->
        <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
        <script src="../js/bootstrap.js"></script>
        <!-- Banner -->
        <!--<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js"></script>-->
      <script type="text/javascript" src="../js/nivo-slider.js"></script>
        <script type="text/javascript">
         //<!--  Load the slider  -->
         $(window).load(function() {
            $('#slider').nivoSlider();
         });
      </script>
       
        <!-- Ticker -->
        <script type="text/javascript" src="../testimonials/ticker00.js"></script>
        <script type="text/javascript">
            $(document).ready(function () {
                $('#fade').list_ticker({
                    speed: 6000,
                    effect: 'fade'
                });         
            })
        </script>
   </body>
</html>
<?php COUCH::invoke(); ?>


And this is the code of my loggedin.php dummy page:
Code: Select all
<?php require_once( 'couch/cms.php' ); ?>
<cms:template title='loggedin'>

</cms:template>

<cms:if k_logged_out >
    <cms:redirect "<cms:login_link />" />
</cms:if>

<cms:if k_logged_in >
    <cms:if k_user_access_level ge '7' >
        <cms:redirect k_admin_link />
    </cms:if>
</cms:if>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
       <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
       <title>Logged In</title>
    </head>

   <body>
      You are logged in "finally"!!!
        <cms:show k_user_name /> | <cms:show k_user_access_level />
        <!-- also give an option to logout -->
       <a href="<cms:process_logout />">logout</a>
   </body>
</html>
<?php COUCH::invoke(); ?>


There is something that i am missing.
Image
where innovation meets technology
The problem lies in your loggedin.php template here -
Code: Select all
<!-- also give an option to logout -->
<a href="<cms:process_logout />">logout</a>

The code above will execute for any non-admin user who has just logged-in and the <cms:process_logout> tag will, guess what, immediately try to log her off.

Loggin-off action requires a security token which is not there and hence the "Security tokens do not tally for executing this action. Please try again." message.

I'm sure you intended to provide the used a logoff link and not to actually log her off by your code above.

The correct code to use would be this -
Code: Select all
<!-- also give an option to logout -->
<a href="<cms:logout_link />">logout</a> 

Please use that and things should work as expected.
I will give a little heads up for what I am doing this "Membership" type of site.

Actually the site that I am doing right now is for a "Blue Collar Job". very similar to http://www.bookmybai.com or http://www.helper4u.in.

What I want to achieve with the member module (extended) is that, from the login page, the following types of users should be able to login:

1. Site Owner (Super Admin): Should be able to administer the site (i.e, on logging in, the site owner should be shown the couch admin panel).

2. Other Users:
Individual Job Seeker: Should be able to login and fill out a form. The form will contain, the individuals photo, identification document(s), basic details (name, age, sex, etc), contact details (address, contact number) and most importantly specify what kind of a job they are looking for (e.g., driver, maid, nanny, etc. from a dropdown). Once done, the individual should be able to view his/her details (profile) and edit any of the details as and when required. (should select user type as individual during registration)
Agency (Head Hunters): Should be able register, pay a fees to get an quarterly/bi-annual/annual membership and then be able to fill out a form (exactly similar to the form as in Individual Job Seekers). Every time the agency creates a new job seeker account, the job seeker should be tagged with the agency name, so that the employer should call the agency for further processing. The agency should be able to edit the job seekers profile.
Employer: Should be able to register and then search for the job seekers. Once the employer zeros upon a particular job seeker:
(i) if job seeker is individual: then the contact details of the job seeker should be displayed.
(ii) if agency based job seeker: then contact details of the agency should be displayed.
But, in order to view the contact details, the Employer should buy a pack. Let us say, the employer wants to hire a driver, then the employer will have to buy a Driver Pack. This driver pack has a validity associated with it of (say) 7days. The employer can then see only the contact details of the people who have registered as job seeker type - driver (and not of others). Once the 7 days period expires, the contact details viewing should be disabled. So whenever the employer wants to hire a blue collared employee, he/she should need to pay for the appropriate pack.

Once the above is in place, the results of the submitted forms of the Individual Job Seeker and Agency (Head Hunters) should be displayed in search.

What and how shall I achieve this. Also, The menu options according to the logged in user should change. For example, Site owner ill go directly to the couch admin panel, but if:
1. Individual Job Seeker logs in: then the menu items should have option of view/edit profile and logout only.
2. Agency (Head Hunters) logs in: then the menu items should have the option of view/edit all forms (even if it is from the couch panel, it wont matter, until they are shown only the forms submitted by them), add new job seeker, logout.
3. Employer logs in: then the menu items should be have the option to view/edit his/her profile, Search Job Seekers (when logged in, the basic page will display a search filter in the body of the page), Select Package to Purchase, View validity of purchased package, view transaction history, logout. Wherein, View validity and Transaction history can be clubbed in and shown as a list.

I am in the process of designing the pages in accordance to the above. But I need to simultaneously also code it in to Couch.

Please help me for the same with tips.

Regards,
Aashish
Image
where innovation meets technology
BUMP!!!
Image
where innovation meets technology
Aashish, this is very interesting. I would like to take part in this project. I see the application in other fields, like real estate. If you are interested, create a topic in General Discussion instead and let's get started!
Join COUCH:TALK channel here https://t.me/couchcms_chat
Ryazania — a framework to boost productivity with Add-ons viewtopic.php?f=2&t=13475
Support my efforts to help the community https://boosty.to/trendo/donate
Bump :?:
Image
where innovation meets technology
16 posts Page 2 of 2