Jump to content
Sign in to follow this  
Graham Quince

My first widget

Recommended Posts

Hi folks,

I know we've been talking about FrogCode IDE for some time, but today I got my hands on an alpha build.  With only a few pointers from @Chris.Smith, I've been able to build a widget in Frog.
 

I've called it Embed or Link and it's a widget which detects if you're trying to embed a website which cannot be embedded because it doesn't have HTTPS security.  If it can't be embedded it provides a link instead.

Using basic IF statements in Javascript, I was able to really quickly assemble a widget (less than an hour).  The screenshot below shows four examples of it in action.  Hopefully you can see it also takes embed codes!

myfirstwidget.JPG

There is literally not much work left by Chris and the team before we start talking to schools for a beta trial.  If you're comfortable with code and would like to be part of the beta trial, let me know here or PM me.

  • Like 1

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Similar Content

    • By Graham Quince
      Here's a new FrogCode widget:
      https://www.frogeducation.com/community/frogcode/frogcode-showcase/visitor-log
      We worked with George Bligh from Greenshaw on this widget.  When someone views a page with this widget on, it records their visit.  Anyone with Edit and Manage rights gets a button which displays a list of all visitors, their profile, their children (if a parent), how many times they have visited the site and the time and date of their last visit.

      (This widget uses the datastore - a little known about feature of Frog's API.)
    • By Phil Stiles
      Hi, I am trying to create a widget that is able to pull the Total Positive Behaviour Points into a variable, the end result is we will use an if statement to display a specific image depending on a number of points the student has.
      I have started by testing with the HTML widget. using the below code to see if I can use the behaviour.getBehaviourTotals API to get the total points this year for the user, however, it is not working.
      <script> var $ap,user; //Create a div, and give it a unique ID $ap = $("div", { id: Frog.Utilities.generateSimpleID() } ); $ap.html( '<b>Your House Points:</b>'+ '<table clase="table" id="your_points">'+ '<tr>'+ "<th>This Year</th>"+ '</tr>'+ '</table>' ); // Use Frog's API to get the logged in student user = FrogOS.getUser(); // Use Frog's API to get Behaviour points Frog.Model .api('behaviour.getBehaviourTotals',{ Student_uuid: user.uuid, }).done(function(behaviourResponse){ behaviourResponse.data.pos.year(function(work){ $ap.find('tbody') .append( '<tr>'+ '<td>'+ data.pos.year+ '</td>'+ '</tr>' ); }); }); arguments[0].append($ap); </script> any advice appreciated.
      Phil
    • By Graham Quince
      The brilliant @Simon Law has built a new widget which adds a site's menu to a page, to save us all from having to do this manually using text widgets.
      You can download this from the showcase page:
      https://www.frogeducation.com/community/tutorials/frogcode/frogcode-showcase
    • By K.Ermit
      Hi,
      I want to link an image (or file) to my widget, but I can't get the web address when I upload it.
    • By pconkie
      We have a new process for monitoring regularity and quality of home learning (all of which are now done via assignment manager).
      Happy to share this frog code app which allows Tutors, Heads of House/Year, SLT to lookup what has been assigned to a student and act accordingly.   I will ensure this app continues to work if frog change api's in the future as it is part of our internal systems.  
      I realise this functionality is available in the assignment monitor app, but we do not wish to share this app with staff as it would allow them to lookup staff as well as students!
      A quick screen shot...

      Paul
×
×
  • Create New...