At our company, we use chrome and have the 3CX chrome extension.
This extension is quite eager to transform any sequence of number into a clickable link to pass a phone call.
How to prevent the 3CX extension from converting sequences of numbers into clickable links on specific pages ?
So far we figured out that enclosing numbers in a <pre> or <code> tag does the trick. But we need something to disable 3CX as a whole on a webpage.
Does a special meta tag exists for this purpose ?
So I ran into the same problem my company uses 3cx extension, but it keeps modifying our page to add "click to call" links where it shouldn't.
I found this thread on the official forum which says that apparently they have no options to force the extension to ignore a specific website or field:
https://www.3cx.com/community/threads/disable-the-chrome-extension-for-my-website.79302/
But on the bright side, I implemented a hack on my field to force the extension to ignore numbers on my string, I added zero-width space after each number like this:
str.split(/(\d+)/g).join('<zero-width-space>');
the editor does not let me paste the code for the zero-width space, it can be acquired here: https://codepen.io/chriscoyier/pen/AwVNjg%E2%80%8B%E2%80%8B
Try this
Admin Panel>Extensions>Click to Talk> untick the box labeled "Click2Talk"at the top of the page.
Related
I have a client who's having trouble with Visual Editor on WordPress but I cannot, for the life of me, replicate the issue my client's having.
A little background...
For styling purposes, there are certain elements on the content area
with custom codes/data attributes hard-coded in Text editor by me. I
primarily work with Foundation framework (by Zurb) and if you're not
familiar, in the markup there are html attributes like 'data-tabs' or
'data-accordions' that enable certain stylistic components on the
front-end.
I also put a lot of effort in accessibility so there are
many instances where I add ARIA attributes wherever necessary.
My client deals with some educational analytical data, so there are some iframes embedded in the content area.
Problem arises when my client tries to edit text contents in the Visual Editor and the editor strips any custom code I put in, data attributes and outright deletes iframe altogether.
Here's what I've done so far:
Even before handing off the project monthes ago, I had added 'valid_elements',
'extended_valid_elements' rule set in the WordPress filter 'tiny_mce_before_init' to allow any kind of attributes/data sets I want
Ever since the issue has been reported, I added ARIA attribute specifically just to make sure that it's not being removed
For iframes being removed, I added extra rule that specifies iframe as a valid children of any container, and iframe can have all the necessary attributes it comes with
Switching back and forth between Visual and Text editor (at least on my environment), saving progress on both Visual/Text while editing content on the other sides, autosaving/drafting/forcing it to close and using browser backups did not cause codes/attributes/iframe to disappear so far (before handing the project to the client and after my client reported the issue).
I've tested with Chrome, Firefox, Internet Explorer, Safari, and Opera on both iOS and Windows environment
I asked my client what their work environment is like, and my client is using Mac, and according to my client, there is no browser extentions like adblock or script block installed on Firefox/Safari
This is what I added in the filter before my client even reported having the problem:
$opts = '*[*]';
$initArray['valid_elements'] = $opts;
$initArray['extended_valid_elements'] = $opts;
I added extra and modified the rules since, and this is what I have right now (in functions.php):
$initArray['valid_elements'] = $opts. ',#[role|aria-hidden|aria-checked|aria-selected|aria-pressed|aria-label|aria-labelledby|aria-disabled|aria-grabbed|aria-controls|aria-describedby|aria-required|tabindex|class|style|data-tabs|data-tabs-content|data-equalizer|data-equalizer-watch|data-equalize-on|data-count|data-ratio|frameborder|allowFullScreen|allowfullscreen]';
$initArray['extended_valid_elements'] = 'iframe[title|class|type|width|height|src|frameborder|allowFullScreen|allowfullscreen|data-ratio]';
$initArray['valid_children'] = '+p[iframe],+div[iframe]';
$initArray['invalid_elements'] = '';
I added iframe as valid children, and specifically told TinyMCE that there are no invalid elements.
...And the client is still having the same problem and I need some insight on why this is happening and how to fix this.
Anyone had the similar experience or might have an answer to this issue?
Edit: Currently looking for a plugin-less solution. There is nothing wrong with using a plugin, I suppose, but if it's doable by writing extra bit of code to solve this, then I'd rather not use it.
Edit 2: It seems that iframe being removed is more pressing issue at the moment. Attributes seem to be intact from my client's grasp, for now.
Update: Figured out the issue. It had nothing to do with TinyMCE. One thing I neglected to account for was that the website is a multisite, and that admin account don't actually have 'unfiltered_html' capability. It was something I did not know, and now I know.
WordPress cleans all the content edited in TinyMCE using KSES functions. So, even if you whitelist some tags in TinyMCE settings, on save, WordPress will filter the content using own KSES functions and will remove tags that are not allowed. By default, only administrators can use IFRAME in the content, for other users, it will be stripped on save. Here is the article on manipulating tags that KSES will allow to be used in content: KSES Tricks. Using similar method, you can add IFRAME to allowed tags list for all users.
I have a Wordpress site that uses a JQuery plugin called Hover-Caption ( https://github.com/coryschires/hover-caption ).
The main page of site: (http://brighidfitzsimons.com) looks good.
However in Internet Explorer 9, a similar page based on Category adds a 282px top offset to the post thumbnail image. (http://brighidfitzsimons.com/category/lifestyle/)
I am new web developer so I am struggling to figure out how to isolate problem. Based on this stackoverflow entry ( How do I get rid of an element's offset using CSS? ) my current train of thought is to add a IE specific CSS sheet to 'reverse' the offset but I can't seem to get at the offending element. Also I'm confused why works on main page but not on category page. If you watch page loading carefully, it initially loads correctly then at the very end the images are moved down. Perhaps this is a clue.
First stackoverflow entry so I hope I have followed correct ettiquete. Please advise if you need me to provide any more information.
Thanks for taking time to read problem.
Regards Simon
It has something to do with the substitutions of the content inside the title, probably some quirk about ie9 which someone else would have more of an idea for me
just so you can take my word for it: http://jsfiddle.net/BXjK3/
the first two i have removed all the greater, lesser and quotes and it works, but I would say the browser does the substitutions before Javascript can see it, and it all goes down-hill
edit: worth mentioning the reason it looks like that is because the text is no longer properly contained, and so the display none is not taking effect on it, pushing all the images down and making it a jumble, due to the way the content is loaded the ie inspection cannot show me how the text is after the javascript, only what was loaded on page load, so i can't give you more help than that
I'm having a peculiar problem with comments in Drupal. If I enable writing comments in a node, and I put a hash tag in the url (for example, node/123#footer), it will load for a split second at the correct div and jump right back to the top. This doesn't happen on any other page of the site where there are no comments. It also doesn't happen if I disable comments or set comments to read-only for the node. It's not Javascript and it's not my theme because the same thing happens if I disable JS in my browser (tested with Chrome, Firefox, IE, and Opera) and use Garland. I've also changed the node's comment settings to every combination I could think of.
I want to use this because I have a lot of links that jump directly to a comment (each comment has id="comment-cid") but it's pretty useless right now!
Any idea where to look? Appreciate it!
Did you check thr source to see if there are any actual anchors available ?
If you have commentes over multiple pages(I mean 30 comments per page), then node/123#comment-3232 won't work if the comment-3232 is in ?page=1 or 2,3,etc.
Is it possible to link youtube videos in HTML code without showing it's captions (subtitles)?
Let's say I have following video: http://www.youtube.com/watch?v=kTvHIDKLFqc . It has default english subtitles. However, when linking this video, I want to load it without them. Is there a possibility to do so with some kind of parameter in video?
I found this link with description how to do it, but it doesn't seem to work. If I try to use following format of link, it shows captions anyway: http://www.youtube.com/watch?v=kTvHIDKLFqc&cc_load_policy=0. Is it not working or did I misunderstand anything?
I found the documentation to be a little misleading in that setting &cc_load_policy=1 does not show the closed captions by default, but enables toggling with the cc button in the video control bar when entered as shown here -
http://www.google.com/support/youtube/bin/answer.py?hl=en&answer=140174
It seems cc_load_policy is a parameter that only accepts 1 as value, so even if you try to use 0 or off values to turn off captions, it won't make a difference (at least until today: 2015-05-18 2017-09-11):
https://developers.google.com/youtube/player_parameters#cc_load_policy
2017-09-11 Solution: "Enable privacy-enhanced mode"
When you share a video in Youtube through the embedding option, you can click the "Enable privacy-enhanced mode" checkbox. This will change the URL to a different Youtube domain: https://www.youtube-nocookie.com
Just by doing this, even if the user has captions On by default, the nocookie option will not read the cookie associated to the user preferences (it's as if the user does not require captions by default).
I have created this codepen example in order to explain this:
Try playing the "No parameters" video and then the cc_load_policy=1 video (it may not display captions due to user preferences, even if in the latter the CC button is activated - red underline);
Then play the "nocookie domain" video and there should be no captions.
Try activating captions in the "no parameters" video and refresh the page.
All videos except the "nocookie domain" video will display captions.
Disclaimer: I have only seen this working in Chrome (Firefox and Edge always display captions in the nocookie domain, even in private navigations). If you activate/deactivate captions manually in the "nocookie domain" video, then it will display/hide captions in this domain when you refresh the page respectively.
Old stuff (partial solution for owners of the video)
cc_lang_pref does not accept off or Off as a value either...
I managed to turn off captions/subtitles for the default language of the video this way only for Safari and IE (I have captions in the default language and English - in my case, Chrome and Firefox seemed to have ignored the change, but I suggest to give it a shot anyway):
In youtube if you go to your video's Info and Settings page and click Advanced Settings tab, set the Video Language to Not applicable.
Save and go to Subtitles and CC page, where a pop-up appears explaining that «You must select a video language before adding subtitles or CC.» (this seems not to be true, because they even appear anyway).
Choose your video's default language in the pop-up: this is what makes it understand that you don't need captions of your default language when the video is in the same default language the weird thing is, this is the step that will make them not to show up, and it's not because the same language is used in the captions.
In the URL's video that you do not want to have captions do not use cc_load_policy parameter, but you can use cc_lang_pref to the default language like this:
http://www.youtube.com/watch?v=kTvHIDKLFqc&cc_lang_pref=en.
Again, this seems to work only in some browsers (Firefox and Chrome not included), but hope it helps...
The site says how to turn on caption. It does not talk about turning off captions. I thinkit depends on the user's previous choice.
When you embed a video on another
site, you can make it so that captions
are always shown on the embedded
video. To enable captions on a video
you'd like to embed, just add
&cc_load_policy=1 to the video's embed
code.
It's very simple, add iv_load_policy=3 parameter to your embed code.
Peace to whom will follow the guidance,
(Thanks for your tries but I found something nice not far away from there...)
Ask for a language preference that is not from the translated captions (for my exemple "He" stands Hebrew, that was not among the offered translations of the video.)
Add ?hl=He to the url, like this :
without it :
https://www.youtube.com/watch?v=pRztmbnyV70
and with it :
https://www.youtube.com/watch?v=pRztmbnyV70?hl=He
Makes it... ?
It worked for me on Firefox, Edge and Opera.
-- Enjoy !
Note : the particle desapears after the loading of the page ...But the job is done !
I have a link that renders an rss feed, is there a way to have firefox display the source of this link as opposed to popping up the Add Live Bookmark dialog?
For every URL you can open the view-source version by prepending two magic words:
view-source:http://lebkowski.name/show/blog.atom
Works with any URL/Content-type. Gecko based only.
You could lie about the Content-Type and claim that it is text/plain.
I might be slightly more inclined to create an HTML version of the source (with syntax highlighting) — but that would depend on the reasons behind you wanting non–standard behaviour.
It might be worth pointing out that Firefox 3 (at least) doesn't display a dialog, it displays an XSLTed–to–HTML version of the feed which includes a number of options (at the top) for subscribing to it. View → Source works as you would expect, so end users can easily access the source if they should so wish.