Jump to content

Search the Community

Showing results for tags 'javascript'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Community Forums

  • The New Claris Platform
  • Community Resources
    • Community Videos, Tips, & Techniques, Articles.
    • FileMaker Marketplace Discussions
    • FileMaker Videos
  • FileMaker Platform
    • FileMaker Interface Features
    • FileMaker Schema & Logical Functions
    • FileMaker Go for iPad and iPhone
    • FileMaker and the Internet
    • FileMaker Pro 19
  • FileMaker Server Administration
    • FileMaker Server 19
    • FileMaker Server 19 (Linux)
    • FileMaker Cloud
    • FileMaker Custom SSL Certificates
    • oAuth and External Server Authentication
    • Zabbix Server Monitoring
    • Previous Version Server Discussions
  • JavaScript Integration
    • Java Script and the Web Viewer
    • Carafe.FM
    • Widget Studio
  • Brain Food
    • Security Concepts
    • The Left Brain
    • Upgrading & Migration
    • Data Analysis
    • Development Standards
    • The Separation Model
    • Relational Database Theory
    • Damaged / Corrupt File Problems
    • Hardware & Networking
    • Product Ideas
  • FMForums Affiliates & Sponsors
    • Productive Computing Support Forums
    • 360 Works Official Product Support Forums
    • Proof+Geist
    • FileMaker Vendors
    • FileMaker Training Resources
  • FileMaker Classifieds
    • Announcements of FileMaker Product, Services or Resources
    • Classifieds
    • Tools Of The Trade
  • FM Forums Operations
    • FM Forums Feedback & Site News
  • FileMaker Friday Night Chat's Topics

Blogs

  • Captain's Blog
  • FileMaker Weetbicks
  • FileMaker Security Blog
  • The FileMaker Rift
  • HOnza's Bits @ FMForums
  • SeedCode
  • FileMaker Hacks
  • Skeleton Key's Blog
  • Wing Forward Solutions
  • 360Works Articles and Tutorials
  • GoBillit
  • Filemaker - an amateur's view
  • Linear Blue
  • Surya Kanta Mekap's Blog
  • eXcelisys' Blog
  • Manjit Behera
  • Blue Feather's Blog
  • RCC's FileMaker News and Bits
  • Thorsen Consulting
  • DB Services Blog
  • FileMaker Magazine
  • Eye on FileMaker
  • Dev Talk
  • The Philosophy of FileMaker
  • 1-more-blog
  • Productive Computing
  • Geist Interactive
  • Soliant Consulting

Categories

  • White Papers
  • Infographics
  • Samples
  • Add-ons
  • FMGo
  • Solutions
  • Tutorials
  • Plug-Ins

Product Groups

  • Workplace Innovation Platform
  • Site Advertising
  • Development
  • FileMaker Hosting

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Title


Industry


Location


Interests


Website URL


Skype


MSN


Yahoo


OS Version

  1. We use our own app called Collector to manage our software development projects. A few years ago my colleague Milan started feeling the need to schedule our development capacity more precisely. So we created a detailed plan layout. In the following video you can see what the layout looked like and how we later optimized it using Web Viewer and JavaScript. In the first version of the layout, we used a list view with 31 filtered portals in the body part and another 31 portals in the footer to show summaries. That required FileMaker Pro to render 11 625 fields just for the calendar part of the layout. It was quite fast and easy to develop but changing a single value caused it to take a few seconds to refresh the whole layout and we had to wait for the refresh to complete before we could change another value. With a little bit of JavaScript and AJAX, our web developers were able to make the user interface so fast that a responding to any change takes less time than an eye blink. Click here to read the whole story and watch the video
  2. Today we're covering the PerformScriptWithOptions JavaScript function with Calvin Mosiman. Learn about this new option for calling a FileMaker script from a web viewer! Future live streams: https://fmtraining.tv/#LIVE support@rcconsulting.com www.fmtraining.tv www.fmstartingpoint.com www.rcconsulting.com
  3. I use jQuery and the jQueryUI slider widget to display a slider in FileMaker Pro (v17-17-18-19). Works fine but I also need to have it work on FileMaker Go, so I tried my luck on jQuery Mobile 1.4.5. The slider is working nicely on FileMaker Pro, but on FmGo 17, 18 or 19 it doesn't load, keeps displaying a spinning logo. When I publish the HTML page on a website and open it in Safari Mobile it works fine. Any help appreciated! See the example file: just downlaod it and open it on FMGo. The Webviewer and the HTML are displayed side by side. sliderExample.fmp12
  4. NOW AVAILABLE: fmPromise Presentation and Free Download! Thank you for your patience with the demonstration of fmPromise, a new free tool created to improve FileMaker and JavaScript integration. You can now watch the video presentation by Sam Barnum immediately at the 360Works YouTube Channel. Questions can be asked in the comment section below the video, or by emailing support@360works.com Free download available at the fmPromise page! More on 360Works fmPromise: We are now showcasing fmPromise, a brand new free tool created to improve JavaScript and FileMaker integration! Most people are aware that JavaScript in FileMaker can provide a much better UI within apps. While FileMaker 19 improved Web Viewer usage with JavaScript, 360Works is always looking for ways to build-in improvements to the FileMaker platform. FileMaker 19 has added the ability to call FileMaker scripts from your JavaScript, as well as executing a JavaScript function from a FileMaker script. This allows for integration between FileMaker and JavaScript in your Web Viewer, but has some areas that fmPromise will make better. Every call from JavaScript to a FileMaker script needs a public JavaScript function to receive the script response, and it is the responsibility of the Script to call that function. All data coming back from FileMaker is a string Debugging JavaScript errors is very difficult without browser-based dev tools The window.FileMaker object is not available right when the page loads, so you need a window.setTimeout() to wait for it to become available if you want to populate your web viewer using a script call. fmPromise is designed to address these shortcomings, and help you utilize Web Viewers in your solution with the minimum amount of fuss. Tune In Remotely: Click here to watch the video presentation anytime! Click here to visit the fmPromise page and get your free download. Stay updated with 360Works
  5. The new FileMaker JavaScript Web Viewer Integration creates seamless communication between FileMaker and web viewers. This integration will allow for more efficient development of web viewers which will extend the functionality of FileMaker systems with features not native to FileMaker. Learn how with our tutorial and free sample file: https://dbservices.com/articles/filemaker-javascript-web-viewer-integration/ dbservices.com
  6. Looking to take your FileMaker to the next level by bringing it to web or creating a customer web portal? Learn why Vue.js is our recommended Javascript framework to build highly dynamic FileMaker webapps. Be sure to check out FileMaker Web Apps with Vue.js Includes a free video and sample file. dbservices.com
  7. Recently a client asked how to leverage JavaScript in FileMaker to do a specific calculation. For this blog post we replace the client's function with a CRC function to show you how to do it. Up until a few weeks ago we would have pointed to loading JavaScript in a web viewer and using WebView.RunJavaScript to run the JavaScript. But now we would point to WebView.Evaluate and just run it. See the example script in our documentation for this CRC function. With MBS FileMaker Plugin in version 10.0 we got our own JavaScript functions using the DukTape engine. We have an example in the documentation to run the CRC function right in a Let command and the JS.Evaluate command. But instead of initializing it each time in a Let statement, you may prefer to split this into three scripts, so you do the initialization only once. he following script initializes the JavaScript environment once and uses a call to JS.Evaluate to pass the JavaScript functions: If [ Length($$js) = 0 ] Set Variable [ $$js ; Value: MBS( "JS.New" ) ] Set Variable [ $r ; Value: MBS( "JS.Evaluate"; $$js; "function makeCRCTable(){ var c; var crcTable = []; for(var n =0; n < 256; n++){ c = n; for(var k =0; k < 8; k++){ c = ((c&1) ? (0xEDB88320 ^ (c >>> 1)) : (c >>> 1)); } crcTable[n] = c; } return crcTable; } function crc32(str) { var crcTable = crcTable || (crcTable = makeCRCTable()); var crc = 0 ^ (-1); for (var i = 0; i < str.length; i++ ) { crc = (crc >>> 😎 ^ crcTable[(crc ^ str.charCodeAt(i)) & 0xFF]; } return (crc ^ (-1)) >>> 0; };") ] End If As you see we store the JavaScript environment in a global $$js variable, so we can refer to it everywhere in this file. Instead of letting JS.Evaluate define the functions, we could alternatively use JS.AddFunction if you prefer: If [ Length($$js) = 0 ] Set Variable [ $$js ; Value: MBS( "JS.New" ) ] Set Variable [ $r ; Value: MBS( "JS.AddFunction"; $$js; "makeCRCTable"; "function makeCRCTable(){ var c; var crcTable = []; for(var n =0; n < 256; n++){ c = n; for(var k =0; k < 8; k++){ c = ((c&1) ? (0xEDB88320 ^ (c >>> 1)) : (c >>> 1)); } crcTable[n] = c; } return crcTable; }") ] Set Variable [ $r ; Value: MBS( "JS.AddFunction"; $$js; "crc32"; "function crc32(str) { var crcTable = crcTable || (crcTable = makeCRCTable()); var crc = 0 ^ (-1); for (var i = 0; i < str.length; i++ ) { crc = (crc >>> 😎 ^ crcTable[(crc ^ str.charCodeAt(i)) & 0xFF]; } return (crc ^ (-1)) >>> 0; }") ] End If Next we have a script to process data and use JS.CallFunction to run our function. This allows us to pass the argument as JSON data and avoid building JavaScript on the fly where wrong escaping could cause a JavaScript injection by an user: If [ Length($$js) > 0 ] Set Variable [ $p ; Value: MBS( "JSON.CreateString"; test::Input) ] Set Field [ test::Output ; MBS( "JS.CallFunction"; $$js; "crc32"; $p ) ] End If When the solution closes you can cleanup the JavaScript environment: If [ Length($$js) > 0 ] Set Variable [ $r ; Value: MBS( "JS.Free"; $$js ) ] Set Variable [ $$js ; Value: "" ] End If If you have questions, please do not hesitate to contact us. from CRC function in FileMaker using JavaScript
  8. We have a new fix for Google Maps in FMSP & the FMI Contacts Starter Solution Vid 1 - Getting your API Key: Vid 2 - FMI Contacts Starter Solution Fix Vid 3 - FMSP Fix Get up to speed with the FileMaker Video Training Course! FileMaker is a cross-platform relational database application from FileMaker Inc. https://en.wikipedia.org/wiki/FileMaker Top Rated Course by FileMaker Expert, Richard Carlton. http://learningfilemaker.com/fmpro17.php Customer relationship management, processes implemented to manage a company's interactions with customers and prospects https://en.wikipedia.org/wiki/CRM Experience Richard's dynamic and exciting teaching format, while learning both basic, intermediate, and advanced FileMaker development skills. With 26 years of FileMaker experience and a long time speaker at FileMaker's Developer Conference, Richard will teach you all the ins and outs of building FileMaker Solutions. The course is 50 hours of video content! Richard has been involved with the FileMaker platform since 1990 and has grown RCC into one of the largest top tier FileMaker consultancies worldwide. Richard works closely with RCC's staff: a team of 28 FileMaker developers and supporting web designers. He has offices in California, Nevada, and Texas. Richard has been a frequent speaker at the FileMaker Developers Conference on a variety of topics involving FileMaker for Startups and Entrepreneurs, and client-server integration. Richard is the Product Manager for FM Starting Point, the popular and most downloaded free FileMaker CRM Starter Solution. Looking for FM Starting Point free software download: http://www.fmstartingpoint.com Richard won 2015 Excellence Award from FileMaker Inc (Apple Inc) for outstanding video and product creation, leading to business development. RCC, Filemaker Videos, and LearningFileMaker.com are headquartered in Santa Clara, CA. http://www.rcconsulting.com/ Contact us at support@rcconsulting.com FileMaker Pro is simply a powerful software used to create custom apps that work seamlessly across iPad, iPhone, Windows, Mac, and the web Transform your business with the FileMaker Platform https://sites.google.com/site/filemakerprotrainingd2n/home/filemaker-training Free FileMaker Training Videos Channel https://www.youtube.com/user/FileMakerVideos FileMaker Training -FileMaker Video Training Course-FileMaker News-FileMaker Experts https://www.youtube.com/watch?v=RO3Do8QIQOE https://www.youtube.com/watch?v=RO3Do8QIQOE&index=2&list=PLjTvUZtwtgBTWVT38kPvgjCfkZmMmvCOk&t=25s FileMaker What's New-Top Ten Things To Know About FileMaker -FileMaker News https://youtu.be/6ZcnQEOF9XE https://www.youtube.com/watch?v=6ZcnQEOF9XE&index=1&list=PLjTvUZtwtgBTWVT38kPvgjCfkZmMmvCOk&t=25s Sharing a FileMaker Solution-The Basics-Sharing FileMaker Database-FileMaker Experts https://youtu.be/a5o5Mt8DnFI https://www.youtube.com/watch?v=a5o5Mt8DnFI&index=9&list=PLjTvUZtwtgBQukMafXx60CF5rcXwNmGWl&t=0s A database management system (DBMS) is a computer software application that interacts with the user, other applications, and the database itself to capture and analyze data Official site SDK, Developer's Guide, Reference, and Android Market for the open source project http://learningfilemaker.com/FIAS.html Video introduction to iOS App Training https://www.youtube.com/watch?v=cVxQe_yAshw Free FileMaker videos check out ...http://www.filemakervideos.com Download the FileMaker Pro & FileMaker GO for mobile devices training videos at http://www.learningfilemaker.com Download FileMaker Go video training at http://learningfilemaker.com/FMGO-17/index.php Download FileMaker Full Video Training Bundle at http://learningfilemaker.com/subscription.php Learn how to use FileMaker to create an app with the FileMaker Training Series Comment, Like & Share All of Our Videos. Feel Free to Embed any of Our Videos on Your Blog or Website. Follow Us on Your Favorite Social Media Facebook Twitter Google+ #FileMakerGoogleMaps #FileMakerAPI #FileMakerGoogleMapsAPI #FileMakerFreeVideoTraining #FileMakerTrainingVideos #FilemakerProTraining #FileMakerVideoTutorial #FileMakerProVideos
  9. Hello, I would like to use UUIDdecimal CF for the taskID rather than an auto-enter Serial Number. However I get Integer Notation like this: 2.25640703445567e+37, rather than a number like this: 22564070344556677882256407034455667788. I have toyed with other implementations of FullCalendar and have gotten it to work, but the related libraries were different versions and I can't recall how I solved the same problem then. How can I solve this? Example { "allDay" : false, "color" : "#FF0000", "end" : "2018-05-30T23:00:00**TIMEZONE**", "id" : 9, "start" : "2018-05-30T21:00:00**TIMEZONE**", "title" : "New Task" }, { "allDay" : false, "color" : "#E69138", "end" : "2018-06-01T23:30:00**TIMEZONE**", "id" : 2.25640703445567e+37, "start" : "2018-06-01T22:30:00**TIMEZONE**", "title" : "Old Task" }
  10. Hello, everyone. I have a question. I have web viewer object named "web". If I start a script running, Every 5 seconds, it fetches the string from the HTML that is shown in the web viewer, and keeps creating new records. Just like this GetLayoutObjectAttribute ( "web" ; "content" ) Then the target value always get refreshed every 5 seconds. javascript is just like this function updateLastvalue(new_last_value){ var current_last_value = $('.last-value').text(); var fixed_last_value = Number(new_last_value).toFixed(8); $('.last-value').text(fixed_last_value); // update document.title = fixed_last_value"; } and the number that I want to fetch but it changes every 5 seconds is just like this <td><span class="last-value”>297</a></td> How can I take out this 297 and another numbers that continues changing? GetLayoutObjectAttribute ( "web" ; "content" ) takes out only the number that was shown first. Can anyone help me with this?
  11. I´m not sure why but the WV shows the correct result in some computers and devices, but in other just shows an empty page (please see attached file with WV including code). This is the result after testings: - It doesn't work on my Mac (10.11.06) - It works on my iPhone - It works on my iPad - I works on one of my colleague´s Mac (10.12 I believe) - It doesn't work on another collegue's Windows I have attached the file with the wv, is this working for you? any clue why this is happening? any help would be very much appreciated!! WV_Table.fmp12
  12. For anyone interested in an npm package that communicates with Filemaker's data API, I am currently developing here - https://github.com/thomann061/fmrest
  13. Hi I am experimenting with Treemaps using the D3.js and D3plus.js libraries in FMPro Advanced 15 and the Webviewer (OSX 10.11). D3plus.js is really nice as it makes it much much easier to implement a Treemap using a simple JSON object containing your data. But sometimes thing don't work as expected and I don't fully understand why: - I invoke D3plus code in a FileMaker global text field, as a data:url, iincluding the D3 and D3plus libs in an external reference (I don't include the complete code in the text field). So these are loaded at runtime. - this works fine, but sometimes the treemap hich is a complex SVG graphics generated by D3) defaults to a 200x200 px area. Reloading the webviewer usually fixes the problem (or manually changing the HTML body, by adding a space, wihich forces the webviewer to refresh its contents). But my question remains: why and when does this happen? My guess is that at times the Javascript code is not loaded in the proper order, but I can't figure out how to influence this. The D3.js is invoked prior to D3plus.js, and all D3plus code is executed after these libraries are invoked. Anyone with similar issues?
  14. I have a web page that I want to display in a web viewer. It uses an HTML5 Canvas and Javascript to display a map. The page loads fine in a browser but in a webviewer the HTML loads but the referenced javascripts never run. Does anyone know why? or how I can get it to work? link to the page I am trying to load in a webviewer Any insights would be appreciated.
  15. Greetings - I got my start with CWP using FMwebstudio as the front end library to the FileMaker API (Dreamweaver). That library is no longer maintained. One of very cool things about that library was a dynamic field capability, fmsLiveInputField, where the changes you made in a web page were updated into the database in real time. I used it for event registration where the total attending and fees due automatically updated. I'd like to replicate this functionality ... display the total due, a show a few other live calculations. I prefer a PHP solution but realize javascript might be a better approach these days. I'm not a javascript guru so your help pointing me in the right direction would be helpful. And I do not want to use WebDirect due to the public pacing nature of this site and unpredictability in users active. Thanks!
  16. Hi everyone, We have a newly deployed OS X 10.10.5 Server with FMS14 installed with only 3 databases hosted, all accessible via Web Direct. Now some of our customers are experiencing difficulties with even accessing our solutions, which we have narrowed down to local network problems at our customers. The problem is, the login window is not showing, and therefore they can't access the databases. Now, the problem is somehow browser based.. I went through the login process with a customer, which was sitting with Windows 8.1 / IE.. Now when trying to connect to the database the customer gets the following message "Failed to load the bootstrap javascript ./VAADIN/vaardinBootstrap.js" I then tried to connect to the database through Chrome, which worked perfectly fine! Is there something I can do for the customer or on our Server, to prevent this message for future customers? Best regards Christoffer
  17. Hey Fellow Easy Sync-ers. I have an idea for improving the speed of the Sync Check step. Instead of comparing UUID lists in loops, we can retrieve a UUID list from server, and compare it to the client UUIDs using a couple lines of JavaScript in a webviewer. I've tested this and my Sync check time comparing ~23000 records, over 18 sync tables on a shared server has gone from 5-10 minutes down to a few seconds. No plugins necessary. Process: Get UUIDs_client. Get full UUIDs_host list from server Format both as JavaScript arrays and put them into a web viewer to be compared using 'filter' Have the webviewer call another script using FMP url to return the resulting diff array as a list. Process the diff like normal (The way Tim wrote it). I also updated the Sync Check process to pull the Server UUIDs in segments if they exceed the $$max_pull_segment_size setting. Here are my example files. Try adding a bunch of records and then run the sync to see how quick the sync check is. PLEASE NOTE: This method requires a named webviewer on the client EasySync_Payloads layout. EasySync v1.3 mod1 (jwillinghalpern@gmail).zip
  18. I'm using a web viewer to display a html webpage that allows the user to interact with it via java scripts. The web page works on a Mac running FM13 and FM14 with Mac OS X 10.10 and 10.11. When I try to view the web page in a web viewer on Windows 7 running with IE11 installed, the webpage doesn't allow any interaction with the java scripts, and the web page renders incorrectly. I'm running FM13 and FM14 in Windows 7, and they both render the webpage incorrectly. When I copy the HTML out of FileMaker and paste it into a file and open it directly in IE11, I get a security warning on the bottom of the window that says "Internet Explorer restricted this webpage from running scripts or ActiveX controls", when I click Allow, the page renders correctly. If the Allow button is not clicked, the page would render exactly like it does FileMaker's web viewer. So it looks like FileMaker is suppressing this popup and just showing the web page with the scripts disabled. I checked Internet Options in IE and all relevant scripting options are enabled, but every time I try to display the page in IE directly, I get the security warning. So I'm assuming if I can get the page to display in IE without the prompt I can get the page to display in FIleMaker. What options need to get set to allow the scripts to run? Why does it work on Mac OS X and not Windows 7?
  19. Hi there, I am using EasyMaps and trying to integrate into my own solution. I am loving it so far, however, I have run into issues when trying to create infoWindow on Marker Click. I had it working within maps as a standalone setup in my database before I integrated EasyMaps but now i can only load a blank screen. Here is my code. I know it's flawed, I just don't know where lol. "<!DOCTYPE html>¶ <html>¶ <head>¶ <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\">¶ <meta charset=\"utf-8\">¶ <title>FMEasyMaps " & Get ( CurrentTimestamp ) & "</title>¶ <style>¶ html, body, #map-canvas {¶ height: 100%;¶ margin: 0px;¶ padding: 0px¶ }¶ </style>¶ ¶ <script src=\"http://maps.googleapis.com/maps/api/js?key=[[API_KEY]]&v=3.exp&sensor=false\"></script>¶ ¶ <script>¶ ¶ function initialize() {¶ ¶ var positionLatlng = new google.maps.LatLng([[START_COORDS]]);¶ ¶ var mapOptions = ( {¶ zoom: 5,¶ center: positionLatlng¶ } );¶ ¶ var map = new google.maps.Map(document.getElementById('map-canvas'), mapOptions);¶ ¶ var contentString = '<div id=\"content\">'+¶ '<div id=\"siteNotice\">'+¶ '</div>'+¶ '<h1 id=\"firstHeading\" class=\"firstHeading\">Tony McShane</h1>'+¶ '<div id=\"bodyContent\">'+¶ '<p><b>TONY</b>, also referred to as <b>Epic Douchebag</b>, is a dude from cranny' +¶ '</p>'+¶ '<div id=\"link_div\" style=\"text-align:centre\">'+¶ '<a href=\"fmp://REMOVED/iCOMPLI%20Auditor_Tenancy%20Lite%20MetCash%20upgrade.fmp12?script=goto_iCompli%20Map%20Info%20Window%20Button%20Click%20TEST\">View Client Record</a>'+¶ '</div>'+¶ '</div>'+¶ '</div>';¶ ¶ var infowindow = new google.maps.InfoWindow({¶ content: contentString¶ ¶ });¶ ¶ });¶ ¶ var bounds = new google.maps.LatLngBounds();¶ ¶ [[MARKERS]]¶ ¶ google.maps.event.addListener(marker, 'click', function() {¶ infowindow.open(map,marker);¶ });¶ ¶ map.fitBounds(bounds);¶ ¶ }¶ ¶ google.maps.event.addDomListener(window, 'load', initialize);¶ ¶ </script>¶ </head>¶ <body>¶ <div id=\"map-canvas\"></div>¶ </body>¶ </html>" Any help would be appreciated.
  20. In FMP 13.02 FileMaker apparently fixed the FMP URL for the desktop client, such that it could be used to make a call to the same/local/self file. So I would have a web viewer in a solution and it would use an "fmp://web.address/dbname..." URL that would reference itself, the file that was currently open. I found some references to how to do this, but for some reason things aren't working for me. Apparently, if you are on a non-mobile platform, you need to use "$" as the IP address to reference the local file. E.g. "fmp://web.address/dbname.fmp12?script=AScriptName&$var1=1234&$var2=abcd". This would make the database essentially accept AJAX calls. (Although an unanswered question for me is how does the response or data get back to the web viewer. But for now, I just want to register event that trigger sending new data into the DB.) Here's the code I am using for my web viewer definition. The short description is that I am trying to integrate Full Calendar into a web viewer in a solution. I am trying to configure the onDrag event so that when an event is modified it sends the new date range back to the DB. ----------------------------- Let ( [ _IPDestination = If ( Left(Get(FilePath);7) = "fmnet:/"; Get ( HostIPAddress ) ; "$" ) ; _fmpURLString = "fmp://" & _IPDestination & "/" & Get(FileName) & ".fmp12" ; _fmScript1 = "?script=FullCalendarChangeDate"; $CurrDate = "2015/7/01" //hardcoding for testing purposes ]; "data:text/html, <!DOCTYPE html> <html><head><meta charset='utf-8' /> <link rel='stylesheet' type='text/css' href='http://cdnjs.cloudflare.com/ajax/libs/fullcalendar/2.3.1/fullcalendar.min.css'/> <script src='http://cdnjs.cloudflare.com/ajax/libs/moment.js/2.9.0/moment.min.js'></script> <script src='http://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js'></script> <script src='http://cdnjs.cloudflare.com/ajax/libs/fullcalendar/2.3.1/fullcalendar.min.js'></script> <script> $(document).ready(function() { var httpXHR, fmpurl ; $('#calendar').fullCalendar({ defaultDate: '" & $CurrDate & "', editable: true, allDayDefault: true, eventStartEditable: true, eventDurationEditable: true, dayClick: function() { alert('a day has been clicked!'); }, eventDrop: function(event, delta, revertFunc) { if (!confirm(event.title + ' was dropped on ' + event.start.format() + '.nAre you sure?')) { revertFunc(); } }, eventResize: function(event, delta, revertFunc) { if (!confirm(event.title + ' end is now ' + ( event.end.format() ) + '.nnIs this okay?')) { revertFunc(); } else { fmpurl = '" & _fmpURLString & _fmScript1 & "&$eventid=' + event.id + '&$newEndDate=' + event.end ; httpXHR = new XMLHttpRequest(); httpXHR.open("GET", fmpurl, true); } }, events: [ { id: 1, title: "Project 1", start: "7/1/2015", end: "7/3/2015" }, { id: 2, title: "Project 2", start: "7/3/2015", end: "7/7/2015" }, { id: 3, title: "Project 3", start: "7/7/2015", end: "7/7/2015" }, { id: 4, title: "Project 4", start: "7/7/2015", end: "7/11/2015" }, { id: 5, title: "Project 5", start: "7/14/2015", end: "7/16/2015" }, { id: 6, title: "Project 6", start: "6/18/2015", end: "7/3/2015" }, { id: 7, title: "Project 7", start: "7/30/2015", end: "8/15/2015" }, { id: 15, title: "Project 15", start: "6/08/2015", end: "6/19/2015" } ] }); }); </script> <style> body { margin: 0; padding: 0; font-family: "Lucida Grande",Helvetica,Arial,Verdana,sans-serif; font-size: 14px; } #calendar { width: 900px; margin: 40px auto; } </style></head> <body> <div id='calendar'></div> </body> </html> " ) ----------------------------- In the middle of that you will see these three lines, where I am trying to make that call back to the local file from the webviewer: fmpurl = '" & _fmpURLString & _fmScript1 & "&$eventid=' + event.id + '&$newEndDate=' + event.end ; httpXHR = new XMLHttpRequest(); httpXHR.open("GET", fmpurl, true); Any one have experience achieving this? Todd Geist's Watermark module uses this technique but I can't seem to extract that functionality for my own purposes here. Thanks, -- Justin
  21. Hey and good morning from Europe! I have a problem saving javascript in global field. When I quit Filemaker, changes goes away and reverts back to old one. Is there a workaround for this? This raises question for other people who needs to run the javascript? We are using Filemaker 13.0v3 & Filemaker Server 2013 Would one solution be to save it as normal field and make a script to update the global field which triggers when user need's the script? Or is there a better solution for this? Thank you for all the help I can get!
  22. Hi, I have run into a standstill here where maybe someone could point me in the right direction. This is for a large personal project that I have been working on for a few years. I have considered all the possibilities with FM and looked at add-ons, but this is the first time I think I cannot find an answer. I have used the Webviewer just to navigate through a website to get to a certain page to scrape. That works great. In this usage, I want to do more than just scrape. I want to load the page in FM (on the webviewer), take the "content" (client-side HTML), run it through a comparative analysis in FM, append text to it line-by-line, and then reload that back into the Webviewer. The only problem is that the reload process always causes the Webviewer to get rid of any other website files, in particular Javascript files, which this web page needs in order work correctly. Right now I am working around this by using an earlier (alternate) version of my script. I first open the web page using the web browser Opera, cut and paste the HTML from that using the Windows clipboard, dump it into a global text field in FM, run my script on that, then cut and paste that back into Opera and click Update, which replaces the HTML but leaves everything else alone. Is there any way I could use the Filemaker Webviewer (or possibly some plug-in) to do similar - only replace the HTML, but leave all the other website files (javascript) as-is?? It has to be using some sort of web viewer, as I will manually be selecting options from the updated web page and submitting to a local web server. Thanks Chris
  23. I'm trying to use TinyMce in a webviewer in FileMaker but save the resulting HTML into a database field. I am aware of the standard practice of using an fmp:// link with a script & parameter, but that won't work in Windows (the html content returned as the parameter will likely exceed the 2048 character limit). I am using a javascript function to change the HTML DOM by putting the contents of the TinyMCE editor into another div on the page when the user clicks "Submit" inside the webviewer. However, when I use `GetLayoutObjectAttribute ( "webviewer" ; "Content" )` it shows the content of the unmodified (pre-javascript altered) page, not the page after javascript has modified the DOM. Sample file: http://cris.lc/sxti2 Is this expected behavior? Am I doing something incorrectly?
  24. Hi guys, problem here. I'm working with a web viewer and I'm familiar with triggering a script from within the web viewer using the fmp:// protocol. But, what I need is kind of the opposite. I have a 2000 records list that I need to display in my webviewer. As one may find, that is lots of html data, what makes my solution very slow. What I want is a webviewer that displays the first records and, when I scroll down (my first option) or I click a button (second option, but also ok) it displays more records. I'm aware that I could do that using the url protocol, calling a script, rewriting the html code for the webviewer, but that seems as a dumb solution So, it's my understanding that javascript can change the html of a webpage (played a little with javascript, but not a master). So, in theory, there is a way for javascritp to append to the end of my <body> the next record I could use the ExecuteSQL function (not the script step) if it worked, but I'm not sure how to do that without hardcoding the change of the webviewer code, and I rather not do that. I'm really hoping I can handle it from the webviewer I have a hard time being brief. What I want is to pass a parameter from the filemaker to javascript to execute its function. Any help will be overwhelmingly appreciated
  25. Hi, I have some html/javascript that I'm trying to display in the webviewer. This code will display a google map with 6 pins in every browser I've tested it in, but shows a blank page in the WebViewer. Any idea as to what I need to do to fix this would be really appreciated. I'm on FMPro11 on Mac OSX Lion. (I removed my GoogleKey, gut this code should still work as v3 doesn't require a key) data:text/html, <!DOCTYPE html> <html> <head> <meta charset='utf-8'> <title></title> <meta name='viewport' content='initial-scale=1.0, user-scalable=no'> <style type='text/css'> html { height: 100% }body { height: 100%; margin: 0; padding: 0 }#map-canvas { height: 100% }</style> <script src='https://maps.googleapis.com/maps/api/js?&amp;sensor=false'></script> <script> var geocoder; var map; function initialize() { geocoder = new google.maps.Geocoder(); var latlng = new google.maps.LatLng( 43.670234 , -79.386737 ); var mapOptions = { zoom: 11, center: latlng, mapTypeId: google.maps.MapTypeId.ROADMAP } map = new google.maps.Map(document.getElementById('map-canvas'), mapOptions); var locations = [ '229 Ashworth Avenue, Toronto ON', '1112 Queen Street East, Toronto ON', '889 Yonge Street, Toronto ON', '1711 Melrose Avenue, Toronto ON', '2500 Yonge Street, Toronto ON', '45 First Avenue, Toronto ON' ]; var i; for (i = 0; i < locations.length; i++) { geocoder.geocode( { 'address': locations }, function(results, status) { map.setCenter(results[0].geometry.location); var marker = new google.maps.Marker({ map: map, position: results[0].geometry.location });});}} google.maps.event.addDomListener(window, 'load', initialize); </script> </head> <body> <div id='map-canvas'> </div> </body> </html>
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.