Use my_changes on core js file in cs-cart? - cs-cart

I want to make changes to the wysiwyg editor in CS-Cart, and I can do this by editing the file:
/js/tygh/editors/tinymce.editor.js
But this is a core file that should only be edited through the my_changes addon.
So the question is, how do I use my_changes to edit this file?
The my_changes addon is active and is used elsewhere successfully.
I have tried putting my edited js file in this folder:
/js/addons/my_changes/tygh/editors
But this does nothing.
In the file there appears to be a js hook:
$.ceEditor('handlers', editor);
How and where do I override the editor var?

Use JS Hooks:
$.ceEvent('trigger', 'ce.picker_add_js_item', [hook_data]);
https://docs.cs-cart.com/latest/developer_guide/core/coding_standards/hooks.html#js-hooks
If there is no hooks, then ask the CS-Cart developers to create it.

Related

How do I customize go-present template?

I am new to Go and just stumbled upon Go's present package which I imported via go get golang.org/x/tools/present.
Is there any way to customize the look of the presentation? E.g. via adjusting the default css file?
If so where are the files used for the style? I cannot find the package anywhere in my Go path...
Let's assume you have a directory myslides with some .slide files in it.
Create a subfolder theme in myslides.
Copy the folders template and static from $GOPATH/src/golang.org/x/tools/cmd/present to that new theme directory
Start present with a new parameter -base: present -base theme
Modify the styles and template files. Most small things are in styles.css.
If you change the template files, then you need to stop and restart present. If your are changing the styles only, then a reload in the browser will do (take care to disable the cache.)
I found that the only way to change presentation styles is to modify library files directly.
If you use vgo:
$GOPATH/pkg/mod/golang.org/x/tools#<version>/cmd/present
Otherwise:
$GOPATH/src/golang.org/x/tools/cmd/present
Of cause first you need to download present package: go get golang.org/x/tools/cmd/present

How to specify output directory of CSS file in scssphp

I'm using Redux Framework and SASS. I've checked the http://leafo.net/scssphp/docs/ documentation, but I can't seem to find any mention of output css file directory mentions. And also how do I pass the Redux variables(taken from options field) to scss(_variables.scss) file and update the output css when I update of Redux Framework options from admin options menu. Thanks in advance.

Aurelia: Using KendoUI Core

I downloaded kendoui core from Telerik's website. Folder has a js directory with separate files for each widget. I want to integrate kendoui with systemJS in my Aurelia app(built on top of skeleton-navigation). I was able to do this with JQueryUI as follows:
--Created a "jquery-ui#1.11.4" folder containing the jqueryUI JavaScript lib in github folder in jspm_packages folder
--Created a file called "jquery-ui#1.11.4.js" that exports the lib above like so:
module.exports = require("github:github/jquery-ui#1.11.4/jquery-ui.js")
--Defined jqueryui in my config file: "jquery-ui": "github:github/jquery-ui#1.11.4"
Now, if I want to use any widget, like the datepicker, i do this:
import { datepicker } from 'jquery-ui';
How do I do this for kendoUI? I read somewhere that the "kendo.core.js" file contains all widgets but it seems too lightweight and using it alone didnt work. It also has a complementary .map file. What is it for?
UPDATE: As suggested in the answer below, I decided to include kendoUI and jQuery with the script tag in my index page. Also instead of importing the whole kendoUI library (kendo.ui.core.min.js->670KB) I just included the files needed for kendoUI's date picker that I needed (kendo.core, kendo.popup, kendo.calendar and kendo.datepicker->99.1KB). Incase anyone wants to use this approach, Remember that jQuery will have to be imported in index.html too and before any kendo files. Also, kendo.core should be imported before the others and datepicker after everything else(I.e. last)
The solution you are using for adding jQuery UI is not one that will scale. You should never write anything to the jspm_packages folder, as that folder is jspm's to use as it wishes. Also, you can simply install jQueryUI using JSPM (jspm install jquery-ui).
Your first option is to install KendoUI Core using jspm with jspm install kendo-ui.
If you'd prefer to go it alone, you should probably just load the kendo files using a <script> element. There's nothing wrong with doing this. These files are made to be used as global variables loaded using script tags, so don't fight it.
Again, there's nothing wrong with using script elements to load legacy (read non-modular) js files.

Wordpress, Genesis theme, streamline pro, How to add an extra .PHP file?

I would like to create a new formhandler.php file where I can collect the info from a form on a page in the streamline pro theme on the genesis framework. I am looking at appearance-> editor -> streamline pro theme. I see a list of php files:
Templates
front-page.php
Theme functions (function.php)
theme-defaults.php (lib/theme-defaults.php)
Landing page templates (page_landing.php)
Now my question is: How do I add another .php file under this? (or anywhere else) to gather the form info using the PHP POST Method. Other suggestions are welcome. Should I do this by building a custom plugin?
You put files in your Child theme, how to add new template, take a look here https://developer.wordpress.org/themes/template-files-section/page-template-files/page-templates/#Custom_Page_Template, and here also
http://www.carriedils.com/custom-page-template-genesis/

How can i make customized template for the front end by overriding the default one?

I am new to Pyrocms and reading the documentation I could not change fix my problem. I need my own template to be incorporated that is I want to change the default one provided. How can I do that. I really need a help.
Go into:
system/cms/themes/default/
This is the folder where you can find the default template of pyrocms. There you will see folders like "views, css, js, img" etc.
You can start by modifying views/layouts/default.html and views/partials/ folder.
Ofcourse if you need to change css and/or js you need to modify them too.
By the way this is the official pyrocms documentation for editing themes:
http://www.pyrocms.com/docs/manuals/designers

Resources