0
votes

I would like to be able to access a site's HTML in Wordpress in order for fine editing/customization. At the moment, to access the HTML of the page I am going to Chrome Developer tools where I can see all the html for the site in the bottom left-hand window. But when I try and access it from the Wordpress dashboard, all I can find are files such as 'single.php', which are written using php loops and I cannot seem to trace where the original html elements are.

For example, for changing the number of columns in a contact form 'message' box.

Any ideas?

2

2 Answers

1
votes

Wordpress is template-based. As you already mentioned there are templates such as single.php, content.php etc. In order to change the lay-out of the website (or better, the structure) you have to change the corresponding template. If you want to change the style, you have to edit the style.css of your theme.

If you want to change the HTML of individual posts or pages, you can simply click the "edit" button and instead of using the WYSIWYG editor, you can swap to a standard text editor.

Wordpress is very well documented. Here is a guide to get you started on editing files.

1
votes

WordPress, like pretty much any popular CMS, produces its HTML by combining three basic factors:

  • The active theme

  • The enabled plugins

  • The stored content

While the latter is merely data stored in a database, the other two are responsible for deciding what to pull from the database, how to filter it and how to render it.

So the final HTML your browser receives cannot be a subject of arbitary manipulation. You can change some things by developing your own theme, some others by installing or building extra plugins but not the final, dynamically-produced output.

Consequently, I highly doubt there will ever be a plugin that gives you the opportunity to do what you ask.