Solved

Weather.com content to ASP.NET Masterpage

Posted on 2009-05-04
3
421 Views
Last Modified: 2012-05-06
Hello,

When I try to run the below code I get an error message....do i need to do something special if I am running javascript from within a masterpage?
<div class= "sidebarcontainer" >
	<div id="wx_module_4044">
   <a href="http://www.weather.com/weather/local/USTN0094">Cleveland Weather Forecast, TN</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 = 'USTN0094';
 
    /* 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_4044';
 
    /* 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=300x250*WX=FWC*LNK=SSNL*UNT=F*BGI=golf*MAP=CSC|null*DN=matthew-wilson.com*TIER=0*PID=1114395521*MD5=55983657be43b506bc1d7a5bf660df76';
 
    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>
</div>

Open in new window

0
Comment
Question by:ITHelper80
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 10

Expert Comment

by:cdebel
ID: 24301360
what's the error message?

Here's a link about your confusion... if you google, you will find hundreds like this.
http://www.dotnetcurry.com/ShowArticle.aspx?ID=273&AspxAutoDetectCookieSupport=1
0
 
LVL 6

Author Comment

by:ITHelper80
ID: 24301511
I did try to google for this but couldnt find anything with my particular situation. Ive included a screen shot of the error....looks generic to me. I tried loading the code into a reg aspx page and it works just fine.




error.jpg
0
 
LVL 6

Accepted Solution

by:
ITHelper80 earned 0 total points
ID: 24301980
I went with accuweather.com code and it works perfect.
0

Featured Post

How our DevOps Teams Maximize Uptime

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us. Read the use case whitepaper.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article will give core knowledge of JavaScript and will head in to your first JavaScript program. I am Durvesh Naik and I am here to deal with this series of JavaScript. I will teach you JavaScript in part wise , as its quite boring to read big…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question