in Hip Chat notification any url i send in anchor tag with property "target='_blank' ", Hip Chat does not receive target property. Is there any alternative so that any url when i click open in new tab. Please help me for this.... Thanks
Hey Christopher,
Thanks again buddy for reply. Yes you are right, the url I had was just for comment. My complete anchor tag looks like this:
<a href="http://fake.link?from=2015-11-20T17%3A35%3A15Z&until=2015-11-20T19%3A35%3A15Z"> View All Anomaly Events </a>
Screenshot from 2017-01-10 10-45-17.png
Now when i click the link, its opening in same tab. I want it to be opened in new one. Please correct me if I am doing any kind of mistake also guide me how I should achieve this functionality.
It looks like you're doing everything correctly, given you have custom text for your link. My guess is that you either have a browser setting preventing the link from opening in a new page or there's a bug in the display code for the web client. I would suggest sending an email to support@hipchat.com referencing this post and they can help you out with your specific situation.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
A couple things:
1: You want to make sure that you're using the /room/<room-id>/notification API - the /room/message API doesn't allow for sending HTML, only plain text
2: The URL in your href attribute should include the scheme (e.g. https://www.google.com instead of just www.google.com)
Following those rules, I tried this with a test account and the resulting message link automatically opened up in a new browser (in Chrome):
image2017-1-9 17:47:22.png
The arguments I used for that message, for reference:
{ "color": "red", "message_format": "html", "notify": "false", "message": "Hey - I'm an API message... <a href='https://www.google.com'>click here</a>" }
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Chrostopher, first of all many thanks for your reply. Actually i am using the HipChat Api to send message to hipchat. The message is in html tags and this message contains anchor tag something like :
<a href="www.google.com"> Click Here </a>
In web client when I click on this link it gets open in same tab not new one(In chrome) . So please help me out for this one.
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Manoj - I'm not sure exactly what you mean. Are you sending a message through the API? All URLs in HipChat should open in new browser tabs automatically (whether you're using the desktop client or the web client). There should be no need to specifically add "target='_blank'" to provide that behavior.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.