Syntaxhighlighter the correct way to remove the help icon in the upper right corner

Source: Internet
Author: User

Post the problem picture first: about this problem. Online has a lot of posts, said three ways, after testing, found that some of the methods are problematic, and some of the methods can solve the problem, but will bring other errors. It is now explained as follows:

Online words: Syntaxhighlighter can be highlighted in almost all language forms of the source code, but also can display line number, is a favorite tool by the website developers, and it is free. The use of free products has the obligation to promote it, so when using the tool, a Help icon will be automatically displayed, click it will prompt to visit the official website and call for donations, you can remove the icon after payment. The official approach is beyond reproach, but what if we want to cancel this seemingly unsightly icon and don't want to pay for it? Here are three ways I learned: Method one in front of the page, usually in the following code:
false;</script>
Method two Add "Toolbar:false" to the pre class. (Bold section), as shown below:
<pre class= "Brush:js;toolbar:false;" > Put the coloring code here </pre>
Note: Some of the coloring code marker symbols are textarea, then the method is the same. Such as:
<textarea class= "Brush:js;toolbar:false;" > Put the coloring code here </textarea>
There are many ways to use the three syntaxhighlighter, and in some cases it is found that both methods are invalid, so you can use the method of modifying CSS directly to remove the question mark icon in the upper-right corner: First find shcore.css This file (usually under the Style folder), open it, find ". Syntaxhighlighter. Toolbar {" (Bold section), and then add "Display:none;" At the end of this class. (Bold section), it's ready. Examples are as follows:
 .syntaxhighlighter. toolbar  {position :  absolute!important ; right :  1px!important ; top :  1px!important ; width :  11px!important ; height :  11px!important ; font-size :  10px!important ; z-index : !important ; //The original here ends display :  none ; /want to turn it off? Add this line to } 

I started with the first method, inserting the code into footer.php or header.php, because it was all global, and then when I started to use it, I found that there was no problem, and it did solve the problem, but then I found an error when I turned on the Google Browser review element: Find a solution on the internet, did not. Give up decisively. The second method I look at all the trouble, there is no test. The third method looks at modifying the CSS code. I reckon it's possible to solve the problem. So start testing, how to add code? Because this is a plug-in, so certainly only in the Cpanel panel to find, so open public_html/wp-content/plugins/syntaxhighlighter/This directory, found that there are two versions: how to know that they are using that version? First go to the WordPress admin panel, find the plugin settings interface to view their version: I am using 3, so open 3 that folder, to the corresponding directory public_html/wp-content/plugins/syntaxhighlighter/ Syntaxhighlighter3/styles, find Shcore.css, open the editor, add Display:none, as follows: Save it. The download opens the interface to find out that the help picture is removed. And there's nothing wrong with the Google browser censorship element.

Syntaxhighlighter the correct way to remove the help icon in the upper right corner

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.