I have multilingual CMS Joomla website but when I switch between languages logo anyway is pointing always to default language
I am using Gavik Pro Template
My live website click on logo and it will switch to russian language but it must load Romanian default page
Any ideas?
If it doesn't come default with your template settings, you will have to override the index.php.
Try something like the following:
$lang = JFactory::getLanguage();
$logo = '<img src="img/logo.png" alt="Logo" />';
I'm not sure how your template displays the logo (or in which file), but find where it does, and base it on what I have provided above. The key to it is $lang->getTag() which will output something like en-GB or fr-FR etc
Hope this helps
Related
Images embedded in Articles not being displayed in migrated Joomla website
I have migrated a Joomla 3.7.2 website from an old server to a new server using a particularly messy technique. Basically, I exported the database and then copied the important folders and it all worked remarkably well barring one very specific feature. Articles with images in them no longer display the images in the new site.
I have System - SEF enabled in both sites (and switching it off makes no difference)
I use JCE and in code view the typical line displaying the image looks like this:
<p><img src="images/players/shirt.jpg" alt="" /></p>
In both sites.
JCE is configured to use Relative URLs in both sites. If I turn that OFF then I get the image displayed in the new site. Of course that's just a hack around the problem not a solution to it.
Path to Files Folder, and Path to Images Folder is set to images in both sites.
HTML inspector on the old site shows the
<img src="/images/players/shirt.jpg" alt="Shirt">
And on the new site
<img src="images/players/shirt.jpg" alt="Shirt">
And if you hover over the url it says "could not load the image". The missing first '/' is clearly the problem but what is it that puts it there after the article is saved by the editor and before the html is displayed in the browser?
Slightly embarrassed to pretend this is an answer but today I got the prompt to update Joomla to 3.7.3 and of course immediately afterwards the problem has gone away.
my wife have a joomla 2.5 site
She claims that she has done nothing except, installing and and subsequently uninstalling Koowa plugi, Ninja plugin and Ninjaboard component.
Anyway after that the joomla 'path' have changed such that between the domain name and the path rendered by HTML, the joomla server now seems to insert "/index.php" or "/index.php/menu-item-name"
for example clicking a link like the following:
<a href="images/some_folder/xxx.JPG">
points to something like: http://www.domain.contry/index.php/fun/images/some_folder/xxx.JPG
how to we change the 'global path settings' such that
<a href="images/some_folder/xxx.JPG">
points to
http://www.domain.contry/images/some_folder/xxx.JPG
NB: my joomla and php skills are very basic :)
Update:
I think the problem something like this:
all the image paths used to be 'absolute' and are now relative, so if I am in 'index.php/some-menu' and click 'images/xxx.jpg' then it resolves to 'index.php/some-menu/images/xxx.jpg', she has all her images in the image folder, is there some way make all image paths 'absolute' instead of relative in joomla?
because changing 'images/xxx.jpg' to '/images/xxx.jpg' with firebug fixes the problem...
if it is not possible in joomla... how bad do you think it is to:
download the sql database
and run a regex akin to
s/<.+?=\"(images)\/[\w\s]+?\.[\w\d]+)\".*?>/\/$1/g
Look in your global configuration under the Site tab for your SEO settings. Make sure you have URL rewriting enabled, and follow the directions in the tooltip to rename htaccess.txt (Linux servers) or web.config.txt (Windows servers) if necessary.
If you get a server error on the site at this point, try uncommenting RewriteBase / in .htaccess.
I am trying to add some code to a Joomla site just before the tag. I have never used Joomla before but from what I read up it should be something like this -
Log on to: http://www.yoursite.com/administrator/
In the top menu select: "Extensions" > "Template Manager"
Now select the template which is marked as default and click "Edit"
In the template edit page click "Edit HTML"
Or index.php file from your template folder however when I do both of these options the only thing there is:
<?php
if (class_exists('T3Template')) {
$tmpl = T3Template::getInstance($this);
$tmpl->render();
return;
} else {
//Need to install or enable JAT3 Plugin
echo JText::_('Missing jat3 framework plugin');
}
Any ideas where I can find the normal HTML markup with the tag?
Thanks for the help.
The markup for your template would normally be in /templates/template_name/index.php but your joomlart template uses a framework (which is not standard joomla, but common practice amongst large template providers). You should look into joomlart documentation, so you can make sure you will follow their best practices. From a quick glance at their forums, try looking at the \plugins\system\jat3\jat3\base-themes\default\page\default.php file (see here: http://www.joomlart.com/forums/showthread.php?55256-Add-code-before-lt-body-gt-amp-lt-head-gt&highlight=template+edit+jat3)
In a standard Joomla template, you would find the code inside abovementioned index.php.
You can find the template files at following location:
*Your_Base_URL/templates/mynewtemplate/*
I have a problem with magento 1.7 (WYSIWYG).
My problem is that I can't have a proper description of the product when I use the WYSIWYG.
For example if I write in the WYSIWYG my product description, on site web site I will have a presentation which isn't the same.
The WYSIWYG puts html tags for each line return.
Thank you for your help
I've found in the past that with some themes the description is run through the nl2br function first. This will replace all new lines with <br> tags. Look in your view.phtml template file for this and remove the nl2br function.
It could be that you have custom css on the front causing it to appair different, view source both the admin (WYSIWYG) and on the website to see if the html are the same. If they are the same then check your custom css
In the file description.phtml in the template/easytabs folder, I removed the nl2br.
And then it works fine.
I have a DokuWiki and I'd like to place a logo on the title bar at the top of the page? How can I do this? Note that I am not referring to the title bar at the top of the browser, but rather the title bar on the website itself.
I tried inserting the DokuWiki syntax: {{public:logo.jpg?100x100}}, but this simply rendered as plain text and not an image.
Is it possible to put an image in the page title?
Easy: Rename your logo as "logo.png" and place it into :wiki namespace. It will show automatically.
This solution works on template "dokuwiki" (default one on dokuwiki old stable version "Adora Belle" and in current one "Weatherwax"):
Deeper:
We can look at tpl_header.php file, lines 21&23:
// get logo either out of the template images folder or data/media folder
[...]
$logo = tpl_getMediaFile(array(':wiki:logo.png', 'images/logo.png'), false, $logoSize);
Ok: tpl_getMediaFile() function will look for a file logo.png in media namespace called wiki.
So I go to dokuwiki File Manager and I upload my logo.png file on wiki namespace. I refresh page and I smile.
Hope That Helps
In modern versions of DokuWiki you don't have to make your own template. Simply upload a file called logo.png to the wiki or root namespace in the DokuWiki Media Manager.
This is the line of template code that gets the logo:
https://github.com/splitbrain/dokuwiki/blob/master/lib/tpl/dokuwiki/tpl_header.php#L23
You can tell that it is first checking logo.png in the wiki namespace with :wiki:logo.png and then logo.png in the root namespace with :logo.png.
If it doesn't find either, it falls back on images/logo.png, which is the default logo.
(for latest versions of Dokuwiki)
You should create your own template, and do whatever hack you need to do.
It is located in lib/tpl/
Just copy the default directory with your own name (this will be available in the admin area later), something like "company", and edit:
<div class="pagename">
<img src="<?php echo DOKU_TPL; ?>images/logo.png" align="absmiddle"/>
[[<?php tpl_link(wl($ID,'do=backlink'),tpl_pagetitle($ID,true),'title="'.$lang['btn_backlink'].'"')?>]]
</div>
You can build the HTML as you like... but the example above works just fine (the image is located in the lib/tpl/company/images/)
You can then change the template of your Wiki by updating the configuration at:
Admin > configuration manager > template
There's no config option for this, you'd have to hack it in \dokuwiki-2009-02-14\lib\tpl\index.php I'm afraid.