Desktop version

Main > Forum > 1C:Enterprise Platform > Studying 1C:Enterprise platform > Login into web client using PHP POST method

Forum

Search UsersRules
Login into web client using PHP POST method
#1
Active user
Points:: 0
Joined:: Sep 1, 2014

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

Profile
#2
Guest
Points::
Joined::

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.

Profile
#3
Active user
Points:: 0
Joined:: Sep 1, 2014

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?

Profile
#4
Guest
Points::
Joined::

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

Profile
#5
Active user
Points:: 0
Joined:: Sep 1, 2014

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

Profile
#6
Guest
Points::
Joined::

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>

Profile
#7
Active user
Points:: 0
Joined:: Sep 1, 2014

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

Profile
#8
Guest
Points::
Joined::

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.

Profile
Subscribe
Users browsing this topic (guests: 1, registered: 0, hidden: 0)



© 1C LLC. All rights reserved
1C Company respects the privacy of our customers and visitors
to our Web-site.