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] Variablen und Ausgabe Problem

Empfohlene Antworten

Veröffentlicht

Hallo,

ich habe dieses Script:

<?

for ($i=0; $i<10; $i++){

$aktuell = "$serv"$i"\n";

echo ($aktuell);

}

?>

Da kommt ein Parse-Error, in der Zeile 3. Problem ist, er soll mir nacher im Browser folgendes ausgeben:

$serv0

$serv1

$serv2

$serv3

...

Wie kann ich das veranlassen, dass er das $serv nicht als Variable annimmt sondern als Text

hi,

versuch doch mal das $serv in einfache hochkommata zu schreiben.

'$serv'

mfg korea1

Originally posted by Ranger81

Hallo,

ich habe dieses Script:

<?

for ($i=0; $i<10; $i++){

$aktuell = "$serv"$i"\n";

echo ($aktuell);

}

?>

Um diese Ausgabe zu bekommen versuch es mal so:

$aktuell = "$serv".$i."\n";

ggf. muss das $ noch mit einem \ escaped werden.

MfG

mit den Hochkomma gehts und mit den . verbinden, danke !

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.