Jump to content
Tony Morosco

Problems converting Custom Web Publishing scripts from12 to 15

Recommended Posts

Hello,

I am trying to convert a custom web publishing site in php, from FM Server 12 to FM Server 15.    We've updated the Windows machine that hosts it (to a shared server on the recommendation of IT) and installed FM Server 15.  

Direct opening of the existing scripts always yields 0 results, though the database hasn't changed.  

Is there some setting, somewhere, that I am oblivious to?   I've consulted user's manuals, IIS settings, web postings, ...

Attached is a copy of the website I am running.

I can point you to the existing website, though I doubt it would be useful.  The beginning part of this website are script tracking errors.  I've been inserting them, trying to track down where this error is creeping up.  So please ignore.

Please ask any additional questions, I am sure there are many.

Cheers,

Tony

 

 

PublicPortal.zip

Share this post


Link to post
Share on other sites

A number of things come to mind:

1) Updating the machine (probably) involves updating to a new php versions and IIS, either of which could be playing  a part in the failure.  Come back to that later after #2.

2) I would want to know what $result FMP Server is reporting after any query.  Try adding print_r($result); exit; after the query to see how FMP is responding..

 

Hope that helps.

Jonathan

Share this post


Link to post
Share on other sites

Hi Jonathan,

Early on, I did end up reverting the php back to the FileMaker supplied files, and removed the extraneous php version that IT  had installed.  However I seem to be running into the same issue, so the versioning does not seem to be an issue.  I'm now running under php 5.6.24, and Microsoft Windows 2012 R2 Standard.

For the second question, I've inserted this directly after the database call.  Here is what it produces: 

FileMaker_Result Object
(
    [_impl] => FileMaker_Result_Implementation Object
        (
            [_fm] => FileMaker_Implementation Object
                (
                    [V73ee434e] => Array
                        (
                            [charset] => UTF-8
                            [locale] => en
                            [logLevel] => 3
                            [hostspec] => http://127.0.0.1
                            [recordClass] => FileMaker_Record
                            [prevalidate] =>
                            [database] => location
                            [username] =>
                            [password] =>
                        )

                    [Vea4b3413] =>
                    [V9a3dcbce] =>
                )

            [_layout] =>
            [_records] =>
            [_tableCount] =>
            [_foundSetCount] =>
            [_fetchCount] =>
        )

 

 

Share this post


Link to post
Share on other sites

Tony,

Looks like you received a valid result from the query. I assume that there was more to the result other than what you posted. 

Moving forward,  what happens after this?

Share this post


Link to post
Share on other sites
19 hours ago, jbschwartz said:

Tony,

Looks like you received a valid result from the query. I assume that there was more to the result other than what you posted. 

Moving forward,  what happens after this?

If I follow up the print_r($result); with the following, 

     $statusLinks = getStatusLinks("recordlist.php", $result, $skip, $max);
     $records = $result->getRecords();   
     echo "\n<P>Records: ";
     echo $statusLinks['records']['rangestart'];
     echo " - "; 
     echo $statusLinks['records']['rangeend'];
     echo " of "; 
     echo $statusLinks['records']['foundcount'];
     echo ". <P>\n";
     exit;

I still get the following:

Records: 0 - 0 of 0.

I know this script ran for many years under a previous version of FileMaker, so very frustrating for me to update!  :-P  I did the initial design, but had a little thing called an AVM since then (a stroke.)

Share this post


Link to post
Share on other sites

Tony,

This looks like code generated by SiteAssistant...which was a flawed concept from the start.  But we won't go there.

Going back to the $result you posted, I realized that it's not returning any results. Everything up to the last 5 lines is normal. but the last 5 lines represent arrays (layout, records, etc) and is supposed to be populated with literally hundreds/thousands lines of data.  Can't expect the record link functions to work without having data to work with.

Is this system online? I can try and resolve from here.

Share this post


Link to post
Share on other sites

Hi Jonathan ,

Yes, this site was originally generated in SiteAssistant back in 2010 or so.   It's only recently updated to FileMaker Server 15 this year, thus the problems.  

Yes, I know it isn't returning any results, which is what I was looking for.  I probably didn't phrase it very well.

The online website is at http://cornucopia.sfbg.org/PublicPortal/home.php
and called PlantFinder.   (Obviously it looks for specimens at a botanical garden for the public.)

But I presume you need to get into the computer.   Will have to see if I can swing that. 

Why don't you contact me and I'll see what I can do!  tmorosco@gmail.com

 

Many thanks!  I'll post any follow-up results here, once we get this solved.

Cheers,

Tony

Share this post


Link to post
Share on other sites

Hi all,

We ended up re-creating the site in FM WebDirect. 

It was much simpler, than trying to suss out the problems with the older pHp custom web publishing scripts.

So I am sure this thread won't be of much help for future researchers.

Cheers,

Tony

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Similar Content

    • By jstewart30
      Running FMS 13 and trying to run a simple PHP page from my website to access a database, but I'm only getting a blank page.  Not sure if it's a port forwarding issue or a PHP issue, or something else.  If I put my .php file and the includes ("FileMaker.php" file and "FileMaker" folder from the FMS PHP .zip file) in the fmi-test folder on my FM server and access it locally (http://localhost/fmi-test/myphpfile.php), the PHP file works fine and returns data, so I don't think it has any inherent issues, and presumably my FMS is set up correctly.  Putting the same .php file and includes on my web server, though, results in a blank page only.  The includes are in the same directory as the php file itself.  Here's the php file (I've changed the IP address and database names to protect the innocent but they're correct):
       
      <?php
      error_reporting(E_ALL);
      ini_set('display_errors', 1);
      include_once('FileMaker.php');  /* have also used require, include, and require_once with no change */

      $fm = new FileMaker("MyDatabase", "http://myfilemakerserver:8888", "Admin", "");   /*no password*/
      $findCommand = $fm->newFindCommand("MyDatabase");
      $findCommand->addFindCriterion("Phone", "303-555-1234");
      $findCommand->setRange(0, 1);
      $result = $findCommand->execute();
      if (FileMaker::isError($result)) {
          echo($result->getMessage());
          return;
      }
      $record = $result->getFirstRecord();
      $name = $record->getField("Customer Name");
      $status = $record->getField("Status");
      echo("$name - $status");
      ?>
      Infuriatingly I get no errors or feedback, just a blank page when I run this file from my website (but again it works fine locally on the FM server machine). I've confirmed PHP is working on my website as I can do a simple phpinfo() file in the same directory and it runs fine and displays the PHP info.  If I direct a web browser to the same "http://myfilemakerserver:8888" (not the real address obviously, but it is port 8888) I get the "Filemaker Database Server Website" page, so the port forwarding seems to be correct.  I have port 8888 forwarding to port 80 of my FM Server.  I don't have port 443 forwarded to that machine as that's being used for another device on our network, but I assume if I'm not making "https" requests that it should work fine (but maybe that's my problem?).  
      I assume it's just something simple but I've been beating my head against a wall for the better part of the day on this.  Any help would be greatly appreciated.
    • By Joost Miltenburg
      LS,
      We are running FMserver with custom webpublishing. People can connect to the website and see pictures that are attached to propositions.
      The pictures folder is located on the FMServer as well and getting pretty big now. So we are complating moving the folder ( it is currently located in htdocs ( running on a Mac )).
      How do we reconfigure FMServer/apache to do this?
      Kind regards....
    • By Martin Taylor
      Hi all experts (hopefully), I have just upgraded from FMS12 to FMS16. On the FMS12 server we are running a php solution. I have installed 16 onto a new server, uploaded all the databases (all successfully running) and have copied the php website to the new location on the 16 server. I can see the website from home (so I know the website is in the right place and the DNS s working) BUT I can't seem to connect to the database successfully. Any help would be much appreciated. Thanks in advance. 
      Oh, and it is accessed with https
    • By Anthony Girdler
      Hi,
      My programmer and I are trying to set up communication between FileMaker 16 and a WordPress website(www.heightspethospital.com.au ) so our veterinary clients can do online booking and look up when their pets are due for vaccination and other treatments.
      My programmer has hit a problem.
      The code does not work on the WordPress Server (www.heightspethospital.com.au), though it works on his local machine.
      He gets the following error:
      “Communication Error: (7) Failed to connect to 203.206.217.177 port 8080: Connection timed out”
       
      Filemaker error codes suggest this is a memory issue, but my programmer is sure it's not related to memory.
      He has tried re-installing filemaker server multiple times with no effect. I think he said the default port is 80, but that cannot be used for an unknown reason and he has chosen to use port 8080.
       
      The filemaker database is stored on:
      PC Windows 10 home 64-bit
      Filemaker server 16
      Processor: Intel(R) Core(TM) i7-5820K CPU @ 3.30GHz (12 CPUs), ~3.3GHz
      Memory: 16384MB RAM
       
      Wordpress 4.8.1 hosted by SiteGround.
       
      Any answers or leads greatly appreciated.
      Anthony.
      PS. I don't know anything about programming and computer jargon, so I apologise if I have some of these terms wrong.
    • By Richard Carlton
      PHP VIDEO 2 - Process Walkthrough: https://youtu.be/yAQX0B9Hfyk
      PHP VIDEO 3 - Sample Code Review: https://youtu.be/9thUCa_q_eY
      Download Sample Code: http://fmstartingpoint.com/links/dl_proc.php?idc=CPN_S0067
      Live PHP Page to try out: http://fmstartingpoint.com/links/dl_proc.php?idc=CPN_R0068
      FileMaker CWP Guide: https://fmhelp.filemaker.com/docs/16/en/fms16_cwp_guide.pdf
  • Who Viewed the Topic

    11 members have viewed this topic:
    ggt667  Richard J  brana15  IdealData  bcooney  Lee Smith  doughemi  Tony Morosco  jvagla  jbschwartz  dansmith65 
×

Important Information

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