Article
· Dec 12, 2016 3m read
Generate and Validate Captcha Code

Suppose you have developed your own web app with InterSystems technologies stack and now want to perform a captcha validation on the client side in order to determine whether or not the user is human and make it safer. There are some modern frameworks to address the captcha issue, however most part of them needs internet access to generate codes and sometimes are complex to implement. Take this as basic example considering that image recognition has gotten too good. That's why you nowadays you tend to see more pattern recognition captchas than mere reading ones. (I.e.

7 9
2 1.4K

When refreshing a html or tablePane component using refreshContents() that takes a lot of server-side-processing, I'm running into timeouts every now and then. i.e., the result for the tablePane is that there's nothing displayed at all.

How can we configure (relax) that timeout so also those heavier ones get refreshed eventually? Just overriding %request.Timeout in %OnPreHTTP did not seem to do the trick.

0 2
0 803

Hello,

I am trying to use %ZEN.proxyObject to send out in JSON format so I do:

set tProxyRequest = ##class(%ZEN.proxyObject).%New()
set tProxyRequest.notanumber = "28001"
set tProxyRequest.aboolean = "true"

set tBody = ##class(%GlobalCharacterStream).%New()
do ##class(Ens.Util.JSON).ObjectToJSONStream(tProxyRequest,.tBody,"aelotwu")
w tBody.Read()

and I get:

0 10
0 1.4K

Intro

Please note, this article is considered deprecated, check out the new revision over here: https://community.intersystems.com/post/tutorial-websockets

The goal of this post is to discuss working with Websockets in a Caché environment. We are going to have a quick discussion of what websockets are and then talk through an example chat application implemented on top of Websockets.

13 28
4 18.7K

Does anyone have any experience with getting, unfortunately, an older version of Cache to authenticate via SMTP to send email? I have verified that the settings are set up properly on the mailbox as I have successfully sent an email from a LAMP server, which comes from the same IP address.

If you have any thoughts, I would greatly appreciate it.

This is the error I receive

ERROR #6034: SMTP server connection failed during MAIL FROM command: <READ>zSend+105^%Net.SMTP.1.

0 6
0 2.4K

I cannot connect to Cache from node.js

I have installed in Windows 10 the following: CACHE 2016, node.js v 4.4.7 and express .

- where can I get cache.node? The link in the Intersystmes documentation http://globalsdb.org/downloads/ doesn't work. I found cache0100.node and cache0120.node in my Cache instance's \bin directory. But I am not sure if I can use them or not.

- how to install cache.node ? Where do I place it exactly?

Can anyone recommend any tutorial or code example with installation instructions?

1 12
1 3.4K

In this article I would like to present the RESTForms project - generic REST API backend for modern web applications.

The idea behind the project is simple -after I wrote several REST APIs I realized that generally, REST API consists of two parts:

  • Work with persistent classes
  • Custom business logic

And, while you'll have to write your own custom business logic, RESTForms provides all things related to working with persistent classes right out of the box.
Use cases

  • You already have a data model in Caché and you want to expose some (or all) of the information in a form of REST API
  • You are developing a new Caché application and you want to provide a REST API
12 23
3 5K

I would like to write some code to parse a set of HTML pages from the internet in order to gather information from each web page.

All of the web pages are generated using a template, so the format of each of the web-pages is consistent with one-another and the information that I want to gather is always located in the same logical place within the page.

What is the best way to parse an html page in order to gather information at a specific place?

Can XML XPATH be used here? Does anyone have any examples of parsing HTML content?

2 6
0 1.4K

I have a CSP page that needs to allow the user to submit a file. I have a form with an element in it <input type="file" name="file"/> which allows the user to select the file they want to upload from their local filesystem.

How do I go about actually getting the file to be sent to the server?

0 5
0 1.3K
Question
· Dec 14, 2016
How do I free licenses?

I have a server with public web application with Unauthenticated access and there seems to be a problem that CSP session ends, but associated license persists for some time (hours). If several users log in, we can hit license limit and all the other users get 503 Service unavailable error.

We are currently debugging it and moving to authenticated web applications, but is there a way to free these licenses quickly?

Here's how it looks like in SMP:

0 1
0 685
Article
· Dec 7, 2016 3m read
Enable CORS for CSP/ ZEN Applications

As web application gets more complex, more technologies are involved into the application development. Once it gets deployed in large scale the configuration gets more complex too. For sure one of the most difficult part of the story is the security. In a complex solution when independent servers are feeding single web pages with contents, it is indeed challenging to keep the integrity of such system. HTML5 introduced a (weak) security constraint, the Cross Origin Resource Sharing (CORS). This article tells how to enable CORS for CSP/ ZEN applications.

2 2
0 1.4K
Question
· Dec 7, 2016
Login Routine

Hi all,

Which routine use to get username and password (telnet) ?

cache version :Cache for Windows NT (Intel) 5.0.21 (Build 6408) Tue Jan 3 2006 13:28:20 EST

Thanks,

sansa.

0 1
0 319

Caché Localization Manager

CLM is a tool for localization/internationalization/adding multi-language support to a project based on InterSystems Caché.

Imagine that you have a ready project where all the content is in Russian, and you need to add an English localization to it. You wrap all your strings into resources, translate them into English and call the necessary resource for Russian or English when necessary. Nothing tricky, if you think about it. But what if there are lots of strings and there are mistakes in Russian (or English)? What if you need to localize in more than one language – say, ten? This is exactly the kind of project where you should use CLM. It will help you localize the entire content of your project into the necessary language and retain the possibility to correct entries.

6 4
0 922

We are trying to understand how websocket connections from a javascript client may timeout in cache. Does anyone know if and of the session timeout or any other timeouts apply to any synchronous websocket connections? I have not been able to prove that they do timeout at all.

0 5
0 585
Announcement
· Oct 21, 2016
Zen Mojo 1.1.2 released

I am happy to share the news that Zen Mojo 1.1.2 has been released. This release includes a critical fix for Firefox that we had to get out as fast as possible. No other changes are included to allow easy upgrades. We recommend upgrading to this release if you are running on Zen Mojo 1.1.1.

All upcoming Caché and Ensemble releases will ship with Zen Mojo 1.1.2.

You can download Zen Mojo kits from the WRC distribution page: https://wrc.intersystems.com/wrc/Distribution.csp

2 0
0 324
Article
· Oct 4, 2016 1m read
How to Parse a URL in Caché

How to parse a URL in Caché:

Let's pretend you are working on a project where you may be retrieving a URL for some purpose and you have the need to be easily able to parse apart that URL to get the various components that make up the URL.

Here's how to do that:

2 8
0 1.7K