I would like to know if there is a better way to create posts in the WordPress dashboard.
I explain myself, I have created two categories called “News – left side” and “News – right side” where I’m displaying some post on the left, and some post on the right of the page.
But, the post that I have created as been made with html tags like this :
“News – left side”:
<div id="about">
<div id="mug-shot" class="thin-column">
<div class="thumbnail"><img class="attachment-thumbnail wp-post-image" title="A web picture" src="http://www.marketwize.co.uk/communities/3/004/007/028/723/images/4538143501.jpg" alt="Web tools" width="240" height="350" /></div>
</div>
<div id="about-page" class="thin-column">
<div class="page-content">
<h3 class="inline-subtitle">TEXT</h3>
<h1 class="inline-title">TEXT</h1>
<div class="content">
<div>
Just simple text, simple text.
Another paragraph Another paragraph.
</div>
</div>
</div>
</div>
<div id="contacts" class="thin-column">
<h3 class="inline-subtitle">Please do not hesitate to</h3>
<h1 class="inline-title">Contact</h1>
<div>
Company name
Adress
<em><a title="Email" href="mailto:test@test.com" target="_blank">email@email.com</a></em>
+0 000 000 0000
On <a title="Twitter" href="http://www.twitter.com/" target="_blank"><em>Twitter</em></a>
</div>
</div>
<div id="book-list" class="thin-column">
<h3 class="inline-subtitle">H3 title</h3>
<div>
<h4>H4 tag</h4>
<em>EM text</em>
<a title="Title | Title2" href="https://www.google.co.uk/" target="_blank">GOOD Magazine</a>
</div>
</div>
</div>
“News – right side”
<div class="thumbnail"><img class="attachment-thumbnail wp-post-image" title="Me on my snowboard" src="http://i.telegraph.co.uk/multimedia/archive/02016/WSS-fest_2016290b.jpg" alt="Snowboarder" width="240" height="350" /></div>
<h3 class="inline-subtitle">Illustration title</h3>
<h1 class="inline-title">28.04.2013 (A date)</h1>
Here is my text, with a link to <a href="https://www.google.co.uk/" target="_blank">Google</a>.
So, inside posts, I’m filling html tags. Is there a way to avoid it? (I can create custom field but this won’t be convenient).
And how can I create a default template for a new post like this:
<div class="thumbnail">Add your image here</div>
<h3 class="inline-subtitle">Add your illustration title here</h3>
<h1 class="inline-title">Add a date here</h1>
Add your text here.
Thanks
It is the default behaviour of the WordPress core to strip out most HTML tags. You could try overriding this by installing a plugin, such as TinyMCE Advanced, within the settings for which should be an option to allow the complete HTML to be saved unfiltered.
Hope this helps,
Ross