Jump to content
Local
Картавый

Написать условия используя сессию

Recommended Posts

Всем привет , ребята начал пилить сайт для работы, нужно написать условие :

Если у пользователя в таблице user поле succes == 1 показать содержимое страницы иначе перекинуть его на index.php

Помогите соответственно написать такой скрипт используя сессию

Edited by Картавый

Share this post


Link to post
Share on other sites

Оффтопик.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By fix3r
      Народ помогите новичку, поставил abills, настроил pppoe-server, все работает на компьютере хорошо, когда подключаю маршрутизатор, не поднимает сессию, смотрю логи пиши что сессия поднялась на 10 сек
       
       
       
      info: ppp0:  [0;39msend [RADIUS(1) Accounting-Request id=1 <User-Name "fix3r"> <NAS-IP-Address 127.0.0.1> <NAS-Port 0> <NAS-Port-Type Virtual> <Tunnel-Type L2TP> <Service-Type Framed-User> <Framed-Protocol PPP> <Calling-Station-Id "00:1a:4b:90:3e:3b"> <Called-Station-Id "ec:a8:6b:f7:e4:8a"> <Acct-Status-Type Start> <Acct-Authentic RADIUS> <Acct-Session-Id "1534ee7faeb1c2be"> <Acct-Session-Time 0> <Acct-Input-Octets 0> <Acct-Output-Octets 0> <Acct-Input-Packets 0> <Acct-Output-Packets 0> <Acct-Input-Gigawords 0> <Acct-Output-Gigawords 0> <Framed-IP-Address 172.20.0.81>]
      [1;32m[2017-03-11 21:14:59]:  info: ppp0: [0;39mrecv [RADIUS(1) Accounting-Response id=1] [1;34m[2017-03-11 21:14:59]: debug: ppp0: [0;39mpppoe: ppp started [1;32m[2017-03-11 21:14:59]:  info: ppp0: [0;39mpppd_compat: ip-up started (pid 3086) [1;32m[2017-03-11 21:14:59]:  info: ppp0: [0;39mpppd_compat: ip-up finished (1) [1;32m[2017-03-11 21:15:01]:  info: ppp0: [0;39mrecv [LCP TermReq id=9] [1;32m[2017-03-11 21:15:01]:  info: ppp0: [0;39msend [LCP TermAck id=9] [1;34m[2017-03-11 21:15:01]: debug: ppp0: [0;39mppp_terminate [1;32m[2017-03-11 21:15:01]:  info: ppp0: [0;39msend [RADIUS(1) Accounting-Request id=1 <User-Name "fix3r"> <NAS-IP-Address 127.0.0.1> <NAS-Port 0> <NAS-Port-Type Virtual> <Tunnel-Type L2TP> <Service-Type Framed-User> <Framed-Protocol PPP> <Calling-Station-Id "00:1a:4b:90:3e:3b"> <Called-Station-Id "ec:a8:6b:f7:e4:8a"> <Acct-Status-Type Stop> <Acct-Authentic RADIUS> <Acct-Session-Id "1534ee7faeb1c2be"> <Acct-Session-Time 5> <Acct-Input-Octets 702> <Acct-Output-Octets 538> <Acct-Input-Packets 11> <Acct-Output-Packets 9> <Acct-Input-Gigawords 0> <Acct-Output-Gigawords 0> <Framed-IP-Address 172.20.0.81> <Acct-Terminate-Cause User-Request>] [1;32m[2017-03-11 21:15:02]:  info: ppp0: [0;39mrecv [RADIUS(1) Accounting-Response id=1] [1;34m[2017-03-11 21:15:02]: debug: ppp0: [0;39mlcp_layer_finish [1;34m[2017-03-11 21:15:02]: debug: ppp0: [0;39mauth_layer_finish [1;34m[2017-03-11 21:15:02]: debug: ppp0: [0;39mauth_layer_finished [1;34m[2017-03-11 21:15:02]: debug: ppp0: [0;39mccp_layer_finish [1;34m[2017-03-11 21:15:02]: debug: ppp0: [0;39mccp_layer_finished [1;34m[2017-03-11 21:15:02]: debug: ppp0: [0;39mipcp_layer_finish [1;34m[2017-03-11 21:15:02]: debug: ppp0: [0;39mipcp_layer_finished [1;34m[2017-03-11 21:15:02]: debug: ppp0: [0;39mipv6cp_layer_finish [1;34m[2017-03-11 21:15:02]: debug: ppp0: [0;39mipv6cp_layer_finished [1;32m[2017-03-11 21:15:02]:  info: [0;39mrecv [PPPoE PADT 00:1a:4b:90:3e:3b => ec:a8:6b:f7:e4:8a sid=0014] [1;32m[2017-03-11 21:15:02]:  info: ppp0: [0;39mpppd_compat: ip-down started (pid 3094) [1;32m[2017-03-11 21:15:02]:  info: ppp0: [0;39mpppd_compat: ip-down finished (0)      Спасибо зарания    
×