I am using the latest SyntaxHighlighter within my app and for some reason the toolbars do not show in IE, Firefox or Chrome. The code highlights without issue, but I want to have toolbars. What makes things worse is that the toolbar demo on the official website is not working either.
Am I missing something obvious? Below are the code nuggets.
<script src="Scripts/syntaxhighlighter/scripts/shBrushCSharp.js" type="text/javascript"></script>
<link type="text/css" rel="stylesheet" href="Scripts/syntaxhighlighter/styles/shCoreDefault.css" />
<script type="text/javascript">
// Highlight code
SyntaxHighlighter.all();
</script>
<pre class="brush: csharp; ruler: true; title: 'Test'; toolbar: true;">
public static bool HelloWorld()
{
// Return
return false;
}
</pre>
I've been trying to figure this one out myself. I won't claim to be 100% correct here, but from what I can tell, this is the answer:
Toolbar was changed in update from version 2 to version 3.
Toolbar no longer includes the icons and whatnot.
The default toolbar is now the simple '?'.
This pretty much sucks, if it's true. The pop-up toolbar w/ icons is one of the things that made me choose SH over the other options.
This is what I'm guessing comparing the included CSS files in the latest package to the CSS available on sites that have a version with the "proper" toolbar enabled.
Here's a link to one I was snooping in: ramymostafa.com
While I would like the toolbar myself, it seems that one of the toolbars features - copy & paste - have been included without the need for a toolbar item:
If you double click anywhere on the code, the entire code view is replaces with a pre-selected view from which users can copy with a simple Ctrl/Cmd-C. Clicking anywhere else returns the view to the original state.
http://alexgorbatchev.com/SyntaxHighlighter/whatsnew.html#copytoclipboard
I would still like the pop out feature, but less buttons is a good thing, I guess?
the same problem here. looks like there is no toolbar in v3.
i use v2 again: http://alexgorbatchev.com/SyntaxHighlighter/download/download.php?sh_2.1.382
if you copy the css and js around, don't forget to include the images in folder styles
The toolbar can be easily be showing simply go to the plugin configuration, on the Highlighter Version set to VERSION 2X. This way the toolbar will be shown again!
I confirm that in Version 3 the toolbar does not show.
Related
Hi I'm using TYPO3 CMS 6.2.14 with FluidTYPO3 (flux 7.2.2, fluidcontent 4.3.2and vhs 2.3.3). Since the last few TYPO3 installations my Icons for Fluidcontent-Elements are missing in Backend?! I've didn't change the path or sth. else.
Here are my tries, nothing works:
<flux:form id="fce6" icon="../typo3conf/ext/mytemplates/Resources/Public/Icons/Content/Icon.gif" wizardTab="FCE" options="{Fluidcontent: {sorting: 106}}">
...
<flux:form id="fce6" options="{Fluidcontent: {sorting: 105}, group: 'FCE', icon: '{f:uri.resource(path: \'Icons/Content/Icon.gif\')}'}">
...
<flux:form id="fce6" options="{icon: '{f:uri.resource(path: \'Icons/Content/Icon.gif\')}'}">
...
<flux:form wizardTab="Bootstrap" id="tabs" icon="{v:extension.path.resources(path: 'Icons/icon-tabs.gif')}">
If I inspect the missing Icons in Backend with a developer tool (browser), the Icon is found, so I don't understand it.
../typo3conf/ext/mytemplates/Resources/Public/Icons/content/Icon.gif
Some sceenshots
-
The funny thing is, that the Icon is still there, if you're inside the Fluidcontent Element (FCE), see last screenshot (red bar icon):
EDIT :: I was looking in one of my older TYPO3-Projects and the Icons are still there: flux 7.2.1, fluidcontent 4.2.4 and TYPO3 6.2.15
Code:
<flux:form id="tabsvertical" options="{Fluidcontent: {sorting: 305}, group: 'FCE', icon: '{f:uri.resource(path: \'Icons/Content/Example.gif\')}'}">
See screenshot:
Flux supports convention based icons since v.7.2.0.
It means, that for each your template you can have corresponding icon in Icons folder, which will be shown automatically.
Example:
Template file typo3conf\ext\my_ext\Resources\Private\Templates\Content\Grid-1.html should have an icon typo3conf\ext\my_ext\Resources\Public\Icons\Content\Grid-1.png.
See more in changelog.
I spent some hours with TYPO3 6.2.15 and 7.5 to get icons running. The convention based icons did the job for 6.2.15. Rather than using a f:uri.resource(), which will not work. The flux form configuration is somehow rendered in a special container. E.g. for the "new content elements page". Try to put a var_dump() into the view helper. Best combined with an exit(). The container does not seem to be aware of the extension. That is for 6.2.15 and the current versions of fluid/flux. For 7.5 the 7.2.3 does not produce any reasonable results. I only get /typo3/ as icon path. But the 7.2.4 is expected to fix it.
I use this Options Fields for Backend Icons and Grouping.
<flux:form.option.group value="Content" />
<flux:form.option.icon value="EXT:ext_name/Resources/Public/Icons/Content/HeroImage.svg" />
I also added the <flux:form.option name="settings.options"> as wrapper around the group and icon Definitions
I'm not using FluidContent but Flux Version 8.2 and TYPO3 8.7.15
I am developing an application which runs within Microsoft Dynamics CRM (MSCRM). Essentially in this environment web resources including HTML, JavaScript, CSS and image files are stored within the system the can be referenced on pages. I've got SlickGrid running but have an issue where the pager buttons each occupy a whole line. The key part of the HTML is:
<div id="SPLocation" style="width:100%; height:80%">Grid</div>
<DIV id="SPPager" style="width:100%;height:20px;">Pager</DIV
but it looks like this:
!http://www.clew-consulting.com/Temp/SGIssue.png
(hope this image works). Note each icon occupies a whole row. I've checked all the styles and images and they seem fine. The icons are functional.
The cause is probably that display:inline-block is not being picked up but it is there in the style sheets. It could be something special to do with the environment within MSCRM but the other markups all look fine.
Unfortunately I cannot run IE developer and show this part of the screen where I could inspect the CSS.
Anyone any ideas? I know I have not posted all information.
Paul
The pager styles are defined in slick.pager.css file.
Place this file in your css folder and add the following line to your html file
(do not forget to replace [path to your file] with your real path):
<link href="[path to your file]/slick.pager.css" rel="stylesheet">
I am trying to create a Hello World JS Metro app on Visual Studio 2011, using YUI3.
I´ve grabbed a local copy of YUI, added to a subfolder in the solution, and added a reference to yui-min.js on my default.html page:
<!-- TodoJS references -->
<link href="/css/default.css" rel="stylesheet">
<script src="/js/default.js"></script>
<script src="js/yui/build/yui/yui.js"></script>
and then at the bottom of the page I´ve added the following code:
<script type="text/javascript">
document.addEventListener("DOMContentLoaded", function () {
YUI().use("event", function () {
//some code will go here..
});
}, false);
</script>
When I run the code, I get a null ref error on YUI(). I do get intelissense working in Visual Studio (e.g YUI().add), so the reference seems to be OK, but YUI is not found on run time. Any tips?
I would try the steps outlined in How To: Create a Windows 8 Metro App with JS and YUI 3
I take it that you've got the issue fixed. However if you'd like to use the YUI components such as "calendar", "tabview" etc, you'll have to modify a few files that include innerHTML calls and wrap the added html content with toStaticHTML.
There were only a couple of files(dom-base.js, yui.js) that needed to be modified and most of the components worked fine(including the "datatable" and "charts" widgets), with the exception of the rich text editor. The nice thing about YUI is that it supports touch gestures for a majority of the components, for example panning "datatable" works correctly.
Ok. I have some experience with HTML and CSS, little with Javascript and none with JQuery.
And I'm trying to try out in my HTML file the Galleria plugin with fullscreen theme but I can't make it work. ( http://galleria.aino.se/ )
It only show the empty page with no pictures. I took the source code from the demo page and I pasted in my page and after some little modifications with the url of the theme, I managed to have on my screen only the image, without the "mechanism". Any help?
I think the instructions were made for an old release of the plugin and that's the reason I can't get it work.
P.S. I found a ready made demo on googlecode, but I can't get the fullscreen feature. Any help?
Try passing debug:true to yield more errors if you are seeing a blank page. Regarding customizations, try the documentation and API reference.
Is there a way to beautify JavaScript and CSS in Firebug?
I'd like to be able to view formatted JavaScript code instead of the compressed version :).
There is now a plugin that intercepts JavaScript downloads and deminifies it at that point.
Unfortunately, the way it hooks into Firefox means that it applies to all JavaScript downloads and just not specific ones and the JavaScript files have to be served with an appropriate MIME type.
https://addons.mozilla.org/en-US/firefox/addon/247565/
CSS is already beautified in Firebug, as clearly seen by comparing the CSS tab or CSS pane with the raw source.
JavaScript, alas, is not. The best you can do, for now, is to paste the code into something like http://jsbeautifier.org/ .
However, if you write a Firebug extension that does this, you will have all of our gratitude. ;-)
Firefox Developer Tools has:
"Prettify Source" button: braces {} icon on bottom left
"Auto Prettify Minified Sources" setting: turns Prettify Source on by default.
To enable it: go to the engine icon on top right of the Debugger tab, not the global settings engine.
Tested on Firefox 42.