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.

html / css Hintergrundgrafik einfügen

Empfohlene Antworten

hallo zusammen,

ich glaub, ich hab jetzt schon so ziemlich alles mögliche versucht, um eine hintergrundgrafik einzufügen.

<html>

 <head>

 <title>titel^^</title>

 <style type="text/css">


 <!--


ul,body,p,td,tr,table,ol,div{

font-size:11px;

font-family:Verdana;

}

.button{

border-bottom: black 1px solid;

border-left: #297394 1px solid;

border-right: black 1px solid;

border-top: #297394 1px solid;

font-family:Verdana;

font-size: 11px;

text-align:left;

padding-left:5px;

padding-top:2px;

padding-bottom:2px;

font-weight:bolder;

color:black;

background-color:/cgi-data/formmanager/files(hintergrund.jpg);

cursor:pointer;

display:inline;

width:auto;

}

.text{

background-color:/cgi-data/formmanager/files(hintergrund.jpg);

color:#297394;

border:1px solid black;

}

.select{

background-color:/cgi-data/formmanager/files(hintergrund.jpg);

color:#297394;

}

 -->

 </style>


</head><body style="background-image:/cgi-data/formmanager/files(hintergrund.jpg)">





<body background="hintergrund.jpg" /*text="#990000" link="#0000CC" vlink="#000066" alink="#000000"*/>


<div style="background:/cgi-data/formmanager/files(hintergrund.jpg) repeat-x;">

<h1 style="font-family:Arial,sans-serif; color:maroon; font-size:80px">NEWS</h1>

<div style="margin-top:45px; font-size:1.2em">

<p>Hier folgen die News...</p>

</div></div>



 <form action="{form}" method="post" enctype="multipart/form-data">

 <input type="hidden" name="fid" value="{formular_id}">

 <!-- START error --><p style="color:red">{error}</p><!-- END error -->

 <table><!-- END head --><!-- START input_text -->

 <tr>

  <td>{text_text}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --></td>

  <td><input class="text" type="text" name="{name}" value="{value}" size="{size}" maxlength="{maxlength}"></td>

 </tr><!-- END input_text --><!-- START input_checkbox -->

<!-- START one_input_checkbox -->

 <tr>

  <td>

   {text_checkbox}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk -->

  </td>

  <td>

   <input type="checkbox" name="{name}" value="{value}" <!-- START checked_block -->checked<!-- END checked_block --> /><!-- START br_block --><br /><!-- END br_block --><!-- END one_input_checkbox -->

  </td>

 </tr><!-- END input_checkbox --><!-- START input_radio -->

  <!-- START one_input_radio --><tr><td>

   {text_radio}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk -->

  </td>

  <td>

   <input type="radio" name="{name}" value="{value}" <!-- START checked_block -->checked<!-- END checked_block --> /><!-- START br_block --><br /><!-- END br_block -->

  </td>

 </tr><!-- END one_input_radio --><!-- END input_radio --><!-- START input_hidden -->

 <tr>

  <td colspan="2">

   <input type="hidden" name="{name}" value="{value}">

  </td>

 </tr><!-- END input_hidden --><!-- START input_img -->

 <tr>

  <td>{text_img}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --></td>

  <td>

   <input class="text" type="img" src="{src}" {options} />

  </td>

 </tr><!-- END input_img --><!-- START input_password -->

 <tr>

  <td>{text_password}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --></td>

  <td>

   <input class="text" type="password" name="{name}" value="{value}" size="{size}" maxlength="{maxlength}" />

  </td>

 </tr><!-- END input_password --><!-- START input_submit -->

 <tr>

  <td><input class="button" type="reset" name="reset2" value="{rst_value}" /></td>

  <td><input class="button" type="submit" name="submit" value="{sbm_value}" /></td>

</tr><!-- END input_submit --><!-- START input_reset -->

 <tr>

  <td colspan="2"><input class="button" type="reset" name="reset" value="{rst_value}" /></td>

 </tr><!-- END input_reset --><!-- START input_select -->

 <tr>

  <td>{text_select}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --></td>

  <td>

   <select class="select" name="{name}" size="{size}" <!-- START multiple -->multiple="multiple"<!-- END multiple -->><!-- START one_input_option -->

    <option value="{value}" <!-- START selected -->selected<!-- END selected -->>{option_text}</option><!-- END one_input_option -->

   </select>

  </td>

 </tr><!-- END input_select --><!-- START input_textarea -->

 <tr>

  <td colspan="2">

   {text_textarea}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --><br />

   <textarea class="text" name="{name}" cols="{cols}" rows="{rows}">{value}</textarea>

  </td>

 </tr><!-- END input_textarea --><!-- START input_file -->

 <tr>

  <td>{file_text} </td><td><p><input class="button" type="file" name="file" value="" /><br />

  <span title="{file_extensions}" style="cursor:pointer; font-size: 0.8em;">{file_extensions_short}</span></p>

  </td>

 </tr><!-- END input_file --><!-- START sternchentext -->

 <tr><td colspan="2"><span style="color:red">* Pflichtfeld</span></td>

 </tr><!-- END sternchentext -->

<!-- START footer -->

</table>

</form>


</body>

</html>

das ist ein formular, welches ich über ein baukasten bei strato erstellt habe.

hat einer einen tip für mich? :)

<style type="text/css">

div.bg {

background-image: url(../images/bg.gif);

background-color:orange;

width:500px;height:200px;

border:1px solid red;

padding:20px;

}

</style>


...


<body>

<div class="bg">

  div-Container mit Hintergrundbild

</div>

ok, habe ich jetzt hier auch noch ein fehler? oder falsch verstanden.... :confused:

<style type="text/css">

div.bg {

background-image:/cgi-data/formmanager/files(hintergrund.jpg);

background-color:orange;

width:500px;height:200px;

border:1px solid red;

padding:20px;

}

</style>

background-image: url(cgi-data/formmanager/files/hintergrund.jpg);

ich hab mich wirklich super wenig mit html + css beschäftigt, da ich es eigentlich auch nicht brauche. funktioniert immer noch nicht :(

<style type="text/css">

div.bg {

background-image: url(cgi-data/formmanager/files/hintergrund.jpg);

background-color:orange;

width:500px;height:200px;

border:1px solid red;

padding:20px;

}

</style>



<body>

<div class="hintergundbild">

 div-Container mit Hintergrundbild

</div>

poste nochmal, wie deine html-datei jetzt aussieht

<html>

 <head>

 <title>Bitte geben Sie Ihre Daten ein</title>

</head>

<style type="text/css">

div.bg {

background-image: url(cgi-data/formmanager/files/hintergrund.jpg);

background-color:orange;

width:500px;height:200px;

border:1px solid red;

padding:20px;

}

</style>


</head>



<body>

<div class="hintergundbild">

 div-Container mit Hintergrundbild

</div>



</body>


<div style="background:/cgi-data/formmanager/files(hintergrund.jpg) repeat-x;">

<h1 style="font-family:Arial,sans-serif; color:maroon; font-size:80px">NEWS</h1>

<div style="margin-top:45px; font-size:1.2em">

<p>Hier folgen die News...</p>

</div></div>



 <form action="{form}" method="post" enctype="multipart/form-data">

 <input type="hidden" name="fid" value="{formular_id}">

 <!-- START error --><p style="color:red">{error}</p><!-- END error -->

 <table><!-- END head --><!-- START input_text -->

 <tr>

  <td>{text_text}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --></td>

  <td><input class="text" type="text" name="{name}" value="{value}" size="{size}" maxlength="{maxlength}"></td>

 </tr><!-- END input_text --><!-- START input_checkbox -->

<!-- START one_input_checkbox -->

 <tr>

  <td>

   {text_checkbox}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk -->

  </td>

  <td>

   <input type="checkbox" name="{name}" value="{value}" <!-- START checked_block -->checked<!-- END checked_block --> /><!-- START br_block --><br /><!-- END br_block --><!-- END one_input_checkbox -->

  </td>

 </tr><!-- END input_checkbox --><!-- START input_radio -->

  <!-- START one_input_radio --><tr><td>

   {text_radio}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk -->

  </td>

  <td>

   <input type="radio" name="{name}" value="{value}" <!-- START checked_block -->checked<!-- END checked_block --> /><!-- START br_block --><br /><!-- END br_block -->

  </td>

 </tr><!-- END one_input_radio --><!-- END input_radio --><!-- START input_hidden -->

 <tr>

  <td colspan="2">

   <input type="hidden" name="{name}" value="{value}">

  </td>

 </tr><!-- END input_hidden --><!-- START input_img -->

 <tr>

  <td>{text_img}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --></td>

  <td>

   <input class="text" type="img" src="{src}" {options} />

  </td>

 </tr><!-- END input_img --><!-- START input_password -->

 <tr>

  <td>{text_password}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --></td>

  <td>

   <input class="text" type="password" name="{name}" value="{value}" size="{size}" maxlength="{maxlength}" />

  </td>

 </tr><!-- END input_password --><!-- START input_submit -->

 <tr>

  <td><input class="button" type="reset" name="reset2" value="{rst_value}" /></td>

  <td><input class="button" type="submit" name="submit" value="{sbm_value}" /></td>

</tr><!-- END input_submit --><!-- START input_reset -->

 <tr>

  <td colspan="2"><input class="button" type="reset" name="reset" value="{rst_value}" /></td>

 </tr><!-- END input_reset --><!-- START input_select -->

 <tr>

  <td>{text_select}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --></td>

  <td>

   <select class="select" name="{name}" size="{size}" <!-- START multiple -->multiple="multiple"<!-- END multiple -->><!-- START one_input_option -->

    <option value="{value}" <!-- START selected -->selected<!-- END selected -->>{option_text}</option><!-- END one_input_option -->

   </select>

  </td>

 </tr><!-- END input_select --><!-- START input_textarea -->

 <tr>

  <td colspan="2">

   {text_textarea}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --><br />

   <textarea class="text" name="{name}" cols="{cols}" rows="{rows}">{value}</textarea>

  </td>

 </tr><!-- END input_textarea --><!-- START input_file -->

 <tr>

  <td>{file_text} </td><td><p><input class="button" type="file" name="file" value="" /><br />

  <span title="{file_extensions}" style="cursor:pointer; font-size: 0.8em;">{file_extensions_short}</span></p>

  </td>

 </tr><!-- END input_file --><!-- START sternchentext -->

 <tr><td colspan="2"><span style="color:red">* Pflichtfeld</span></td>

 </tr><!-- END sternchentext -->

<!-- START footer -->

</table>

</form>


</body>

</html>

wenn du schon einträge aus meinem beispiel änderst, dann änder sie auch überall. Kein Wunder, dass es nicht funktioniert.

Hier nochmal zum Vergleich

Mein Code:

<style type="text/css">

div.bg {

background-image: url(cgi-data/formmanager/files/hintergrund.jpg);

background-color:orange;

width:500px;height:200px;

border:1px solid red;

padding:20px;

}

</style>


...


<body>

<div class=[COLOR="Red"]"bg"[/COLOR]>

  div-Container mit Hintergrundbild

</div>

Dein Code:
<style type="text/css">

div.bg {

background-image: url(cgi-data/formmanager/files/hintergrund.jpg);

background-color:orange;

width:500px;height:200px;

border:1px solid red;

padding:20px;

}

</style>



<body>

<div class=[COLOR="Red"]"hintergundbild"[/COLOR]>

 div-Container mit Hintergrundbild

</div>

Fehler gefunden?

Ganz davon abgesehn sieht deine HTML grausam aus. Body auf, Body zu, Body auf, Body zu.

Wenn du das mit einem Editor gemacht hast, schmeiß ihn weg.

Wenn du es selbst gemacht hast, dann solltest du vielleicht nochmal ein Buch zur Hand nehmen

erstmal danke für die hilfe :);)

hmmm hab geändert, allerdings ist dass nicht das hintergrundbild, welches ich angegeben hatte :(

außerdem hab ich nur den kleinen kasten da oben...

....sollte eigentlich über die gesamte seite gehen...

7c5v7ayw.jpg

so habe den code mit dem baukasten nochmals neu erstellen lassen, aber keine ahnung, wo jetzt der befehl zur hintergrundgrafik hinkommt :(

<!-- START head -->

<html>

 <head>

 <title>Strato Formularbaukasten</title>

 <style type="text/css">

 <!--

ul,body,p,td,tr,table,ol,div{

font-size:11px;

font-family:Verdana;

}

.button{

border-bottom: black 1px solid;

border-left: #297394 1px solid;

border-right: black 1px solid;

border-top: #297394 1px solid;

font-family:Verdana;

font-size: 11px;

text-align:left;

padding-left:5px;

padding-top:2px;

padding-bottom:2px;

font-weight:bolder;

color:black;

background-color:#dfdfdf;

cursor:pointer;

display:inline;

width:auto;

}

.text{

background-color:whitesmoke;

color:#297394;

border:1px solid black;

}

.select{

background-color:whitesmoke;

color:#297394;

}

 -->

 </style>

</head>

<body>

 <form action="{form}" method="post" enctype="multipart/form-data">

 <input type="hidden" name="fid" value="{formular_id}">

 <!-- START error --><p style="color:red">{error}</p><!-- END error -->

 <table><!-- END head --><!-- START input_text -->

 <tr>

  <td>{text_text}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --></td>

  <td><input class="text" type="text" name="{name}" value="{value}" size="{size}" maxlength="{maxlength}"></td>

 </tr><!-- END input_text --><!-- START input_checkbox -->

<!-- START one_input_checkbox -->

 <tr>

  <td>

   {text_checkbox}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk -->

  </td>

  <td>

   <input type="checkbox" name="{name}" value="{value}" <!-- START checked_block -->checked<!-- END checked_block --> /><!-- START br_block --><br /><!-- END br_block --><!-- END one_input_checkbox -->

  </td>

 </tr><!-- END input_checkbox --><!-- START input_radio -->

  <!-- START one_input_radio --><tr><td>

   {text_radio}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk -->

  </td>

  <td>

   <input type="radio" name="{name}" value="{value}" <!-- START checked_block -->checked<!-- END checked_block --> /><!-- START br_block --><br /><!-- END br_block -->

  </td>

 </tr><!-- END one_input_radio --><!-- END input_radio --><!-- START input_hidden -->

 <tr>

  <td colspan="2">

   <input type="hidden" name="{name}" value="{value}">

  </td>

 </tr><!-- END input_hidden --><!-- START input_img -->

 <tr>

  <td>{text_img}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --></td>

  <td>

   <input class="text" type="img" src="{src}" {options} />

  </td>

 </tr><!-- END input_img --><!-- START input_password -->

 <tr>

  <td>{text_password}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --></td>

  <td>

   <input class="text" type="password" name="{name}" value="{value}" size="{size}" maxlength="{maxlength}" />

  </td>

 </tr><!-- END input_password --><!-- START input_submit -->

 <tr>

  <td><input class="button" type="reset" name="reset2" value="{rst_value}" /></td>

  <td><input class="button" type="submit" name="submit" value="{sbm_value}" /></td>

</tr><!-- END input_submit --><!-- START input_reset -->

 <tr>

  <td colspan="2"><input class="button" type="reset" name="reset" value="{rst_value}" /></td>

 </tr><!-- END input_reset --><!-- START input_select -->

 <tr>

  <td>{text_select}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --></td>

  <td>

   <select class="select" name="{name}" size="{size}" <!-- START multiple -->multiple="multiple"<!-- END multiple -->><!-- START one_input_option -->

    <option value="{value}" <!-- START selected -->selected<!-- END selected -->>{option_text}</option><!-- END one_input_option -->

   </select>

  </td>

 </tr><!-- END input_select --><!-- START input_textarea -->

 <tr>

  <td colspan="2">

   {text_textarea}<!-- START obl_asterisk --><span style="color:red">*</span><!-- END obl_asterisk --><br />

   <textarea class="text" name="{name}" cols="{cols}" rows="{rows}">{value}</textarea>

  </td>

 </tr><!-- END input_textarea --><!-- START input_file -->

 <tr>

  <td>{file_text} </td><td><p><input class="button" type="file" name="file" value="" /><br />

  <span title="{file_extensions}" style="cursor:pointer; font-size: 0.8em;">{file_extensions_short}</span></p>

  </td>

 </tr><!-- END input_file --><!-- START sternchentext -->

 <tr><td colspan="2"><span style="color:red">* Pflichtfeld</span></td>

 </tr><!-- END sternchentext -->

<!-- START footer -->

</table>

</form>

</body>

</html><!-- END footer -->

habs dann doch noch gefunden :)

Danke trotzdem ;)

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.