I'm migrating my website to another hosting, but I have problem with the font.
When you open site for the first time font is not working, it's just showing blank squares, after you go into any subpage it starts to works. Do you have any idea what might be causing it?
its depends on where you added font awesome in opencart.
Mostly it should be in
catalog/view/theme/default/template/common/header.tpl
And if you added with some custom condition then check it.
because in opencart only Except then home page, other inner pages open with Query parameter.
ex. index.php?route=common/home
So, for inner pages check source code and look at the CSS path is proper or not.
Just to add (I cannot comment), if you're not using the default theme, you'd want to navigate to catalog/view/theme/(your theme name)/template/common/header.tpl
If you're using the Journal theme, you'll want to check the template/journal2/headers folder.
Try these and tell us if any of them makes a difference:
Edit your config.php and check that the HTTP_SERVER and HTTPS_SERVER variables are correct.
Make sure that the link to Font Awesome is correct, this also means making sure that if your site mainly uses www.domain.com and not domain.com that your link to Font Awesome has www. in as well. Same goes for http:// vs https:// and vice versa.
Check the casing of the font filename. Font-Awesome.min.css is not the same as font-awesome.min.css and your new server may care about that.
Koda
Related
How we can create content section in xcart like we create in wordpress via widget ? is there any option like this ? i want to make home page with 4 section with image content and link them to particular page .
This differs depending on X-Cart version. There are two major versions now: X-Cart 4 and X-Cart 5. They are very different and in order to give you any advice it is better to now what X-Cart version you are using.
Alex Mulin is right, it's kinda difficult to answer your question without such specific info as your X-Cart version. Yet I'll try to. In both cases the webmaster mode can help you do the trick. See video tutorials below.
Webmaster mode in X-Cart 4 :
https://www.youtube.com/watch?v=9QrpH4cQGpE
Webmaster mode in X-Cart 5:
http://devs.x-cart.com/en/webinars_and_video_tutorials/using_webmaster_mode_in_x-cart_5.html
If they don't work for you for some reason, try to ask the same question but be a bit more specific, or at least provide the store URL and I will be able to check the version.
What you are trying to do is skin-dependent and each skin has its own sections.
In order to find the files that you need to edit, go to Admin Panel>Settings>General Settings>Enable debugging console and check its box.
When checked, if you open your store, it opens a popup that that shows you the smarty templates loaded (make sure your browser does not block popups).
You can then change the smarty template files in order to add whatever you want. If you are not familiar with them, they are basically extended HTML files with some basic commands (if/for/etc.) and you can get stuff from PHP files in them as well. You can use xcart webmaster mode to edit those files too as mentioned by other answers.
This video can also be useful for you: https://www.youtube.com/watch?v=vN__DZrNrRM (X-Cart - Storefront Design and Layout)
And here's some XCart documentation on how to customize store front and skins:
http://help.x-cart.com/index.php?title=X-Cart:Customizing_storefront
http://help.x-cart.com/index.php?title=X-Cart:Editing_Skin_Files
this is my local site: drupaltest1/
When I/anyother developer inspect my site they can recognize which theme I am using. I want to hide the theme being displayed on inspect elements an display the site name in the path. I searched google, but no luck. Anyone please help in achieving this.
Thanks in advance
You could change the name of the theme to your sitename.
in sites/all/themes/ copy your theme folder and rename the folder
then replace the theme name in .info file and use find/replace in template.php and any other theme specific files as well. (notepad++ search in files works well)
upload and enable the new theme in Drupal
If you are not using a custom theme for your site, be sure to check the licensing/copyright to ensure renaming it isn't a violation - and updates may have issues so you could remove the project info and/or packing script info.
If you can create a sub-theme, then you would be able to hide those info(s) from being inspected your site pages.
Please reply if this helped you.
https://www.drupal.org/node/1010576
https://www.drupal.org/node/225125
I am working on a phpbb design. I have a local install with a duplicated database of the original site. I have no access to the administration panel since I am not an admin on the original site.
Changes made to the CSS would not show on the page, so I edited the file /style.php and forced recompiling CSS by setting $recompile to true. That solved the issue.
However, I am now trying to make changes to the HTML, because the phpbb semantics is one of the worst I have ever seen, and most elements don't have classnames.
When making changes to template files (let's say to the "prosilver" default theme), those changes won't show on the page. For example if I add classnames to certain elements, those classnames will not appear on the page.
I know that the problem comes from phpbb caching templates, and I tried forcing recaching by setting $recache to true in /style.php, but that didn't work.
Thanks for any help !
Kind regards.
If you have access to the server via ftp or your hosts control panel, go into the /cache directory and delete everything EXCEPT .htaccess and index.htm. This will have the same effect as clearing the cache via the ACP and will force the templates to recompile.
I searched...can't find any good references. I have what I think is a pretty simple question: What are the basic concepts behind a system that allows customers to specify and generate a website, from a choice of style templates?
Say for example I created a simple website consisting of four static HTML pages. I can make those pages look like anything I want by using different CSS templates...good.
But if I wanted to give my clients an interface that says "hit this button and your site will be generated" -- I don't know what the basics are underneath that idea to make it happen. Is it simply a matter of creating the directories and copying files?
Before I go down a dumb path I just need some general guidance about how this type of thing is usually done. There are notable services out there that offer people the ability to sign up for an account, and in "three easy steps" generate a simple website. I want to learn the theory and basics behind how that is done.
Thanks...
EDIT:
I know how to change an existing set of static HTML pages using CSS. What I want to do is build a true website generator. You log into my system, pick a theme, hit a button and your site (e.g. www.foo.com or foo.parentsite.com) is ready to use. I can figure out how to allow customers to change content -- by integrating tinyMCE for example. I just need the basic concepts behind the "hit a button...generate a new site" idea.
You can change with javascript the css used. This will change the looks of the current page.
But you need to make multiple css with an unique look.
I suggest you to make a generic css and add the theme of your site into a small css.
The small one should contain only what is unique with this theme.
generic.css => Place content,menu, footer, etc...
theme1.css => Change background color to red, change text color to blue, etc
theme2.css => Change background color to blue, change text color to blue, etc
theme3.css => Change background color to blue, change text color to red, etc
JQuery Ui allow to change his interface easily.
Check this and change selected gallery on left
I don't think you can generate an website than customer will be very satisfy.
There's always something than client want to change.
EDIT:
You need to create folder on the server.
Put all necessary file with his selected themes into the folder
Configure apache for his domain. Then reload it for the new config.
I suggest you to use PHP or cgi.
The thing I don't know how is to register the domain if available and how to redirect his domain to your ip easily and automated.
Found something else tonight: There is a full set of APIs that can be used to gain access to cPanel functionality. So, almost literally, using their PHP wrapper it looks like only a few lines of code to instantiate a subdomain, set up email accounts, domain pointers, etc.
Looks promising...but being a total noob I have a lot of reading to do...
I'm a beginner on Opencart and just started developing a module for Opencart which it must inject some lines of javascript and html code in these pages:
- Cart Page
- Product Page
- Confirmation Order Page
- Register form page
The official documentation doesn't have informations about how can i do that, I've tried to find a good documentation about OpenCart but I didn't find anything.
I need help. How can I do that?
Diggin necro topics;) :
The easiest way i think:
upload/catalog/view/theme/[themename]/template/product/product.tpl - here you can add your custom html for product page
[your theme name, you shouldnt overwrite default theme because it can cause damage after update]
It depends on where you're trying to insert the HTML/JavaScript.
Doing things the proper way in OpenCart, you're limited to the column-left, column-right, content-top, and content-bottom positions.
The files you'll need to create are:
admin/controller/module/mymodule.php
admin/language/english/module/mymodule.php
admin/view/template/module/mymodule.tpl
catalog/controller/module/mymodule.php
catalog/language/module/mymodule.php
catalog/view/theme/default/module/mymodule.php
To learn how to do this the first time, it's easiest to replicate an existing stock OpenCart module (preferably a simple one, such as information). Once you've replicated it you'll need to go through each of those files and replace any references to "information" with "mymodule".
After that, if you've done it properly, you should be able to navigate to Admin > Extensions > Modules and see your module in there. Then install it, use the "Add module" button to position the module on all the relevant layouts, hit save and hey presto you have a working module on the front-end.
To modify the front-end output, just edit catalog/view/theme/default/module/mymodule.php
If you want to insert your HTML somewhere other than the 4 available positions OpenCart gives you, position your module in the content-bottom position and use JavaScript/jQuery to inject some HTML where you want.
If this is for your own personal website then as Pawel S suggested it would be easiest to simply modify the relevant view files (ie. catalog/view/theme/[themename]/template/product/product.tpl), however if you're making a module which you plan to distribute then this should be a last resort.
Hope that helps!
I realize this is probably long dead by now, but if you're creating a module that needs to modify existing controllers, languages, models or views the correct tool to use is vQMod.
vQMod allows you to modify existing code on the fly using XML.
https://code.google.com/p/vqmod/