Authentication of the user - connection to different pages / PHP script / DW8

Hi, I want to develop a PHP script to a login page that will direct users to different URLS depending on the URL address associated with their individual files stored in a MySQL database.

I've set up a MySQL database that includes the fields username (1) (2) address, password and the URL (3).  I use Dreamweaver 8 and am relying on server behavior 'user log '.

After selection all 3 fields in the table x y at - it a specific code that can be inserted in the option "If the connection is successful, go to" resolve this query?

The following link refers to what I'm looking for... .but it does not provide an answer for PHP/MySQL!

http://kb2.Adobe.com/CPS/158/tn_15881.html

Thank you, Simon

My Code so far:

@mysql_select_db ($database_connLogin, $connLogin);
$query_login = "SELECT username, password FROM USERS";
$login = mysql_query ($query_login, $connLogin) or die (mysql_error ());
$row_login = mysql_fetch_assoc ($login);
$totalRows_login = mysql_num_rows ($login);
? > <? PHP

Validate request to connect to this site.
If (! isset {})
session_start();
}

$loginFormAction = $_SERVER ['PHP_SELF'];
If (isset($_GET['accesscheck'])) {}
$_SESSION ['PrevUrl'] = $_GET ['accesscheck"];
}

If (isset($_POST['userName'])) {}
$loginUsername = $_POST ['userName'];
$password = $_POST ["password"];
$MM_fldUserAuthorization = "";
$MM_redirectLoginSuccess = 'members.php ';
$MM_redirectLoginFailed = "tryAgain.php";
$MM_redirecttoReferrer = false;
@mysql_select_db ($database_connLogin, $connLogin);

$LoginRS__query = sprintf ("SELECT username, password AND password OF USERS WHERE userName = %s is %s",
GetSQLValueString ($loginUsername, "text"), GetSQLValueString ($password, "text"));

$LoginRS = mysql_query ($LoginRS__query, $connLogin) or die (mysql_error ());
$loginFoundUser = mysql_num_rows ($LoginRS);
If {($loginFoundUser)
$loginStrGroup = "";

I think you can ignore it. Once you edit the code of a server behavior, Dreamweaver can recognize it is no longer. That's why you get the error message.

Tags: Dreamweaver

Similar Questions

  • column of a link with the ability to send the user on several different pages

    using apex 4.0

    In my example:
    User: Secretary for a large company in charge of the HR database, enter new employees, reorganizing the employees, managers, etc.).
    Employee: A person working for the company whose information is in the database.

    The problem: my client wants the data divided into several subcategories, so, for example, it would be like sales, managers, etc., using the human resources database. The main page of this project contains a table that lists all the company employees, low to high. There is a column of navigation with several links to predefined reports filter that filters data on the question whether the employee in the database is a seller, Manager, etc.. If the user clicks on the link change, it will take them to a page master detail where the upper part is general information and background tasks of the employee. The problem is that, according to his level, there may be additional details that the user will want to change, such as if the employee is responsible for, the user will also want to see another table a list of employees by the Manager. There is also a second level of managers who will have a table of managers of this person manages. The dream is that there is a list of links above the tabular presentation, which will allow the user to choose what table they want to see. I thought about the following:

    1. create several copies of the home page, one for each subcategory, so that she will be the link change correct.
    Positives - Simple, easy, I know how to.
    Negative - would like it to appear on the same page, such that if the user deletes / adds a column in a single page, this change would occur on all other pages. I also have to make the same changes on several pages, one is required.

    2. create a text field hidden on the page that records the last link, what they clicked. When the user clicks on the link change, some kind of javascript selects the right page to go to in view of what is in the box.
    Positives - seems simple enough, but I have not tapped into javascript a lot
    Negative - not for sure if it is even feasible, would need help

    3. create a subpage of master-detail, that holds all the necessary tables and hide those that are not. When the user clicks on a link, the link triggers the current table to hide and another to appear.
    good points - all in the same place, that one page to link to main page
    negatives - it would require at least 5 tables on one page and I do not know how the apex would like that. I also don't like the idea of the page calling itself when the user is looking at senior managers and to display a lower Manager / employee.

    4. a creative method / useful / incredibly simple bore by a user of this forum.

    Because I'm in a very short, customer review period next week, I implémenterai #1 because it is the easiest and most straight forward, but I would like to know your thoughts to make much cleaner.

    Published by: rabbitman June 4, 2012 08:07

    I don't know if it's the best way to accomplish what you want, but it worked for me.

    Change the link in the column to specify the following for a target URL, where EMP_NO and EMP_TYPE are columns of the report.

    JavaScript:apex. Submit('#EMP_NO##EMP_TYPE#')

    In the processing of the page after several branches to different pages depending on the type of employee. For example,.

    Branch to Page 2: Condition = instr (: REQUEST, 'SALES') > 0
    Branch to Page 3: Condition = instr (: REQUEST, "MANAGER") > 0
    Branch to Page 5: Condition = instr (: REQUEST, 'PRÉSIDENT') > 0

    Since the: APPLICATION also has the EMP_NO, you can use this to set the value of the EMP_NO for the target page, pull up to the employee's file.

    Natasha

  • display the text in the navigation bar when the user connects

    Hi all

    I'm (still ) on Apex 4.2.6.

    Currently, I have in my page templates, the following code snippet:

          <div class="logoBar">

              <img src="#IMAGE_PREFIX#themes/theme_125/images/logo_.png" />

              <h1><a href="#HOME_LINK#" id="uLogo">#LOGO#</a></h1>

            <div class="userBlock">

              <span>Username: &APP_USER.</span>

              #NAVIGATION_BAR#

            </div>

          </div>

    I have an obligation to display the user name (APP_USER) and of the company the user works for point Application AI_COMPANY, only when the user is connected. When the user is not connected; instead of these elements, I must show a connection link. Well, I know how to display a link to the login page, only when the user is not authenticated, using the navigation bar. Currently, when a user is not authenticated; the page shows: username: person. It's because he's in my page template. How can I show only the user name when the user connects? And then only display the name of the company?

    My first thought was to add an item in the navigation bar. But these elements comes in the form of links. Is it possible to add a navigation bar element and let it display as text? Of course, I could write a dynamic action on page 0 to remove the link, but I'm looking for a nicer sollution or better.

    I have apreciate your help!

    I take it, you use the same model of your home page and login page.

    You could use 2 different models or get out your elements in your model and put them in page 0.

    You can then make them conditional based on the number of page

    Gus

  • The user connection speed

    Hello

    I have AROUND 1252 connected to WISN, active 802.11n in the network,

    Broadcast SSID HR and ADMIN 2
    HR without authentication and unsecured... ADMIN with active WEP,

    When the user connect to HR SSID, it must be connected to a speed 72Mbps,
    but the problem is when the user connects to ADMIN SSID, the user must be connected to 54Mbps always,

    can someone tell me the reason for the same thing.

    Hi Kiran,

    802.11 N speeds has certain criteria... they are...

    The WIFI network should be...

    1 > auth with no security and encryption + all MCS rates enabled + WMM enabled.

    2 > 2 WPA - AES encryption + all rates active MCS + WMM active.

    Since your second WLAN uses WEP, speeds N shouldn't!

    Let me know if that answers your question...

    Concerning
    Surendra
    ====
    Please do not forget to note positions that answered your question and mark as answer or was useful

  • ACS Auth: Use of group data for the authentication of the user-&gt; security problem?

    IM only using a VPN-installation (router, ACS, Cisco VPN Client) and I noticed that the name of the Group and the Group decrypted password can also be used in the second step of the authentication (the extent of authentication or authentication of users), which is a big security concern. What wrong with my setup.

    For the test I have set up a VPN configuration as described in cisco documents. Here, it also works. The identification information of the Working Group in the authentication of the user, too, which is quite logical, because the group credentials are also a user in the database of GBA. Of course, this user can be authenticated in the user authentication process.

    Who is wrong? How other admins to solve this problem? Am I wrong in my approach?

    Thank you!

    Yes, permission will have password for "cisco", at least for isakmp and pki. The group will send its name and password Cisco to receive the av pairs (ASA has a function to create a "good word of different past" but he's not here on IOS, AFAIR)

    It is a restriction known - you should not use the same server for authentication and authorization, with IOS and ASA.

    Did you give this property (either / or):

    -local isakmp authorization

    -l' authentication certificate (Group)

    -sharing features for authentication and authorization between servers.

    I don't think we can do much wise configuration to prohibit this behavior.

    Edit: spelling correction.

  • How to get the authentication of the user for the link of the Questionnaire Survey Builder?

    How to get the authentication of the user for the link of the Questionnaire Survey Builder?

    Page 100

    The content can be dynamic and the link is unique to the participant, but they all go to Page 100, which has an alias of Q. The link is unique because of the value of the request passed not because of the page.

    Thank you

    -Jorge

  • Using Windows XP with an access switched. How can I stop the network Dialer to invite the user connect even if I checked never dial a connection in Control Panel, then apply, then OK?

    Using Windows XP with an access switched. How can I prevent the network Dialer to invite the user connect even if I checked: never establish a connection to the Control Panel, then apply, then OK? She comes right back in a few minutes for: always connect by default. Help! Control panel Connections tab doesn't really seem to apply my change to never establish a connection right back to always make the default connection. What else is there to do?

    Hi Richard,

    You did it all change hardware or software on your computer before this problem?

    You can follow this link & check if the problem persists:

    Network connections and remote access troubleshooting

    Hope the helps of information.

  • How to access the software so that I just paid. I assigned to a user. The user connects and subscription is not found. The site seems to crash randomly and just sends me in circles. How can I get a refund is my next question.

    How to access the software so that I just paid. I assigned to a user. The user connects and subscription is not found. The site seems to crash randomly and just sends me in circles. How can I get a refund is my next question.

    [Profanity removed... MOD]

    Hello

    I just checked the details of your team, and the license that you have assigned intervenes as well on the same Adobe ID.

    Please see the below help documents:

    Applications creative Cloud back in test mode after an update until 2015 for CC

    Solutions to connection errors, activation and connection with creative Cloud applications and Creative Suite

    Kind regards

    Sheena

  • DPS is their function where the user can choose which pages they want to keep, to build a custom (build yours) version for themselves.

    DPS is their function where the user can choose which pages they want to keep, to build a custom (build yours) version for themselves.

    N °

    Neil

  • Changing the components of the user interface on a page programmatically

    Do I need auto-bind backing bean if I have to programmatically change the attributes, the events of the user interface on a page components? I'm sure that Yes. Thus, each jsf page must have a bean of support to do the above and a bean managed to retrieve/store data? It seems that backing bean is more than enough. Why do I need a managed bean? Is there a way to delete unwanted ui components accessors in the bean to support? Thank you.

    You need a support to programaticaly access bean and change elements on your page.
    But you do not need to expose each component on your page in the bean support - the best practice is to expose a few components that actually access you.
    So instead of using the auto-bind tge option that offers JDeveloper, create your page without a bean of support. Then when you need to access a specific object in your code, go to the attribute binding of this object in the property inspector, click the > change to his right and JDeveloper will give you a quick way to expose this specific component in a pod of support.

  • Display the results on a different Page

    Hi, I have this Web page where I have a search engine and can someone search for a name, the problem im facing is I want to show all results that are 'like' what the person has typed in the search engine and display them on a different web page

    for the moment I set it up to show the search results on the same page that contains the search form and it shows the matches by a < cfloop query = "" > where name LIKE '% #form.search#%' but the problem im facing is I want to see all the results on a different page, but I don't know how to get these results to display on a different Web page can someone please help me? any help will be appreciated... Thanks in advance...

  • view the code for two different pages at a time

    HI - in other editors I've used I've always been able to implement the code for two different pages so that I can watch side by side to compare. I can't find a way to do this in Dreamweaver. Anyone know if this is possible?
    Thank you

    Found. Always after asking for help! This is the "cascade" in the Windows menu.
    Thanks anyway!

  • See the users that you have shared a Script with

    Is there a way to see the users who you have shared a script with?  I spent in and added the email addresses of a few people with different roles and wating to do a couple things:

    • Make sure that everyone who needs to access, I added
    • Who are the co-authors or commentators on the color code

    I don't see anywhere that I can view those which I gave access, to check or do one of those two things.

    Your help is appreciated.

    So that the script is not accepted by all the world appears as a Document not shared. If you click not shared Document your name would appear there with the owner role. As soon as the first person to accept the script, it looks like Shared Document (2 users) and clicking on it would reveal your name and the name of the worker. This number and the information contained in this area would be keep to increase as users increasingly accept the sharing of the script.

  • Once logged in the way to direct the user to their unique page based on their DB info

    OK, I got the user who creates a username, password and id. Once they were connecting I want to be able to send them to a page containing information of their information entered into the database. I was thinking session varialble load information contained in the database based on the id of the user, so that's what I did

    Here is the code

    Login page php check

    <?

    $userid = mysql_real_escape_string ($userid);

    $password = mysql_real_escape_string ($password);

    If ($rec = mysql_fetch_array (mysql_query ("" SELECT * FROM Hdatabase WHERE userid = '$userid' AND password = '$password' ""))) {}

    If (($Rec['userid']==$UserID) & &($rec['password']==$password)) {}

    include "include/newsession.php;

    echo "< class p = 'data' > < center > connected successfully, < br > < br > < a href ="logout.php"> LOGOUT < /a > < br > < br > < a href = welcome.php > click here if your browser does not automatically redirect, or you don't want to wait." < /a > < br / > < / center > ';

    Print "< script >"

    Print "= self.location" welcome.php "; » ; Comment this line if you do not want to redirect

    print '< /script > ';

    }

    }

    else {}

    session_unset();

    echo "< police ="Verdana"size ="2"color = red > incorrect Login." Use your correct username and password and try < br > < Center > < input type = "button" value = "Retry" onClick = 'history.go(-1)' > < / center > ';

    }

    ? >

    It's the php newsessions

    <? PHP

    error_reporting(E_ERROR |) E_PARSE | E_CORE_ERROR);

    $session ['id'] = session_id ();

    $session ['userid'] = $userid;

    $session ['name'] = $name; This is one that I added

    echo $session ['userid'];

    ? >

    This is where I even if I added new sessions then place them in the home page?

    Add it as a new session, I added the welcome.php

    <?

    echo "$session [name];

    ? >

    I hope you can help

    Create a new page with a form and 2 text fields, then go to "Server behaviors" ==> "User authentication" ==> "User login" and follow the instructions to create a login page.

  • Several redirects URL after authentication of the user based on roles

    Hello
    I want to make several url redirects after login. It is:

    If a user connects to I want to open - 1.html.

    If user B logs I want open - 2.html.

    Please tell if this can be done in OAM or not and how do?

    First, create a simple policy area with Basic authentication scheme and test if you can you connect and see the home page of your application.

    Suppose you want to make redirects based on an attribute called user:
    myDepartment = IT, HR, finance, Support, HelpDesk
    Therefore, you should design 5 URLS for each of the departments above.

    Make sure that "myDepartment" is indexed in LDAP.

    The next step:
    Create a domain policy with the resources and rule rule & authentication check. Now, for the authorization, set the following:

    Authorization rules (5):
    AuthZ4IT, AuthZ4HR, AuthZ4Finance, AuthZ4Support, AuthZ4HelpDesk

    Definition of each:
    AuthZ4IT-> General:
    Enable wins: Yes
    AuthZ4IT-> Actions-> success of permission-> URL of Redirection:
    http://www.mycompany.com/it
    AuthZ4IT-> access-> rule:
    LDAP: / / / o = company, c = us? void? (myDepartment = IT)
    AuthZ4IT-> deny access-> role:
    Choose "any"

    Same for AuthZ4HR, AuthZ4Finance, AuthZ4Support, AuthZ4HelpDesk

    Expression of approval:
    AuthZ4IT or AuthZ4HR or AuthZ4Finance or AuthZ4Support or AuthZ4HelpDesk

    Now test the URL redirects.

    -shetty2k

Maybe you are looking for