Login into web client using PHP POST method

Understanding basics of 1C:Enterprise platform. To start working with 1C:Enterprise platform visit Getting started page

#1
People who like this:0Yes/0No
Active user
Rating: 4
Joined: Sep 1, 2014
Company: Smart ID Dynamics

How i can login directly into web client using user and passsword sent from a php page?

 
#2
People who like this:0Yes/0No
Timofey Bugaevsky
Guest

Joined:
Company:

Hello, Marius!

You need to open an URL of the following structure:

Code
http(s)://<domain>/<application>/?N=<user name>&P=<password>

For example:
http://apps.1c-dn.com/demoen/?N=Demo&P=

You can also use the Open ID authentication as well.

 
#3
People who like this:0Yes/0No
Active user
Rating: 4
Joined: Sep 1, 2014
Company: Smart ID Dynamics

Thanks a lot. It works. :)
Now another question.
Can we modify the default login form of 1C to accept more fields, like domain, barcode, etc?

Edited: Marius Gidu - May 08, 2015 05:42 AM
 
#4
People who like this:0Yes/0No
Timofey Bugaevsky
Guest

Joined:
Company:

You can do this in your own form that you are creating and pass this information using "C" parameter.

 
#5
People who like this:0Yes/0No
Active user
Rating: 4
Joined: Sep 1, 2014
Company: Smart ID Dynamics

I want this more fields in enterprise mode and if I can manage the authentification process?

Edited: Marius Gidu - May 08, 2015 06:31 AM
 
#6
People who like this:0Yes/0No
Timofey Bugaevsky
Guest

Joined:
Company:

Marius,

Here is the recommended solution: to use the POST authentication interface. Here is an example of the form that sends POST request.

Code
<html xmlns="http://www.w3.org/1999/xhtml"><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
</head>
<body>
<form action="http://apps.1c-dn.com/demoen/e1cib/start" method="post">
    User: <input id="usr" name="usr" value="Demo" /><br />
    Password: <input id="pwd" type="password" value="" name="pwd" />
    <br />Slow connection: <input id="lowclientconnectionspeed" type="checkbox" name="lowclientconnectionspeed" /><br />
    Run parameter: <input id="launchparameter" name="launchparameter" /><br />
    Interface language: <select id="systemlanguage" name="systemlanguage">
        <option value="zh">Chinese</option>
        <option value="en" selected="">English</option>
    </select><br />
    Session localization code: <select id="localecode" name="localecode">
        <option value="zh">Chinese</option>
        <option value="en" selected="">English</option>
    </select><br />
    Data area: <input id="zone" name="zone" />
    <input id="authfailhandling" type="hidden" value="error" name="authfailhandling" /> 
    <p><input type="submit" value="ОК" /> </p>
</form>
</body>
</html>

 
#7
People who like this:0Yes/0No
Active user
Rating: 4
Joined: Sep 1, 2014
Company: Smart ID Dynamics

Thanks, and with the ENTERPRISE Application Log In Form can i do the same?

 
#8
People who like this:0Yes/0No
Timofey Bugaevsky
Guest

Joined:
Company:

Marius, you will not see that form if log in using this method. If you like to, you can make a conditional redirect to your own form using the web server configuration.

 
Subscribe
Users browsing this topic (guests: 1, registered: 0, hidden: 0)
Be the first to know tips & tricks on business application development!

A confirmation e-mail has been sent to the e-mail address you provided .

Click the link in the e-mail to confirm and activate the subscription.