I have recently started creating a Azure Bot in Node js. I want to add a hyperlink in one of the bot response and send a proactive response after user has clicked on it.
Something like:
Please click this link to complete the payment.
and the link should be a hyperlink that will redirect to an endpoint.
I have tried finding a way to achieve it but so far, I haven't been able to achieve. I have seen the following link:
https://learn.microsoft.com/en-us/azure/bot-service/rest-api/bot-framework-rest-direct-line-3-0-send-activity?view=azure-bot-service-4.0
https://learn.microsoft.com/en-us/azure/bot-service/bot-builder-howto-add-media-attachments?view=azure-bot-service-4.0&tabs=javascript
Can some one suggest me the way to achieve this.
You can use markdown syntax.
The text must be treated as markdown formatting and rendered on the
channel as appropriate.
Hyperlink markdown syntax :
[click this link](https://www.google.com/)
As per your code it would look like the following:
Please [click this link](www.greetings.com) to complete the payment
Reference:
Format text in chatbot
Markdown syntax
Related
While there is good documentation around sending markup emails for specifying offline event. Refrence Can someone help me out on how to add handle an online event?
The issue with offline event is that I need to enter a proper postal address, however in our case the location is simply a url.
Things I have already tried
Putting type of location as VirtualLocation, but that gives error
Entering empty strings in PostalAddress fields
Marking eventAttendanceMode as https://schema.org/OnlineEventAttendanceMode, it gives error
Does gmail support markups for online events? Common sense says it should.
As said by #kayes-fahim comment you can find more information on their blog, and documentation.
By the blog post you could use the virtualLocation but you also need to set the eventAttendanceMode to OnlineEventAttendanceMode. Reference
I want to embed a snippet code at my LinkedIn article, like that:
That image is from Gitlab snippets (https://gitlab.com/snippets/1841785). Is there some way to render its content in the LinkedIn articles? I saw that post at my LinkedIn feed and I got curious how to do this.
I noticed that Gitlab provides two way to get the snippet: a embed or share content. How should I use?
Thank you.
Use https://carbon.now.sh/ for creating beautiful code snippets and download the pic and use it wherever you want
LinkedIn rendering for code snippet is very basic (white text on a black background, no keywords or strings highlight). My favorite way to share short snippet of code on LinkedIn is by creating an image (like the one you included here) and link the image to the original code on GitHub.
I want to define a new template called "product".
This template calls an external service and retrieves the information about that specific product. That is easily done with a custom plugin that access the product information. Information on how to do that has been found here.
However, I would like that the URL of the page would be something like:
/product/<id>/<seo-friendly-description>
So I can retrieve in the Twig template both <id> and <seo-friendly-description> which will be used later to retrieve the specific product information.
I have tried to find something that could help in the documentation, without success. Could someone either point me to the right doc section or highlight the basic steps that shall be achieved so I can start solving this issue?
Just in case it helps, I am trying to find something similar to how bottle or other web frameworks work:
#route('/hello/<name>')
def greet(name):
return 'Hello ' + name
I've been building a family recipebook into my own website and I've been working through a similar problem. I haven't quite worked out all the kinks, but my solution is mostly working if you want to checkout my github repo.
In short, you need the plugin to watch what the active route is. If the route matches, you then create the page and populate it using your plugin data.
I haven't quite figured out how to get the active page to highlight in the navigation menu for generated pages, but you might still find this solution helpful.
Telegram bot sends me a message with a text snippet, which I want to edit, and send back to the bot for further processing.
Copy and paste takes time. Typing message anew takes time.
Ideally I'd like to press an inline button "Edit" on the bot's message and get the message text appear in my reply input box for editing.(A message id attached to my reply somehow would be a plus).
I tried to use deep linking with parameters other than /start*, but that doesn't seem to work.
Can I use bot API (or any other telegram API) to have text ready for editing in my input box?
It's impossible in official apps yet. Your question is about working with drafts - there are no methods in both API to create them or clear.
Nevertheless, you could fork any official app stored on GiHub and implement what you need if you would prefer a hard way, but compared to that copy/past solution seems much more easier, isn't it?
UPD
I can offer to you a new idea how to solve your problem - hope it will be helpful.
This is about switch_inline_query_current_chat field of InlineKeyboardButton. Just attach an inline button to messages you need to edit. Set a text for this field gotten from recieved message and after pressing you will get this text to your input area. All seems good, but you will take bot's username before the text also.
I am working on an e-learning website and developing code editors for php.
I just want it to be like the Code Editor of W3Schools "Try IT Now".
I want to enter the code in the left side and want to get output in the right side.
As per my analysis, "ACE Code Editor" is the best one for this task, but I am unable to integrate that in my website.
I am trying to explain my problem.
I have created two text area with same CSS property
One is hidden and one is visible
When user type code then both text area get the entered code.
Post getting the PHP code, it need to send to server using AJAX..
Now I am having problem with AJAX. I don't know how to send PHP code to server using Ajax and how to get output in return.
I take reference from here