Zum Inhalt springen

Dreamweaver HTML - Text only?


blackyns

Empfohlene Beiträge

Hi.

i want to put a weather forecast on my homepage from National and Local Weather Forecast, Radar, Map and Report but it says that i need to: "When you paste the code into your HTML editor, please ensure you are pasting it in as plain text, not as HTML. Please refer to your HTML editor help files for instructions on how to paste text correctly". I have tried all i can think of e.g. inserting it in "code" mode but it only displays the actual link and not the image.

The code is:

<div id="wx_module_5614">   

<a href="http://www.weather.com/weather/local/GRXX0068">Corfu Weather Forecast, Greece</a></div>

<script type="text/javascript">   

/* Locations can be edited manually by updating 'wx_locID' below.  Please also update */  

/* the location name and link in the above div (wx_module) to reflect any changes made. */   

var wx_locID = 'GRXX0068';   

/* If you are editing locations manually and are adding multiple modules to one page, each */   

/* module must have a unique div id.  Please append a unique # to the div above, as well */   

/* as the one referenced just below.  If you use the builder to create individual modules */   

/* you will not need to edit these parameters. */   

var wx_targetDiv = 'wx_module_5614';   

/* Please do not change the configuration value [wx_config] manually - your module */   

/* will no longer function if you do.  If at any time you wish to modify this */  

 /* configuration please use the graphical configuration tool found at */   

 /* https://registration.weather.com/ursa/wow/step2 */   

 var wx_config='SZ=180x150*WX=FHW*LNK=SSNL*UNT=C*BGC=ffffff*MAP=null|null*DN=http';   

 document.write('<scr'+'ipt src="'+document.location.protocol+'//wow.weather.com/weather/wow/module/'+wx_locID+'?config='+wx_config+'&proto='+document.location.protocol+'&target='+wx_targetDiv+'"></scr'+'ipt>');

 </script>

Can anyone think of anything?

Link zu diesem Kommentar
Auf anderen Seiten teilen

it looks like the Javascript you are using is not working correcty

document.write('<scr'+'ipt src="'+document.location.protocol+'//wow.weather.com/weather/wow/module/'+wx_locID+'?config='+wx_config+'&proto='+document.location.protocol+'&target='+wx_targetDiv+'"></scr'+'ipt>');

it's just building up a link dynamically, you can build up this link manually and take a look if its correct.

this might not even work in every website. (document.write should not be used anymore)

Try using Firefox' JS-Debugger. If you have no knowledge of javascript this might get ugly if you have to go deeper into the script.

Since this is an existing website i presume this script is used on other websites. You might want to check out how its integrated into the html-Source there.

Link zu diesem Kommentar
Auf anderen Seiten teilen

Can anyone think of anything?

I can think of many things ;)

But concerning your problem, I think it is that pasting HTML code will escape the code so in your document (code view, or plan text view) there will be:


<a href="....

insted of

<a href="...

I dont know Dreamweaver, but maybe there is an option to escape/unescape selected text? If not open your page with notepad and paste the text there. This should solve the problem.

Link zu diesem Kommentar
Auf anderen Seiten teilen

Dein Kommentar

Du kannst jetzt schreiben und Dich später registrieren. Wenn Du ein Konto hast, melde Dich jetzt an, um unter Deinem Benutzernamen zu schreiben.

Gast
Auf dieses Thema antworten...

×   Du hast formatierten Text eingefügt.   Formatierung wiederherstellen

  Nur 75 Emojis sind erlaubt.

×   Dein Link wurde automatisch eingebettet.   Einbetten rückgängig machen und als Link darstellen

×   Dein vorheriger Inhalt wurde wiederhergestellt.   Editor leeren

×   Du kannst Bilder nicht direkt einfügen. Lade Bilder hoch oder lade sie von einer URL.

Fachinformatiker.de, 2024 by SE Internet Services

fidelogo_small.png

Schicke uns eine Nachricht!

Fachinformatiker.de ist die größte IT-Community
rund um Ausbildung, Job, Weiterbildung für IT-Fachkräfte.

Fachinformatiker.de App

Download on the App Store
Get it on Google Play

Kontakt

Hier werben?
Oder sende eine E-Mail an

Social media u. feeds

Jobboard für Fachinformatiker und IT-Fachkräfte

×
×
  • Neu erstellen...