Wordpress image and link in header - image

I have a Wordpress child theme of TwentyTwelve with a header image and I would like to place another smaller image with a hyperlink centered in the header image.
---------------------------------------------------------------------
| 1 |
| ----- ----- |
| | 2 | | 3 | |
| ----- ----- |
| |
---------------------------------------------------------------------
From the diagram above, I have [1] being the link to the main site (standard from twentytwelve) and I would like to add [2] and [3] as images and hyperlinks. Any suggestions on how I would to this? I'm just starting to learn theming. Thanks in advance!

I've found a solution if anyone else is looking to do this. In my header.php, I added this just before </header>:
<div style="position:relative; visibility:show; left: 50%; top: -<?php echo get_custom_header()->height/2; ?>px; z-index:2; >
<img src="image" ><br>
</div>

Related

Laravel mail::table not rendering a table

I had a problem on my mail::table in Laravel Markdown Mailables. The table is not rendering. I have also no indents on it.
emails/inquiry.blade.php
#component('mail::message')
#New Inquiry
We have received a new inquiry
#component('mail::table')
| Laravel | Table | Example |
| ------------- |:-------------:| --------:|
| Col 2 is | Centered | $10 |
| Col 3 is | Right-Aligned | $20 |
#endcomponent
Thanks
#endcomponent
Mailtrap output

<blockquote> tag inserted when using image in cell of RST table?

When I use the following code:
+----------------------+---------------+---------------------------------------------------------------------+
| A | B | C |
+======================+===============+=====================================================================+
| Merchant Rating | Ad Extension | Star ratings plus number of reviews for the advertiser/merchant. |
| | | |
| | |.. image:: /images/merchant-rating.png |
+----------------------+---------------+---------------------------------------------------------------------+
The text preceding the image in column C gets wrapped in <blockquote> tags in the HTML output. Is there any way to avoid this?
To avoid the blockquote tag in the first paragraph of the third column, you could try using this:
+----------------------+---------------+---------------------------------------------------------------------+
| A | B | C |
+======================+===============+=====================================================================+
| Merchant Rating | Ad Extension | Star ratings plus number of reviews for the advertiser/merchant. |
| | | |
| | | |img| |
+----------------------+---------------+---------------------------------------------------------------------+
.. |img| image:: /images/merchant-rating.png
Instead, you'll get two paragraphs.
Use a substitution and remove the separating line so that Sphinx interprets the content as a single block of text.
+-----------------+--------------+------------------------------------------------------------------+
| A | B | C |
+=================+==============+==================================================================+
| Merchant Rating | Ad Extension | Star ratings plus number of reviews for the advertiser/merchant. |
| | | |img| |
+-----------------+--------------+------------------------------------------------------------------+
.. |img| image:: /images/merchant-rating.png

Image and table of contents side by side in Restructured Text with python-Shinx

I have been using Sphinx to make a nice documentation of my code and I would like to know if it's possible to place an image next to the table of contents (instead of a big white space without anything)
For now, my beginner's index.rst file looks like this :
.. XXXXXX documentation master file, created by
sphinx-quickstart on Wed Apr 11 13:59:42 2018.
You can adapt this file completely to your liking, but it should at least
contain the root `toctree` directive.
Welcome to XXXXXX's documentation!
==================================
.. topic:: the_topic
.. todo:: write topic
.. toctree::
:maxdepth: 2
:caption: Contents:
Tool1
Tool2
Tool3
Tool4
Tool5
Tool6
Tool7
Tool8
.. image:: _static/my_image.png
:align: center
Indices and tables
==================
* :ref:`genindex`
* :ref:`modindex`
* :ref:`search`
Thanks in advance.
Yes, it's possible. Put your image directive before your toctree directive. Then use a common option, like so:
.. image:: _static/my_image.png
:class: align-right
The Sphinx default style sheet, basic.css, might already exist in your theme and it has a style already set up to float the image to the right. If not, then override your theme's CSS with a local CSS file, or add a new CSS file to your theme, in which you define a new style.
img.align-right {float: right;}
Another option is to use the table directive. See http://docutils.sourceforge.net/docs/ref/rst/directives.html#table for all the table directive options.
.. table::
:align: center
:widths: auto
+--------------------------------------+--------------------------+
| .. image:: _static/my_image.png | .. toctree:: |
| | :maxdepth: 2 |
| | :caption: Contents: |
| | |
| | Tool1 |
| | Tool2 |
| | Tool3 |
| | Tool4 |
| | Tool5 |
| | Tool6 |
| | Tool7 |
| | Tool8 |
+--------------------------------------+--------------------------+

How can I disable resize in a View

My main window looks like this:
____________________________
|Upper View |
|___________________________|
|Left View|Editor|Right view|
| | | |
| | | |
| | | |
and I want to make the upper view not resizable.
The Perspective.createInitialLayout is:
layout.addStandaloneView(URLView.ID, false, IPageLayout.TOP, 0f, layout.getEditorArea());
layout.addStandaloneView(ServicesView.ID, false, IPageLayout.LEFT, 0.2f, layout.getEditorArea());
IFolderLayout folder = layout.createFolder("responses", IPageLayout.RIGHT, 0.6f, layout.getEditorArea());
folder.addPlaceholder(ResponseView.ID + ":*");
folder.addView(ResponseView.ID);
layout.getViewLayout(ResponseView.ID).setCloseable(true);
Is there any way to do it?
Thank you!
There is no easy way to make a view non-resizable. A possible way could be to introduce a banner to place the content of that view inside this banner. I've written some time ago a small example

Visual studio 2010 IDE layout

My current visual studio panel layout looks similar to the drawing below:
-----------------
| | | |
| | | |
| | | |
| | |--|
| | | |
| |---------| |
| | | |
-----------------
I really don't need the full height of the screen for the toolbox or server explorer and was wondering if there was a way to change the layout so that the bottom section extended all the way to the left edge of the screen like in this drawing:
-----------------
| | | |
| | | |
| | | |
| | |--|
| | | |
|------------| |
| | |
-----------------
I am space constrained on the right side, so a symetric layout with the bottom section running full width wouldn't be acceptable. I've tried dragging stuff around but haven't had any luck in getting VS to position the panels as I want. Is my desired layout not possible or am I missing the right way to coax the layout into fitting?
Yes, you can do this. When you are dragging the toolbox, note the little "targets" in the center of the screen. Drop the toolbox onto the target that corresponds with the area where you want it docked.
See here for more detail and pics.
Drag the bottom panel off and make sure to mouse over the icon that appears all the way at the bottom center of the screen, although this will cause it to take up the whole bottom portion of the IDE,
That's an easy process.
Drag the window docked in the bottom to middle of the VS window so that it floats in the middle.
Now when you drag it, a helper would apper to doc it.
You'll have some dynamic docking helpers like below.
↑
↑
← ← → →
↓
↓
if you chose the downarrow in the dock helper in the middle, you'll get the layout like this.
| | | |
| | | |
| | | |
| | |--|
| | | |
| |---------| |
| | | |
-----------------
If you chose the downarrow all the way at the bottom, you'll get the layout like this.
| | | |
| | | |
| | | |
| | |--|
| | | |
|---------------|
| |
-----------------

Resources