Skip to main content
Inspiring
June 23, 2023
Answered

Need part of external website to fit

  • June 23, 2023
  • 4 replies
  • 2517 views

Before anyone asks, yes, I have permission from the National Weather Service to use this:

https://www.spc.noaa.gov/products/outlook/

 

I need a part of their website embeded into my website. I could just take a screenshot, but that updates several times a day. Here's the part that I need embedded on mine:

 

I've tried with iframe, and a div, and I can't seem to figure it out. I thought I almost had it, but when I mess with the css code, it screws up things on my website:  https://www.arklahomaw.com/outlook.html (this is the page I want to put it on).

    This topic has been closed for replies.
    Correct answer jamedlock83

    I am!  It's not 100% like or how I want it, but it'll do

    https://www.arklahomawx.com

    4 replies

    B i r n o u
    Legend
    July 11, 2023

    @jamedlock83 So what is going on ? are you set up now ?

    jamedlock83AuthorCorrect answer
    Inspiring
    July 11, 2023

    I am!  It's not 100% like or how I want it, but it'll do

    https://www.arklahomawx.com

    B i r n o u
    Legend
    July 12, 2023

    thank you for your feedback. it's true that we don't always get 100% of what we'd hoped for. but the main thing is that you're now able to provide the information service that needed to be activated.

    B i r n o u
    Legend
    June 25, 2023
    quote

    I've tried with iframe, and a div, and I can't seem to figure it out. I thought I almost had it, but when I mess with the css code, it screws up things on my website:

    By @jamedlock83

     

    in fact, to avoid any spillover from one to the other, make a clear distinction between the two: your page and your weather space.

    So, CSS code your site as you would, remembering to integrate only the container block for displaying your external weather content (no matter how it's fed, iFrame, API, include, Rest, whatever...)... but it's represented by an ID (#foo), and only its display surface is taken into account in mobile mode up to 5K widescreens.

    Once everything is ok and responsive, then you add a new CSS where all the rules start with #foo and which will only take into account the content of your weather area.

    Inspiring
    June 23, 2023

    Can't seem to get it to be mobile friendly though. . .

    Nancy OShea
    Community Expert
    Community Expert
    June 23, 2023

    <iframes> are not mobile friendly. 

    Does NOA have a feed API you can use?

     

     

     

    Nancy O'Shea— Product User & Community Expert
    B i r n o u
    Legend
    June 26, 2023
    quote

    I know nothing about APIs.

    By @jamedlock83

    =========

    You should learn.  API's are powerful tools based on JavaScript programming -- a fundamental website language.

    - https://www.w3schools.com/js/

     

    APIs are sets of definitions and protocols that allow software components to talk and interact with each other using a simple set of commands.

    https://developer.mozilla.org/en-US/docs/Learn/JavaScript/Client-side_web_APIs/Introduction

     


    quote

    You should learn.  API's are powerful tools based on JavaScript programming --

    By @Nancy OShea

     

    When you put it that way, it sounds exclusive... which it isn't... Python, Ruby, C# and PHP, among others, can also deal with APIs.

    https://rapidapi.com/blog/how-to-use-an-api-with-php/

    https://rapidapi.com/blog/how-to-use-an-api-with-python/

    https://rapidapi.com/blog/how-to-use-an-api-with-ruby/

    i.e also https://github.com/open-meteo/open-meteo propose SDK for .net, kotlin, Android, Rust, Laravel, Symfony...

    Inspiring
    June 23, 2023

    Nevermind!  I figured it out. . lol