Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 2221 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted (edited)

Hi all,

 

I am trying to make a folder and export a container into it on a mac server using BaseElements plugin "BE_CreateFolder" and "BE_ExportFieldContents" but no matter what directory I select, it returns Error #13 (CURLE_FTP_WEIRD_PASV_REPLY (13) >> libcurl failed to get a sensible result back from the server as a response to either a PASV or a EPSV command. The server is flawed.)

 

I have tried get(TemporaryPath), get(DesktopPath) and get(DocumenstPath) with no luck.

The main goal is to be able to send SMTP emails with multiple attachments using "BE_SMTP_Send" and "BE_SMTP_AddAttachment" from Server machine.

 

Please let me know if you need more information.

Thanks in advance for any help.

 

Regards,

Edited by siroos12
Posted

Have you tried doing away with the export step and just emailing straight from the container fields? BE_SMTP_AddAttachment will allow you to add the container fields instead of file paths.

Posted

Try "BE_Curl_Set_Option ( "BE_CURLOPT_FORCE_STARTTLS" ; True )" before the BE_SMTP_Server step, or remove username and password. Also double check you can send via your smtp server with other means, i.e. Outlook.

Or, if the attachment was created by filemaker in the first place, try and manually insert an attachment in to the attachment field and try that.

Posted

Hi sal88,

 

It is just working fine on Windows. But it does not on MAC. The BE_SMTP_AddAttachment actually export the container contents into a temp folder and then use its path for attaching the file to SMTP email. It does export it successfully on windows and I could see the created file.

 

It seems the problem is that FM server can not save/export container content to a temp folder on my MAC server. I have checked the temp folder on Mac and it seems neither me as administrator nor FM server has "Read/Write" access to the folder. Then I tried to add the access with no luck. I get the error of not having permission to do this while I have administrator permission on MAC.

 

So I believe it is some sort of access permissions to temp folders on MAC. any advise on that?

Posted

Okay, actually FM Server has "Read/Write" access to temp folder but not me as administrator. So I can not check to see if the file is created on Mac or not. Then I tried to make a folder on desktop and documents folder using "BE_CreateFolder" and it does not.  

Posted

To use BE_SMTP_AddAttachment you need access to the temporary folder as it exports the container content and use it for sending SMTP email.

When you run a script on server (MAC) to set BE_SMTP_AddAttachment, the temporary folder is in /var/folders/ but it has not the right privileges for FM server and you cannot change them, even not as the administrator user. So, the BE_SMTP_AddAttachment is not able to export the field content and email is sent with no attachment.


I tried to export the container and add it to a global container to using BE_ExportFieldContents but it fails due to the same reason of wrong privileges.
 
I really appreciate any advise on it.

  • 2 weeks later...
  • 2 weeks later...
Posted
On 2018-03-13 at 2:30 PM, siroos12 said:

I have tried get(TemporaryPath), get(DesktopPath) and get(DocumenstPath) with no luck.

BaseElements does not take FileMaker formatted paths, it takes system paths. If you don't want to deal with path format issues, use my module instead: http://www.modularfilemaker.org/module/path/

 

Posted
On 2018/04/05 at 1:18 PM, dansmith65 said:

BaseElements does not take FileMaker formatted paths, it takes system paths. If you don't want to deal with path format issues, use my module instead: http://www.modularfilemaker.org/module/path/

 

By using "/Users/username/Desktop/myNewFolder" as a path to create a folder, I get the results but only when I run it on FM client. When I run the very same script on server using PSOS, I still get the error #13. 

This would confirm that the path format is correct and plug-in is working. The issue appears when the script runs on server side.

 

Any advise on ho to get it working on server?

 

Server details:

FileMaker Server 16

macOS High Sierra

version: 10.13.3

Posted

My bad. You were right. The problem was the wrong path format. 

 

This below path worked like a charm.

 

Substitute(Get(TemporaryPath)&GetContainerAttribute ( Container; "filename"); "/Macintosh HD" ; "")

 

Thank you all for your help!

Posted

Glad you got it to work. To clarify the issue from your first post today; Desktop isn't available to server-side scripting, as per the link posted earlier in the thread.

Also, if you were to use my Path module, your code would automatically work on a Windows server as well. Right now, your code would fail if you did that.

  • Like 1
  • 4 months later...
Posted

My situation is a bit different.  My server script is writing the desired PDF file to the Documents folder, (FileMaker Server/Data/Documents)  on a Mac server, but then, it is unable to insert that PDF into the target container field.   When I run the same script on my FMP client, it works perfectly.

This is a routine that was working fine in FMS 16 on Windows, but when the database moved to FMS 17 on Mac, it stopped working

I tried running a simple test script to see if Base Elements could create a folder.   The FMP client does it just fine, but the server running the same script yields error 13.

Again, I am not concerned with making folders.  I just want to take the file that is in the Documents folder and insert it into a container field.   Seems to me that the Documents folder should not have a permissions problem, especially if FMS can create documents there.

  • 1 month later...

This topic is 2221 days old. Please don't post here. Open a new topic instead.

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
×
×
  • Create New...

Important Information

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