Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

PHP: Post und get werden "ignoriert"

Empfohlene Antworten

Veröffentlicht

Hei,

ich habe zwar jetzt schon über ein Jahr kein php mehr gemacht, aber wenn ich mich recht erinnere, dann sind doch die Feldnamen im Formular, im nächsten script, das mit action aufgerufen wird, auch als variablen vorhanden.

Sprich:

form.html


.

.

<form method="post" action="fromform.php">

<input name="dtwn">

.

.

<input type="submit">

</form>

fromform.php

<?php

print($dtwn);

?>

Rein theoretisch müßte fromform.php doch das ausgeben, was in form.html in das inputField eingegeben wurde.

Ich habe hier php.4.2.2 mit apache 1.3 als CGi installiert. Ist nur zum Testen

Kann mir jemand sagen, warum's net funzt?

Peace,

Hallo,

bei php 4.2.2 ist register_globals standardmaessig auf off.

Du musst entweder ueber $_POST['dtwn'] (und entsprechend $_GET) drauf zugreifen oder in der php.ini register_globals auf on stellen.

Michael

Original geschrieben von Impulz

Hallo,

bei php 4.2.2 ist register_globals standardmaessig auf off.

Du musst entweder ueber $_POST['dtwn'] (und entsprechend $_GET) drauf zugreifen oder in der php.ini register_globals auf on stellen.

Michael

Ah :)

Big Thx.

Muß mich wieder mal intensiver mit php beschäftigen.

Danke nochmal.

Peace,

Ouch zu früh gefreut. $_POST['name'] geht nämlich net :(

Peace,

Hi

Probiers mal mit

$name = $HTTP_POST_VARS["name"];

Noxy

Thx,

hat sich erledigt, hatte noch einen Fehler im Code, der sich genau in den Post-Variablen "ausgetobt" hat und dadurch gab immer ein "leeres" ergebnis.

Is jetzt gefixt.

Noma danke an alle.

Pacem,

Archiv

Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.