dconf - Custom icons are not displayed in the panel menu - icons

The custom icon custom-symbolic.svg is not displayed in the panel menu.
This is a segment of a dconf file:
[org/cinnamon]
app-menu-icon-name='custom-symbolic'
The full path to the file I created is:
/usr/share/icons/hicolor/scalable/apps/custom-symbolic.svg
and has a resolution of 51x51 pixels.
The owner and permissions of that icon are identical to those of all other icons in that path.
If instead of custom-symbolic I insert cinnamon-symbolic, which is present at the same path, the panel menu icon is displayed correctly, as well as all the other icons already present in the path:
/usr/share/icons/hicolor/scalable/apps
What I did wrong?

I solved:
sudo update-icon-caches /usr/share/icons/*

Related

Only CSS to open link in a new tab

Hello I have the following problem: I have my website made in Wordpress, and I have a 3D Cover Carousel plugin there, which shows me a gallery of photos in 3d. The thing is that when I click on the image I want the link to be opened in a NEW tab. In the plugin settings there are no such an option. The plugin html is a short code added to my page. So the only thing I can change is Additional css. So is there any options to make a link be opened in a new tab only with css?
As it was previously stated here, there is no way to do this with pure CSS.
If you can use JavaScript, you can target the item and add it the attribute target="_blank".
document.getElementById("element").setAttribute("target", "_blank");
document.getElementById("element").setAttribute("target", "_blank");
You can add this piece of js in your footer.php file.
Another method is to add a js file and include it using wp_enqueue_script function in your function.php file.

Wordpress main menu item appears out of nowhere for mobile version

I've been asked to look at the main menu on luxmux.com,
This is a Wordpress website, it has full and mobile version and the menu is different for both. For full version the menu works well and shows all the items as per Wordpress Dashboard>>Appearance>>Menu.
For the mobile version however the menu adds a "- MENU -" item to the menu (to the very top). I've been asked to remove this item.
From what I see the menu is generated in header.php with this single line -
<?php wp_nav_menu( array( 'menu_id'=>'nav', 'theme_location'=>'main-navigation')); ?>
Initially I thought that I can remove a single item by using exclude, as per this example -
wp_nav_menu exclude pages from menu
However, the "- MENU -" item does not have a page ID.
Thanks.
The reason that's happening is that Javascript is building the menu based on the main menu. Look at the selectnav.js file:
view-source:http://www.luxmux.com/wp-content/themes/shootingstar/js/selectnav.js?ver=0.1
Look into that file and you can see label = o.label || "- MENU -",
You'll have to know some JS to fix this issue.
Find the css identifier for the element (like a class or id) and just add the following css to any css file loaded by the admin section:
.whatever-class {
display: none !important;
}

How to name different footer files which can be selected in wp-admin's page editors

Seen this done before in other templates, just wondering if anyone here knows how to do this.
I have one template I have created, and two hard coded footer files. footer.php and footer-1.php.
I want to be able to select between using either footer.php or footer-1.php in wp-admin via the pages editor.
So far all I have found so far is adding something like this to the top of the file:
Template Name: footer_1
However, this requires that a secondary header and other files are also included, it won't allow just a change of footer alone.
Can anyone tell me how I can name different footer files so that wordpress detects them in wp-admin and allows me to switch between them.
I do not require adding widgets to these, there is simply two styles of footer and they have no correlation to page or category to hard code, they have to be selected in the admin area manually.
To dynamically change your footer with a admin editor option, do the following:
Open the page you want to customize in editor
Locate Custom Fields meta box in editor (If it is not visible tick the box Custom Fields in the Screen options dropdown at top right)
Select Add Custom Field in Custom Fields meta box
Enter footer_template in Name field and an arbitrary id in the Value field
Select Update to save your settings
Open your theme folder and locate page.php file
Open page.php file and locate the very last line <?php get_footer(); ?>
Delete the line in step 7 and add the following:
<?php
$scriptonomy_footer_meta = get_post_meta(get_the_ID(), 'footer_template', true);
get_footer($scriptonomy_footer_meta); ?>
Save and close page.php file
Make a duplicate of footer.php and name it footer- plus any arbitrary id you chose in step 4, ie: footer-1.php or footer-two.php
Now you can assign any custom footer to any page. You can do the same for the header as well using this technique.

Displaying image when text is clicked

I want an image to be displayed when a text is clicked, I have this code at the moment and it works perfectly fine but how would I change the code so I can use a image for my own directory instead of an image from online
<iframe src="" name="bettie"></iframe>
<p>Bettie</p>
Use the local URL instead of the remote URL.
download this image: http://www.bettiepage.com/images/photos/bikini/bikini1.jpg
place it in the same folder/directory as your index.html page
change Bettie

Drupal 6: How to add a new region to a theme

I added a new region line to my .info file under /sites/all/themes/[theme] directory. However when I look at the Blocks page, the region is not visible, nor is it a selectable item from the dropdown menus. I've cleared the cache as well. What am I missing?
If you have multiple themes enabled, make sure you are looking at the correct theme on the block configuration page.
For example, if you have custom_theme and garland enabled, there is a block configuration page for each.
Go to http://www.example.com/admin/build/block/list/custom_theme to see blocks for your custom_theme
Go to http://www.example.com/admin/build/block/list/garland to see blocks for the garland theme
etc... for all enabled themes
When you say you cleared the cache, are you actually referring to the Theme Registry? Or did you really clear the database cache? If you just cleared the theme registry, it won't reflect the changes to the theme's .info file. You can clear the cache by...
Use the "clear all cached data" link or button located at "Administer > Site configuration > Performance".
With the devel block enabled (comes with devel module), click the "Empty cache" link.
Simply visit the theme select page at "Administer > Site building > Themes".
List from Drupal.org
It's also possible the browser itself is caching pages. You could clear your browser cache, as well as the Drupal cache, just to be absolutely sure.
If none of that works, could you post your region assignment from the .info file?
I'm presuming Drupal 6 here, but in your andytheme.info, did you add the region like this (look at the bottom line):
regions[left] = Left sidebar
regions[right] = Right sidebar
regions[content] = Content
regions[header] = Header
regions[footer] = Footer
regions[andyregion] = Andy Region
Remember that you have to add all the regions if you add any in your .info file--they won't be inherited from your base theme.
And, in your page.tpl.php, did you add the region variable to be printed somewhere? Something like this?
<div class="region andyregion"><?php print $andyregion ?></div>
Of course, it would be surrounded by whatever and other stuff you'd want. Then flush the cache and see if it's in the blocks.
Andy-
The following assumes you use Zen as the base template.
Open up /sites/[yoursite]/themes/[yourtheme]/[yourtheme].info file and scroll down to where there are loads of regions[xxx] = yyy
The name in brackets is the machine name of the region. The text after the equals sign is a descriptive text used on the admin/structure/blocks page.
Open up /sites/[yoursite]/themes/[yourtheme]/templates/page.tpl.php and adding <?php print render($page['MACHINE-NAME']); ?> where you want the region to appear.

Resources