Forums › Forums › OroCRM › OroCRM – HTML, JavaScript, CSS, Design Questions › JS CSS files not loading
This topic contains 23 replies, has 12 voices, and was last updated by Hryhorii Hrebiniuk 7 years, 4 months ago.
Starting from March 1, 2020 the forum has been switched to the read-only mode. Please head to StackOverflow for support.
- CreatorTopic
- June 18, 2013 at 4:53 am #25583
I have installed OroCRM and OroPlatform, but I can’t see the JS and CSS files being loaded when I open it in browser. I have checked there is only one JS file in web/js (routes.js) and no CSS folder in there.
Any suggestions?
- CreatorTopic
- AuthorReplies
- June 18, 2013 at 6:19 am #25584
Did you experienced some errors while running install.sh?
Try to do these commands:12app/console assets:installapp/console assetic:dumpJune 18, 2013 at 7:11 am #25585Great! It did resolved the issue.
BTW, I encountered error in between the process “PHP Fatal error: Class ‘Assetic\Util\PathUtils’ not found in ..” which I resolved following this post.
September 26, 2013 at 9:54 am #25586I’m hitting an issue with js/routes.js – it’s 404’ing.
Sorry this is probably a really dumb question, but I’m not too clear on how to run the `app/console` command.
I’ve tried running:
1./app/console assets:installBut I get
1env: php\r: No such file or directoryAnd here are the results for the asset dumping from the initial install, in case that helps at all.
123456789101112131415161718192021222324252627282930313233343536Installing assets using the hard copy optionInstalling assets for Symfony\Bundle\FrameworkBundle into web/bundles/frameworkInstalling assets for JMS\JobQueueBundle into web/bundles/jmsjobqueueInstalling assets for FOS\JsRoutingBundle into web/bundles/fosjsroutingInstalling assets for Nelmio\ApiDocBundle into web/bundles/nelmioapidocInstalling assets for Bazinga\ExposeTranslationBundle into web/bundles/bazingaexposetranslationInstalling assets for Genemu\Bundle\FormBundle into web/bundles/genemuformInstalling assets for A2lix\TranslationFormBundle into web/bundles/a2lixtranslationformInstalling assets for JDare\ClankBundle into web/bundles/jdareclankInstalling assets for Oro\Bundle\UIBundle into web/bundles/orouiInstalling assets for Oro\Bundle\FormBundle into web/bundles/oroformInstalling assets for Oro\Bundle\JsFormValidationBundle into web/bundles/orojsformvalidationInstalling assets for Oro\Bundle\SearchBundle into web/bundles/orosearchInstalling assets for Oro\Bundle\UserBundle into web/bundles/orouserInstalling assets for Oro\Bundle\SegmentationTreeBundle into web/bundles/orosegmentationtreeInstalling assets for Oro\Bundle\NavigationBundle into web/bundles/oronavigationInstalling assets for Oro\Bundle\ConfigBundle into web/bundles/oroconfigInstalling assets for Oro\Bundle\FilterBundle into web/bundles/orofilterInstalling assets for Oro\Bundle\GridBundle into web/bundles/orogridInstalling assets for Oro\Bundle\WindowsBundle into web/bundles/orowindowsInstalling assets for Oro\Bundle\AddressBundle into web/bundles/oroaddressInstalling assets for Oro\Bundle\TagBundle into web/bundles/orotagInstalling assets for Oro\Bundle\TranslationBundle into web/bundles/orotranslationInstalling assets for Oro\Bundle\EmailBundle into web/bundles/oroemailInstalling assets for Oro\Bundle\EntityExtendBundle into web/bundles/oroentityextendInstalling assets for Oro\Bundle\CronBundle into web/bundles/orocronInstalling assets for Oro\Bundle\SyncBundle into web/bundles/orosyncInstalling assets for OroCRM\Bundle\DashboardBundle into web/bundles/orocrmdashboardDumping all prod assets.Debug mode is off.09:31:30 [dir+] /kj/crm-application/app/../web/css09:31:30 [file+] /kj/crm-application/app/../web/css/oro.crm.css09:31:31 [file+] /kj/crm-application/app/../web/css/oro.user.cssDumping all dev assets.Debug mode is off.September 26, 2013 at 10:26 am #25587Hi
installation log looks ok, but i suggest that you had some issues during composer update, routes.js generates in post install/update hooks..
You can generate it manually by running
1php app/console fos:js-routing:dump --target=web/js/routes.js(check composer,json for reference)
If you check app/console you will see
#!/usr/bin/env php
at first line,
this line means that path to application that can execute script will asked to system toolenv
(ref)So when you run ./app/console sha-bang will be used, but if your environment configured incorrect bash will not find application to run with. You can say bash to run with php manually by executing with
/path/to/php app/console
.Path can be found by running
whereis php
.
Hope this help, cheers :)September 26, 2013 at 3:29 pm #25588Thanks, asmaga. Super helpful. Yep, I was able to generate routes.js using that command, and I’m all set now.
April 10, 2014 at 1:41 pm #25589sorry wrong place :) moved to here http://oroinc.com/orocrm/forums/topic/installation-errors
April 24, 2014 at 5:30 am #25590Hi,
So I want to change the current theme of Oro-CRM what is the best way to hook into the theme without loosing data on updates?
thanks
April 24, 2014 at 6:08 am #25591Hello, max101.
If you are talking abount visual themes, then you should look at ThemeBundle (https://github.com/orocrm/platform/blob/master/src/Oro/Bundle/ThemeBundle/README.md).
If you have some specific case – please, describe it, so we can understand what you want and answer you how to do that.
April 24, 2014 at 6:56 am #25592Hi Yevhen,
I am just wanting to do a few small overrides that’s all nothing to intense, a color here and there, what is the best quickest method?
Thanks for the quick response
April 24, 2014 at 8:36 am #25593If you want to do small fixes in CSS in some specific areas, you can create your own css file and add it to to assets (see https://github.com/laboro/platform/blob/master/src/Oro/Bundle/UIBundle/Resources/config/assets.yml).
If you want to customize general system functionality (menus, panels etc.) you should create new theme and apply it.
May 13, 2015 at 8:08 am #25594Hallo!
When i do command:
“app/console assetic:dump –env prod”
It output an error, and no css/js files is generated ;( :
/var/home/deploy/builds/test/2015-05-13-13-35-20/app/../web/bundles/orocrmcase/css/less/comment.less
/var/home/deploy/builds/test/2015-05-13-13-35-20/app/../web/bundles/oroui/themes/oro/css/style.css[Exception]
parse error: failed at `content: ‘−’;` line: 56 </Exception trace:
() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/leafo/lessphp/lessc.inc.php:3460
lessc_parser->throwError() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/leafo/lessphp/lessc.inc.php:2273
lessc_parser->parse() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/leafo/lessphp/lessc.inc.php:1795
lessc->compile() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/leafo/lessphp/lessc.inc.php:1934
lessc->parse() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/kriswallsmith/assetic/src/Assetic/Filter/LessphpFilter.php:104
Assetic\Filter\LessphpFilter->filterLoad() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/kriswallsmith/assetic/src/Assetic/Filter/FilterCollection.php:62
Assetic\Filter\FilterCollection->filterLoad() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/kriswallsmith/assetic/src/Assetic/Asset/BaseAsset.php:90
Assetic\Asset\BaseAsset->doLoad() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/kriswallsmith/assetic/src/Assetic/Asset/FileAsset.php:65
Assetic\Asset\FileAsset->load() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/kriswallsmith/assetic/src/Assetic/Asset/BaseAsset.php:99
Assetic\Asset\BaseAsset->dump() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/kriswallsmith/assetic/src/Assetic/Asset/AssetCollection.php:151
Assetic\Asset\AssetCollection->dump() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/symfony/assetic-bundle/Symfony/Bundle/AsseticBundle/Command/DumpCommand.php:222
Symfony\Bundle\AsseticBundle\Command\DumpCommand->doDump() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/symfony/assetic-bundle/Symfony/Bundle/AsseticBundle/Command/DumpCommand.php:162
Symfony\Bundle\AsseticBundle\Command\DumpCommand->dumpAsset() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/symfony/assetic-bundle/Symfony/Bundle/AsseticBundle/Command/DumpCommand.php:61
Symfony\Bundle\AsseticBundle\Command\DumpCommand->execute() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/symfony/symfony/src/Symfony/Component/Console/Command/Command.php:249
Symfony\Component\Console\Command\Command->run() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/symfony/symfony/src/Symfony/Component/Console/Application.php:900
Symfony\Component\Console\Application->doRunCommand() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/symfony/symfony/src/Symfony/Component/Console/Application.php:191
Symfony\Component\Console\Application->doRun() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/symfony/symfony/src/Symfony/Bundle/FrameworkBundle/Console/Application.php:96
Symfony\Bundle\FrameworkBundle\Console\Application->doRun() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/jms/job-queue-bundle/JMS/JobQueueBundle/Console/Application.php:44
JMS\JobQueueBundle\Console\Application->doRun() at /var/home/deploy/builds/test/2015-05-13-13-35-20/vendor/symfony/symfony/src/Symfony/Component/Console/Application.php:121
Symfony\Component\Console\Application->run() at /var/home/deploy/builds/test/2015-05-13-13-35-20/app/console:23May 14, 2015 at 2:56 am #25595Hi babr79,
Looks like leafo/lessphp cannot compile css from less.
What version of OroCRM do you use? Does it contain any style customisation? Is it default theme?
Can not fine what might cause the error:
123parse error: failed at `content: ‘−’;` line: 56Mentioned file does not contain that code:
https://github.com/orocrm/crm/blob/1.7/src/OroCRM/Bundle/CaseBundle/Resources/public/css/less/comment.lessMay 14, 2015 at 3:08 am #25596Hi, Hryhorii Hrebiniuk
>What version of OroCRM do you use?
1.6.1 ( https://github.com/orocrm/crm-application/tree/1.6.1 )>Does it contain any style customisation?
No. Its my first, clean, default installation of OROCRM.>Is it default theme?
Yes>Mentioned file does not contain that code: …
I dont know. I only do steps, defined in manual : https://github.com/orocrm/crm-application/blob/1.6.1/README.md
I try to clean cache, by
app/console cache:clear -vvv –env=prodAnd then, tryed again do assets:install and assetic:dump, but always catch error:
“parse error: failed at `content: ‘−’;` line: 56”May 14, 2015 at 3:12 am #25597Hi again, Hryhorii Hrebiniuk
I’m look at
/web/bundles/orocrmcase/css/less/comment.less , that was generated by “assets:install” command, an saw this content:123456789.notes.comments {.list-item.private {background: #fff6d9;&:hover {background:#fff1c5;}}}And of course, it differ from https://github.com/orocrm/crm/blob/1.7/src/OroCRM/Bundle/CaseBundle/Resources/public/css/less/comment.less
But i dont understand why assets:install generate wrong less file?
May 15, 2015 at 7:13 am #25598Hi babr79,
Could you do following:
Shell123456rm -rf app/cache/pr*rm -rf app/cache/de*rm -rf web/bundlescomposer installapp/console assets:installapp/console assetic:dumpAnd if get the error again, please send output message
- AuthorReplies
The forum ‘OroCRM – HTML, JavaScript, CSS, Design Questions’ is closed to new topics and replies.